* Replaces bare except by Exception in r.plane, v.in.wfs, v.to.lines.py, g.manual (good enough for Flake8). * Removes the per-file ignores from the .flake8 file.
@@ -29,10 +29,6 @@ per-file-ignores =
r.in.srtm/r.in.srtm.py: E722
r.fillnulls/r.fillnulls.py: E722
d.rast.edit/d.rast.edit.py: E722
- g.manual/g.manual.py: E722
- v.to.lines/v.to.lines.py: E722
- v.in.wfs/v.in.wfs.py: E722
- r.plane/r.plane.py: E722
v.what.strds/v.what.strds.py: E722
i.in.spotvgt/i.in.spotvgt.py: E722
@@ -104,7 +104,7 @@ def start_browser(entry):
try:
webbrowser.open(url_path)
- except:
+ except Exception:
grass.fatal(
_("Error starting browser '%(browser)s' for HTML file" " '%(path)s'")
% dict(browser=browser, path=path)
@@ -80,7 +80,7 @@ def main():
ea = float(gscript.utils.float_or_dms(options["easting"]))
no = float(gscript.utils.float_or_dms(options["northing"]))
gscript.fatal(_("Input coordinates seems to be invalid"))
el = float(options["elevation"])
@@ -204,7 +204,7 @@ def main():
grass.run_command("v.in.ogr", flags="o", input=tmpxml, output=out)
grass.message(_("Vector map <%s> imported from WFS.") % out)
grass.message(_("WFS import failed"))
finally:
try_remove(tmpxml)
@@ -188,7 +188,7 @@ def main():
)
grass.fatal(_("Error removing table from layer 1"))
# TODO: when this except is happaning, it seems that never, so it seems wrong
grass.warning(_("No table for layer %d" % 1))
grass.run_command(