diff --git a/.flake8 b/.flake8 index ab4038e4749..326ffef5bff 100644 --- a/.flake8 +++ b/.flake8 @@ -77,11 +77,10 @@ per-file-ignores = python/grass/temporal/temporal_topology_dataset_connector.py: E722 # Current benchmarks/tests are changing sys.path before import. # Possibly, a different approach should be taken there anyway. - python/grass/pygrass/tests/benchmark.py: E402, F821 + python/grass/pygrass/tests/benchmark.py: F821 # Configuration file for Sphinx: # Ignoring import/code mix and line length. # Files not managed by Black - python/grass/imaging/images2gif.py: E226 # Unused imports in init files # F403 star import used; unable to detect undefined names python/grass/*/__init__.py: F401, F403 diff --git a/python/grass/pygrass/tests/benchmark.py b/python/grass/pygrass/tests/benchmark.py index fa7f0c01a65..0e2b86360dd 100644 --- a/python/grass/pygrass/tests/benchmark.py +++ b/python/grass/pygrass/tests/benchmark.py @@ -14,15 +14,14 @@ import sys from jinja2 import Template from pathlib import Path - -sys.path.append(str(Path.cwd())) -sys.path.append("%s/.." % (str(Path.cwd()))) - import grass.lib.gis as libgis import grass.lib.raster as libraster import grass.script as gs import ctypes +sys.path.append(str(Path.cwd())) +sys.path.append("%s/.." % (str(Path.cwd()))) + def test__RasterSegment_value_access__if(): test_a = pygrass.RasterSegment(name="test_a")