diff --git a/src/imagery/i.sentinel/i.sentinel.coverage/i.sentinel.coverage.py b/src/imagery/i.sentinel/i.sentinel.coverage/i.sentinel.coverage.py index 1f11ec0572..20d3f2586f 100644 --- a/src/imagery/i.sentinel/i.sentinel.coverage/i.sentinel.coverage.py +++ b/src/imagery/i.sentinel/i.sentinel.coverage/i.sentinel.coverage.py @@ -200,7 +200,7 @@ def get_size(vector): quiet=True, overwrite=True, ) - sizeselected = grass.parse_command("v.db.select", map=tmpvector, flags="v") + sizeselected = grass.parse_command("v.db.select", map=tmpvector, format="vertical") sizesstr = [x.split("|")[1:] for x in sizeselected if x.startswith("tmparea|")][0] sizes = [float(x) for x in sizesstr] return sum(sizes) diff --git a/src/raster/r.valley.bottom/r.valley.bottom.py b/src/raster/r.valley.bottom/r.valley.bottom.py index 1cb70b5e2a..1751c1c4c7 100644 --- a/src/raster/r.valley.bottom/r.valley.bottom.py +++ b/src/raster/r.valley.bottom/r.valley.bottom.py @@ -495,16 +495,13 @@ def smooth_dem(DEM): smoothed = rand_id("smoothed{}".format(L + 1)) TMP_RAST[L].append(smoothed) - try: - r.neighbors(input=DEM, output=smoothed, size=11, gauss=3) - except ParameterError: - r.neighbors( - input=DEM, - output=smoothed, - size=11, - weighting_function="gaussian", - weighting_factor=3, - ) + r.neighbors( + input=DEM, + output=smoothed, + size=11, + weighting_function="gaussian", + weighting_factor=3, + ) return smoothed diff --git a/src/vector/v.habitat.dem/v.habitat.dem.py b/src/vector/v.habitat.dem/v.habitat.dem.py index 0c6ff09bdb..8a95cbabae 100644 --- a/src/vector/v.habitat.dem/v.habitat.dem.py +++ b/src/vector/v.habitat.dem/v.habitat.dem.py @@ -157,15 +157,7 @@ def main(): PixelArea = Xres * Yres global tmp - ## check if r.geomorphon addon is installed - if not grass.find_program("r.geomorphon", "--help"): - grass.fatal( - _("The 'r.geomorphon' addon was not found, install it first:") - + "\n" - + "g.extension r.geomorphon" - ) - - ## check if r.geomorphon addon is installed + ## check if r.sun.hourly addon is installed if not grass.find_program("r.sun.hourly", "--help"): grass.fatal( _("The 'r.sun.hourly' addon was not found, install it first:") @@ -285,7 +277,7 @@ def main(): grass.run_command( "v.db.select", map=v_habitat, - flags="v", + format="vertical", layer=1, columns=v_column, where="habarea < %s" % (PixelArea), @@ -296,7 +288,7 @@ def main(): grass.run_command( "v.db.select", map=v_habitat, - flags="v", + format="vertical", layer=1, columns=v_column, file=smallareacsv,