cgre-aachen / gemgis

Spatial data processing for geomodeling
https://gemgis.readthedocs.io/en/latest
GNU Lesser General Public License v3.0
257 stars 41 forks source link

[LINTING] Linting with `ruff check` fails with 91 errors. See the report in Details below. #348

Open AlexanderJuestel opened 1 month ago

AlexanderJuestel commented 1 month ago

Relates to https://github.com/pyOpenSci/software-submission/issues/128#issuecomment-2014860216

gemgis/__init__.py:33:1: F403 `from gemgis.gemgis import *` used; unable to detect undefined names
gemgis/__init__.py:34:25: F401 [*] `gemgis.vector` imported but unused
gemgis/__init__.py:35:25: F401 [*] `gemgis.raster` imported but unused
gemgis/__init__.py:36:24: F401 [*] `gemgis.utils` imported but unused
gemgis/__init__.py:37:32: F401 [*] `gemgis.visualization` imported but unused
gemgis/__init__.py:38:22: F401 [*] `gemgis.web` imported but unused
gemgis/__init__.py:39:33: F401 [*] `gemgis.postprocessing` imported but unused
gemgis/__init__.py:40:23: F401 [*] `gemgis.misc` imported but unused
gemgis/__init__.py:41:1: F403 `from gemgis.download_gemgis_data import *` used; unable to detect undefined names
gemgis/download_gemgis_data.py:85:16: F401 `pooch` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/gemgis.py:25:25: F401 [*] `pandas.core.frame` imported but unused
gemgis/postprocessing.py:68:25: F401 `gempy` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/postprocessing.py:255:72: E712 Comparison to `True` should be `cond is True` or `if cond:`
gemgis/postprocessing.py:506:25: F401 `gempy` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/postprocessing.py:720:5: F841 Local variable `option1_1` is assigned to but never used
gemgis/postprocessing.py:726:5: F841 Local variable `option1_2` is assigned to but never used
gemgis/postprocessing.py:730:5: F841 Local variable `option1_3` is assigned to but never used
gemgis/postprocessing.py:747:5: F841 Local variable `option2_1` is assigned to but never used
gemgis/postprocessing.py:753:5: F841 Local variable `option2_2` is assigned to but never used
gemgis/postprocessing.py:759:5: F841 Local variable `option2_3` is assigned to but never used
gemgis/postprocessing.py:765:5: F841 Local variable `option2_4` is assigned to but never used
gemgis/postprocessing.py:771:5: F841 Local variable `option2_5` is assigned to but never used
gemgis/postprocessing.py:777:5: F841 Local variable `option2_6` is assigned to but never used
gemgis/postprocessing.py:783:5: F841 Local variable `option2_7` is assigned to but never used
gemgis/postprocessing.py:789:5: F841 Local variable `option2_8` is assigned to but never used
gemgis/postprocessing.py:795:5: F841 Local variable `option2_9` is assigned to but never used
gemgis/postprocessing.py:801:5: F841 Local variable `option2_10` is assigned to but never used
gemgis/postprocessing.py:807:5: F841 Local variable `option2_11` is assigned to but never used
gemgis/postprocessing.py:820:5: F841 Local variable `option3_1` is assigned to but never used
gemgis/postprocessing.py:824:5: F841 Local variable `option3_2` is assigned to but never used
gemgis/postprocessing.py:828:5: F841 Local variable `option3_3` is assigned to but never used
gemgis/postprocessing.py:883:12: E713 [*] Test for membership should be `not in`
gemgis/postprocessing.py:895:12: E713 [*] Test for membership should be `not in`
gemgis/postprocessing.py:903:12: E713 [*] Test for membership should be `not in`
gemgis/postprocessing.py:972:5: F841 Local variable `roation` is assigned to but never used
gemgis/postprocessing.py:976:5: F841 Local variable `sizescale` is assigned to but never used
gemgis/postprocessing.py:1062:25: F401 `gempy` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/postprocessing.py:1073:16: E713 [*] Test for membership should be `not in`
gemgis/postprocessing.py:1073:94: E712 Comparison to `True` should be `cond is True` or `if cond:`
gemgis/postprocessing.py:1090:16: E713 [*] Test for membership should be `not in`
gemgis/raster.py:31:27: F401 [*] `rasterio.mask.mask` imported but unused
gemgis/raster.py:32:30: F401 [*] `shapely.geometry.box` imported but unused
gemgis/utils.py:545:25: F401 `gempy` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/utils.py:2206:48: E714 [*] Test for object identity should be `is not`
gemgis/utils.py:2408:5: F841 Local variable `bbox` is assigned to but never used
gemgis/utils.py:2639:47: F401 `segysak.segy.segy_writer` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/utils.py:2723:47: F401 `segysak.segy.segy_writer` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/vector.py:8140:56: E713 [*] Test for membership should be `not in`
gemgis/visualization.py:111:26: E712 Comparison to `False` should be `cond is False` or `if not cond:`
gemgis/visualization.py:1670:60: E712 Comparison to `True` should be `cond is True` or `if cond:`
gemgis/visualization.py:1670:114: E712 Comparison to `True` should be `cond is True` or `if cond:`
gemgis/visualization.py:2941:16: F401 `mplstereonet` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:73:32: F401 `owslib.wms.WebMapService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:184:16: F401 `owslib` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:186:32: F401 `owslib.wms.WebMapService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:187:32: F401 `owslib.wfs.WebFeatureService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:188:32: F401 `owslib.wcs.WebCoverageService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:189:9: F841 Local variable `__all__` is assigned to but never used
gemgis/web.py:379:16: F401 `owslib` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:381:32: F401 `owslib.wms.WebMapService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:382:32: F401 `owslib.wfs.WebFeatureService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:383:32: F401 `owslib.wcs.WebCoverageService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:384:9: F841 Local variable `__all__` is assigned to but never used
gemgis/web.py:527:32: F401 `owslib.wms.WebMapService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:528:32: F401 `owslib.wfs.WebFeatureService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:529:32: F401 `owslib.wcs.WebCoverageService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:530:9: F841 Local variable `__all__` is assigned to but never used
gemgis/web.py:602:16: F401 `owslib` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:604:32: F401 `owslib.wms.WebMapService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:605:32: F401 `owslib.wfs.WebFeatureService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:606:32: F401 `owslib.wcs.WebCoverageService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:607:9: F841 Local variable `__all__` is assigned to but never used
gemgis/web.py:701:32: F401 `owslib.wms.WebMapService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:702:32: F401 `owslib.wfs.WebFeatureService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:703:32: F401 `owslib.wcs.WebCoverageService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:704:9: F841 Local variable `__all__` is assigned to but never used
gemgis/web.py:780:16: F401 `owslib` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:782:32: F401 `owslib.wms.WebMapService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:783:32: F401 `owslib.wfs.WebFeatureService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:784:32: F401 `owslib.wcs.WebCoverageService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:785:9: F841 Local variable `__all__` is assigned to but never used
gemgis/web.py:874:16: F401 `owslib` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:876:32: F401 `owslib.wms.WebMapService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:877:32: F401 `owslib.wfs.WebFeatureService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:878:32: F401 `owslib.wcs.WebCoverageService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:879:9: F841 Local variable `__all__` is assigned to but never used
gemgis/web.py:988:16: F401 `owslib` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:990:32: F401 `owslib.wms.WebMapService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:991:32: F401 `owslib.wfs.WebFeatureService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:992:32: F401 `owslib.wcs.WebCoverageService` imported but unused; consider using `importlib.util.find_spec` to test for availability
gemgis/web.py:993:9: F841 Local variable `__all__` is assigned to but never used
Found 91 errors.
[*] 17 fixable with the `--fix` option (33 hidden fixes can be enabled with the `--unsafe-fixes` option).
AlexanderJuestel commented 1 month ago
   |
21 | # -- GemGIS configuration ---------------------------------------------------
22 | import os
   | ^^^^^^^^^ E402
23 | import sys
24 | #sys.path.insert(0, os.path.abspath(".."))
   |

docs\conf.py:22:8: F401 [*] `os` imported but unused
   |
21 | # -- GemGIS configuration ---------------------------------------------------
22 | import os
   |        ^^ F401
23 | import sys
24 | #sys.path.insert(0, os.path.abspath(".."))
   |
   = help: Remove unused import: `os`

docs\conf.py:23:1: E402 Module level import not at top of file
   |
21 | # -- GemGIS configuration ---------------------------------------------------
22 | import os
23 | import sys
   | ^^^^^^^^^^ E402
24 | #sys.path.insert(0, os.path.abspath(".."))
25 | #sys.path.insert(0, os.path.abspath('../..'))
   |

docs\conf.py:23:8: F401 [*] `sys` imported but unused
   |
21 | # -- GemGIS configuration ---------------------------------------------------
22 | import os
23 | import sys
   |        ^^^ F401
24 | #sys.path.insert(0, os.path.abspath(".."))
25 | #sys.path.insert(0, os.path.abspath('../..'))
   |
   = help: Remove unused import: `sys`

docs\conf.py:32:1: E402 Module level import not at top of file
   |
30 | # The full version, including alpha/beta/rc tags
31 |
32 | import gemgis as gg
   | ^^^^^^^^^^^^^^^^^^^ E402
33 |
34 | version = gg.__version__
   |

gemgis\__init__.py:33:1: F403 `from gemgis.gemgis import *` used; unable to detect undefined names
   |
31 |     __version__ = "unreleased"
32 |
33 | from gemgis.gemgis import *
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ F403
34 | import gemgis.vector as vector
35 | import gemgis.raster as raster
   |

gemgis\__init__.py:34:25: F401 `gemgis.vector` imported but unused; consider removing, adding to `__all__`, or using a redundant alias
   |
33 | from gemgis.gemgis import *
34 | import gemgis.vector as vector
   |                         ^^^^^^ F401
35 | import gemgis.raster as raster
36 | import gemgis.utils as utils
   |
   = help: Use an explicit re-export: `gemgis.vector as gemgis.vector`

gemgis\__init__.py:35:25: F401 `gemgis.raster` imported but unused; consider removing, adding to `__all__`, or using a redundant alias
   |
33 | from gemgis.gemgis import *
34 | import gemgis.vector as vector
35 | import gemgis.raster as raster
   |                         ^^^^^^ F401
36 | import gemgis.utils as utils
37 | import gemgis.visualization as visualization
   |
   = help: Use an explicit re-export: `gemgis.raster as gemgis.raster`

gemgis\__init__.py:36:24: F401 `gemgis.utils` imported but unused; consider removing, adding to `__all__`, or using a redundant alias
   |
34 | import gemgis.vector as vector
35 | import gemgis.raster as raster
36 | import gemgis.utils as utils
   |                        ^^^^^ F401
37 | import gemgis.visualization as visualization
38 | import gemgis.web as web
   |
   = help: Use an explicit re-export: `gemgis.utils as gemgis.utils`

gemgis\__init__.py:37:32: F401 `gemgis.visualization` imported but unused; consider removing, adding to `__all__`, or using a redundant alias
   |
35 | import gemgis.raster as raster
36 | import gemgis.utils as utils
37 | import gemgis.visualization as visualization
   |                                ^^^^^^^^^^^^^ F401
38 | import gemgis.web as web
39 | import gemgis.postprocessing as post
   |
   = help: Use an explicit re-export: `gemgis.visualization as gemgis.visualization`

gemgis\__init__.py:38:22: F401 `gemgis.web` imported but unused; consider removing, adding to `__all__`, or using a redundant alias
   |
36 | import gemgis.utils as utils
37 | import gemgis.visualization as visualization
38 | import gemgis.web as web
   |                      ^^^ F401
39 | import gemgis.postprocessing as post
40 | import gemgis.misc as misc
   |
   = help: Use an explicit re-export: `gemgis.web as gemgis.web`

gemgis\__init__.py:39:33: F401 `gemgis.postprocessing` imported but unused; consider removing, adding to `__all__`, or using a redundant alias
   |
37 | import gemgis.visualization as visualization
38 | import gemgis.web as web
39 | import gemgis.postprocessing as post
   |                                 ^^^^ F401
40 | import gemgis.misc as misc
41 | from gemgis.download_gemgis_data import *
   |
   = help: Use an explicit re-export: `gemgis.postprocessing as gemgis.postprocessing`

gemgis\__init__.py:40:23: F401 `gemgis.misc` imported but unused; consider removing, adding to `__all__`, or using a redundant alias
   |
38 | import gemgis.web as web
39 | import gemgis.postprocessing as post
40 | import gemgis.misc as misc
   |                       ^^^^ F401
41 | from gemgis.download_gemgis_data import *
   |
   = help: Use an explicit re-export: `gemgis.misc as gemgis.misc`

gemgis\__init__.py:41:1: F403 `from gemgis.download_gemgis_data import *` used; unable to detect undefined names
   |
39 | import gemgis.postprocessing as post
40 | import gemgis.misc as misc
41 | from gemgis.download_gemgis_data import *
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ F403
   |

gemgis\postprocessing.py:255:36: E712 Avoid equality comparisons to `True`; use `if geo_model.surfaces.df['isFault']:` for truth checks
    |
253 |                         verbose=[])
254 |     # Set faults active
255 |     for i in geo_model.surfaces.df[geo_model.surfaces.df['isFault'] == True]['surface'].values.tolist():
    |                                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ E712
256 |         well_model.set_is_fault([i])
    |
    = help: Replace with `geo_model.surfaces.df['isFault']`

gemgis\postprocessing.py:720:5: F841 Local variable `option1_1` is assigned to but never used
    |
718 |                             attrib={"type": 'Map'})
719 |
720 |     option1_1 = ET.SubElement(option1,
    |     ^^^^^^^^^ F841
721 |                               'Option',
722 |                               attrib={"value": '',
    |
    = help: Remove assignment to unused variable `option1_1`

gemgis\postprocessing.py:726:5: F841 Local variable `option1_2` is assigned to but never used
    |
724 |                                       "name": 'name'})
725 |
726 |     option1_2 = ET.SubElement(option1,
    |     ^^^^^^^^^ F841
727 |                               'Option',
728 |                               attrib={"name": 'properties'})
    |
    = help: Remove assignment to unused variable `option1_2`

gemgis\postprocessing.py:730:5: F841 Local variable `option1_3` is assigned to but never used
    |
728 |                               attrib={"name": 'properties'})
729 |
730 |     option1_3 = ET.SubElement(option1,
    |     ^^^^^^^^^ F841
731 |                               'Option',
732 |                               attrib={"value": 'collection',
    |
    = help: Remove assignment to unused variable `option1_3`

gemgis\postprocessing.py:747:5: F841 Local variable `option2_1` is assigned to but never used
    |
745 |                             attrib={"type": 'Map'})
746 |
747 |     option2_1 = ET.SubElement(option2,
    |     ^^^^^^^^^ F841
748 |                               'Option',
749 |                               attrib={"value": '3x:0,0,0,0,0,0',
    |
    = help: Remove assignment to unused variable `option2_1`

gemgis\postprocessing.py:753:5: F841 Local variable `option2_2` is assigned to but never used
    |
751 |                                       "name": 'border_width_map_unit_scale'})
752 |
753 |     option2_2 = ET.SubElement(option2,
    |     ^^^^^^^^^ F841
754 |                               'Option',
755 |                               attrib={"value": color,
    |
    = help: Remove assignment to unused variable `option2_2`

gemgis\postprocessing.py:759:5: F841 Local variable `option2_3` is assigned to but never used
    |
757 |                                       "name": 'color'})
758 |
759 |     option2_3 = ET.SubElement(option2,
    |     ^^^^^^^^^ F841
760 |                               'Option',
761 |                               attrib={"value": 'bevel',
    |
    = help: Remove assignment to unused variable `option2_3`

gemgis\postprocessing.py:765:5: F841 Local variable `option2_4` is assigned to but never used
    |
763 |                                       "name": 'joinstyle'})
764 |
765 |     option2_4 = ET.SubElement(option2,
    |     ^^^^^^^^^ F841
766 |                               'Option',
767 |                               attrib={"value": '0,0',
    |
    = help: Remove assignment to unused variable `option2_4`

gemgis\postprocessing.py:771:5: F841 Local variable `option2_5` is assigned to but never used
    |
769 |                                       "name": 'offset'})
770 |
771 |     option2_5 = ET.SubElement(option2,
    |     ^^^^^^^^^ F841
772 |                               'Option',
773 |                               attrib={"value": '3x:0,0,0,0,0,0',
    |
    = help: Remove assignment to unused variable `option2_5`

gemgis\postprocessing.py:777:5: F841 Local variable `option2_6` is assigned to but never used
    |
775 |                                       "name": 'offset_map_unit_scale'})
776 |
777 |     option2_6 = ET.SubElement(option2,
    |     ^^^^^^^^^ F841
778 |                               'Option',
779 |                               attrib={"value": 'MM',
    |
    = help: Remove assignment to unused variable `option2_6`

gemgis\postprocessing.py:783:5: F841 Local variable `option2_7` is assigned to but never used
    |
781 |                                       "name": 'offset_unit'})
782 |
783 |     option2_7 = ET.SubElement(option2,
    |     ^^^^^^^^^ F841
784 |                               'Option',
785 |                               attrib={"value": '35,35,35,255',
    |
    = help: Remove assignment to unused variable `option2_7`

gemgis\postprocessing.py:789:5: F841 Local variable `option2_8` is assigned to but never used
    |
787 |                                       "name": 'outline_color'})
788 |
789 |     option2_8 = ET.SubElement(option2,
    |     ^^^^^^^^^ F841
790 |                               'Option',
791 |                               attrib={"value": 'solid',
    |
    = help: Remove assignment to unused variable `option2_8`

gemgis\postprocessing.py:795:5: F841 Local variable `option2_9` is assigned to but never used
    |
793 |                                       "name": 'outline_style'})
794 |
795 |     option2_9 = ET.SubElement(option2,
    |     ^^^^^^^^^ F841
796 |                               'Option',
797 |                               attrib={"value": outline_width,
    |
    = help: Remove assignment to unused variable `option2_9`

gemgis\postprocessing.py:801:5: F841 Local variable `option2_10` is assigned to but never used
    |
799 |                                       "name": 'outline_width'})
800 |
801 |     option2_10 = ET.SubElement(option2,
    |     ^^^^^^^^^^ F841
802 |                                'Option',
803 |                                attrib={"value": 'MM',
    |
    = help: Remove assignment to unused variable `option2_10`

gemgis\postprocessing.py:807:5: F841 Local variable `option2_11` is assigned to but never used
    |
805 |                                        "name": 'outline_width_unit'})
806 |
807 |     option2_11 = ET.SubElement(option2,
    |     ^^^^^^^^^^ F841
808 |                                'Option',
809 |                                attrib={"value": 'solid',
    |
    = help: Remove assignment to unused variable `option2_11`

gemgis\postprocessing.py:820:5: F841 Local variable `option3_1` is assigned to but never used
    |
818 |                             attrib={"type": 'Map'})
819 |
820 |     option3_1 = ET.SubElement(option3,
    |     ^^^^^^^^^ F841
821 |                               'Option', attrib={"value": '',
822 |                                                 "type": 'QString',
    |
    = help: Remove assignment to unused variable `option3_1`

gemgis\postprocessing.py:824:5: F841 Local variable `option3_2` is assigned to but never used
    |
822 |                                                 "type": 'QString',
823 |                                                 "name": 'name'})
824 |     option3_2 = ET.SubElement(option3,
    |     ^^^^^^^^^ F841
825 |                               'Option',
826 |                               attrib={"name": 'properties'})
    |
    = help: Remove assignment to unused variable `option3_2`

gemgis\postprocessing.py:828:5: F841 Local variable `option3_3` is assigned to but never used
    |
826 |                               attrib={"name": 'properties'})
827 |
828 |     option3_3 = ET.SubElement(option3,
    |     ^^^^^^^^^ F841
829 |                               'Option',
830 |                               attrib={"value": 'collection',
    |
    = help: Remove assignment to unused variable `option3_3`

gemgis\postprocessing.py:972:5: F841 Local variable `roation` is assigned to but never used
    |
970 |                   alpha=alpha[0])
971 |
972 |     roation = ET.SubElement(renderer,
    |     ^^^^^^^ F841
973 |                             'rotation',
974 |                             attrib={})
    |
    = help: Remove assignment to unused variable `roation`

gemgis\postprocessing.py:976:5: F841 Local variable `sizescale` is assigned to but never used
    |
974 |                             attrib={})
975 |
976 |     sizescale = ET.SubElement(renderer,
    |     ^^^^^^^^^ F841
977 |                               'sizescale',
978 |                               attrib={})
    |
    = help: Remove assignment to unused variable `sizescale`

gemgis\postprocessing.py:1073:58: E712 Avoid equality comparisons to `True`; use `if geo_model.surfaces.df['isFault']:` for truth checks
     |
1071 |     # Checking that the fault is a fault of the geo_model
1072 |     if isinstance(fault, str):
1073 |         if fault not in geo_model.surfaces.df['surface'][geo_model.surfaces.df['isFault'] == True].tolist():
     |                                                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ E712
1074 |             raise ValueError('Fault is not part of the GemPy geo_model')
     |
     = help: Replace with `geo_model.surfaces.df['isFault']`

gemgis\visualization.py:2948:16: F401 `mplstereonet` imported but unused; consider using `importlib.util.find_spec` to test for availability
     |
2946 |     # Trying to import mplstereonet but returning error if mplstereonet is not installed
2947 |     try:
2948 |         import mplstereonet
     |                ^^^^^^^^^^^^ F401
2949 |     except ModuleNotFoundError:
2950 |         raise ModuleNotFoundError(
     |
     = help: Remove unused import: `mplstereonet`

gemgis\web.py:200:9: F841 Local variable `__all__` is assigned to but never used
    |
198 |     try:
199 |         from owslib import util
200 |         __all__ = [util]
    |         ^^^^^^^ F841
201 |     except ModuleNotFoundError:
202 |         raise ModuleNotFoundError(
    |
    = help: Remove assignment to unused variable `__all__`

gemgis\web.py:403:9: F841 Local variable `__all__` is assigned to but never used
    |
401 |     try:
402 |         from owslib import util
403 |         __all__ = [util]
    |         ^^^^^^^ F841
404 |     except ModuleNotFoundError:
405 |         raise ModuleNotFoundError(
    |
    = help: Remove assignment to unused variable `__all__`

gemgis\web.py:551:9: F841 Local variable `__all__` is assigned to but never used
    |
549 |         from owslib import util
550 |         from owslib.wfs import WebFeatureService
551 |         __all__ = [util]
    |         ^^^^^^^ F841
552 |     except ModuleNotFoundError:
553 |         raise ModuleNotFoundError(
    |
    = help: Remove assignment to unused variable `__all__`

gemgis\web.py:624:9: F841 Local variable `__all__` is assigned to but never used
    |
622 |     try:
623 |         from owslib import util
624 |         __all__ = [util]
    |         ^^^^^^^ F841
625 |     except ModuleNotFoundError:
626 |         raise ModuleNotFoundError(
    |
    = help: Remove assignment to unused variable `__all__`

gemgis\web.py:718:9: F841 Local variable `__all__` is assigned to but never used
    |
716 |         from owslib import util
717 |         from owslib.wcs import WebCoverageService
718 |         __all__ = [util]
    |         ^^^^^^^ F841
719 |     except ModuleNotFoundError:
720 |         raise ModuleNotFoundError(
    |
    = help: Remove assignment to unused variable `__all__`

gemgis\web.py:795:9: F841 Local variable `__all__` is assigned to but never used
    |
793 |     try:
794 |         from owslib import util
795 |         __all__ = [util]
    |         ^^^^^^^ F841
796 |     except ModuleNotFoundError:
797 |         raise ModuleNotFoundError(
    |
    = help: Remove assignment to unused variable `__all__`

gemgis\web.py:885:9: F841 Local variable `__all__` is assigned to but never used
    |
883 |     try:
884 |         from owslib import util
885 |         __all__ = [util]
    |         ^^^^^^^ F841
886 |     except ModuleNotFoundError:
887 |         raise ModuleNotFoundError(
    |
    = help: Remove assignment to unused variable `__all__`

gemgis\web.py:995:9: F841 Local variable `__all__` is assigned to but never used
    |
993 |     try:
994 |         from owslib import util
995 |         __all__ = [util]
    |         ^^^^^^^ F841
996 |     except ModuleNotFoundError:
997 |         raise ModuleNotFoundError(
    |
    = help: Remove assignment to unused variable `__all__`

tests\test_gemgis.py:825:5: F811 Redefinition of unused `test_set_extent_z_data` from line 814
    |
824 | @pytest.mark.parametrize("gdf_extent", [gdf_extent])
825 | def test_set_extent_z_data(gdf_extent):
    |     ^^^^^^^^^^^^^^^^^^^^^^ F811
826 |     from gemgis import GemPyData
827 |     data = GemPyData(model_name='Model1')
    |
    = help: Remove definition: `test_set_extent_z_data`

tests\test_gemgis.py:840:5: F811 Redefinition of unused `test_set_extent_z_data` from line 825
    |
839 | @pytest.mark.parametrize("gdf_extent_points", [gdf_extent_points])
840 | def test_set_extent_z_data(gdf_extent_points):
    |     ^^^^^^^^^^^^^^^^^^^^^^ F811
841 |     from gemgis import GemPyData
842 |     data = GemPyData(model_name='Model1')
    |
    = help: Remove definition: `test_set_extent_z_data`

tests\test_raster.py:88:5: F811 Redefinition of unused `test_sample_from_array` from line 67
   |
86 |                              rasterio.open('../docs/getting_started/tutorial/data/test_raster/raster1.tif')
87 |                          ])
88 | def test_sample_from_array(gdf_interfaces1_points, dem):
   |     ^^^^^^^^^^^^^^^^^^^^^^ F811
89 |     from gemgis.raster import sample_from_array
90 |     from gemgis.vector import extract_xy
   |
   = help: Remove definition: `test_sample_from_array`

tests\test_raster.py:467:5: F811 Redefinition of unused `test_calculate_slope` from line 411
    |
465 |                              rasterio.open('../docs/getting_started/tutorial/data/test_raster/raster1.tif')
466 |                          ])
467 | def test_calculate_slope(raster):
    |     ^^^^^^^^^^^^^^^^^^^^ F811
468 |     from gemgis.raster import calculate_slope
    |
    = help: Remove definition: `test_calculate_slope`

tests\test_raster.py:982:5: F811 Redefinition of unused `test_calculate_difference` from line 964
    |
980 |                              rasterio.open('../docs/getting_started/tutorial/data/test_raster/raster1.tif')
981 |                          ])
982 | def test_calculate_difference(dem):
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^ F811
983 |     from gemgis.raster import calculate_difference
    |
    = help: Remove definition: `test_calculate_difference`

tests\test_raster.py:1111:5: F811 Redefinition of unused `test_save_raster_as_tiff` from line 1097
     |
1109 |                              np.load('../docs/getting_started/tutorial/data/test_raster/array_rbf.npy')
1110 |                          ])
1111 | def test_save_raster_as_tiff(raster):
     |     ^^^^^^^^^^^^^^^^^^^^^^^^ F811
1112 |     from gemgis.raster import save_as_tiff
     |
     = help: Remove definition: `test_save_raster_as_tiff`

tests\test_utils.py:543:5: F811 Redefinition of unused `test_set_extent_z` from line 533
    |
542 | @pytest.mark.parametrize("gdf_extent", [gdf_extent])
543 | def test_set_extent_z(gdf_extent):
    |     ^^^^^^^^^^^^^^^^^ F811
544 |     from gemgis.utils import set_extent
545 |     extent = set_extent(gdf=gdf_extent)
    |
    = help: Remove definition: `test_set_extent_z`

tests\test_utils.py:557:5: F811 Redefinition of unused `test_set_extent_z` from line 543
    |
556 | @pytest.mark.parametrize("gdf_extent_points", [gdf_extent_points])
557 | def test_set_extent_z(gdf_extent_points):
    |     ^^^^^^^^^^^^^^^^^ F811
558 |     from gemgis.utils import set_extent
559 |     extent = set_extent(gdf=gdf_extent_points)
    |
    = help: Remove definition: `test_set_extent_z`

tests\test_vector.py:1539:5: F811 Redefinition of unused `test_extract_xy_points` from line 1393
     |
1537 | ###########################################################
1538 | @pytest.mark.parametrize("gdf_interfaces1_points", [gdf_interfaces1_points])
1539 | def test_extract_xy_points(gdf_interfaces1_points):
     |     ^^^^^^^^^^^^^^^^^^^^^^ F811
1540 |     from gemgis.vector import extract_xy
1541 |     gdf_new = extract_xy(gdf=gdf_interfaces1_points)
     |
     = help: Remove definition: `test_extract_xy_points`

tests\test_vector.py:1758:5: F811 Redefinition of unused `test_extract_xy_lines` from line 1610
     |
1757 | @pytest.mark.parametrize("gdf_topo1", [gdf_topo1])
1758 | def test_extract_xy_lines(gdf_topo1):
     |     ^^^^^^^^^^^^^^^^^^^^^ F811
1759 |     from gemgis.vector import extract_xy
1760 |     gdf_new = extract_xy(gdf=gdf_topo1)
     |
     = help: Remove definition: `test_extract_xy_lines`

tests\test_vector.py:2089:5: F811 Redefinition of unused `test_extract_xy_points` from line 1539
     |
2087 | ###########################################################
2088 | @pytest.mark.parametrize("gdf_interfaces1_points", [gdf_interfaces1_points])
2089 | def test_extract_xy_points(gdf_interfaces1_points):
     |     ^^^^^^^^^^^^^^^^^^^^^^ F811
2090 |     from gemgis.vector import extract_xy
2091 |     gdf_new = extract_xy(gdf=gdf_interfaces1_points)
     |
     = help: Remove definition: `test_extract_xy_points`

tests\test_vector.py:2159:5: F811 Redefinition of unused `test_extract_xy_lines` from line 1758
     |
2158 | @pytest.mark.parametrize("gdf_interfaces1_lines", [gdf_interfaces1_lines])
2159 | def test_extract_xy_lines(gdf_interfaces1_lines):
     |     ^^^^^^^^^^^^^^^^^^^^^ F811
2160 |     from gemgis.vector import extract_xy
     |
     = help: Remove definition: `test_extract_xy_lines`

tests\test_vector.py:2266:5: F811 Redefinition of unused `test_extract_xy_lines` from line 2159
     |
2265 | @pytest.mark.parametrize("gdf_topo1", [gdf_topo1])
2266 | def test_extract_xy_lines(gdf_topo1):
     |     ^^^^^^^^^^^^^^^^^^^^^ F811
2267 |     from gemgis.vector import extract_xy
2268 |     gdf_new = extract_xy(gdf=gdf_topo1)
     |
     = help: Remove definition: `test_extract_xy_lines`

tests\test_vector.py:2302:5: F811 Redefinition of unused `test_extract_xy_lines` from line 2266
     |
2301 | @pytest.mark.parametrize("gdf_topo1", [gdf_topo1])
2302 | def test_extract_xy_lines(gdf_topo1):
     |     ^^^^^^^^^^^^^^^^^^^^^ F811
2303 |     from gemgis.vector import extract_xy
2304 |     gdf_new = extract_xy(gdf=gdf_topo1)
     |
     = help: Remove definition: `test_extract_xy_lines`

tests\test_vector.py:2342:5: F811 Redefinition of unused `test_extract_xy_geojson_multiline` from line 1795
     |
2340 |                                  '../docs/getting_started/tutorial/data/test_vector/interfaces1_lines_geojson.geojson')
2341 |                          ])
2342 | def test_extract_xy_geojson_multiline(gdf):
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ F811
2343 |     from gemgis.vector import extract_xy
2344 |     gdf_new = extract_xy(gdf=gdf)
     |
     = help: Remove definition: `test_extract_xy_geojson_multiline`

tests\test_vector.py:2771:5: F811 Redefinition of unused `test_extract_z_arrays` from line 2679
     |
2769 |                              rasterio.open('../docs/getting_started/tutorial/data/test_vector/raster1.tif')
2770 |                          ])
2771 | def test_extract_z_arrays(gdf_interfaces1_points, dem):
     |     ^^^^^^^^^^^^^^^^^^^^^ F811
2772 |     from gemgis.vector import extract_xyz
     |
     = help: Remove definition: `test_extract_z_arrays`

tests\test_vector.py:2967:5: F811 Redefinition of unused `test_extract_coordinates_points_dem_false` from line 2893
     |
2965 |                              rasterio.open('../docs/getting_started/tutorial/data/test_vector/raster1.tif')
2966 |                          ])
2967 | def test_extract_coordinates_points_dem_false(gdf_interfaces1_points, dem):
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ F811
2968 |     from gemgis.vector import extract_xyz
2969 |     gdf_new = extract_xyz(gdf=gdf_interfaces1_points, dem=dem)
     |
     = help: Remove definition: `test_extract_coordinates_points_dem_false`

tests\test_vector.py:3169:5: F811 Redefinition of unused `test_extract_coordinates_points_dem_false` from line 2967
     |
3167 |                              rasterio.open('../docs/getting_started/tutorial/data/test_vector/raster1.tif')
3168 |                          ])
3169 | def test_extract_coordinates_points_dem_false(gdf_interfaces1_points, dem):
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ F811
3170 |     from gemgis.vector import extract_xyz
3171 |     from gemgis.vector import extract_xy
     |
     = help: Remove definition: `test_extract_coordinates_points_dem_false`

tests\test_vector.py:3211:5: F811 Redefinition of unused `test_extract_coordinates_points_dem_false` from line 3169
     |
3209 |                              rasterio.open('../docs/getting_started/tutorial/data/test_vector/raster1.tif')
3210 |                          ])
3211 | def test_extract_coordinates_points_dem_false(gdf_interfaces1_points, dem):
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ F811
3212 |     from gemgis.vector import extract_xyz
3213 |     from gemgis.vector import extract_xy
     |
     = help: Remove definition: `test_extract_coordinates_points_dem_false`

tests\test_vector.py:3427:5: F811 Redefinition of unused `test_extract_z_lines_inplace` from line 3380
     |
3425 |                              rasterio.open('../docs/getting_started/tutorial/data/test_vector/raster1.tif')
3426 |                          ])
3427 | def test_extract_z_lines_inplace(gdf_interfaces1_lines, dem):
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ F811
3428 |     from gemgis.vector import extract_xyz
3429 |     gdf_new = extract_xyz(gdf=gdf_interfaces1_lines, dem=dem)
     |
     = help: Remove definition: `test_extract_z_lines_inplace`

tests\test_vector.py:3520:5: F811 Redefinition of unused `test_extract_z_points_array` from line 3474
     |
3518 |                              np.load('../docs/getting_started/tutorial/data/test_vector/array_rbf.npy')
3519 |                          ])
3520 | def test_extract_z_points_array(gdf_interfaces1_points, dem):
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ F811
3521 |     from gemgis.vector import extract_xyz
3522 |     gdf_new = extract_xyz(gdf=gdf_interfaces1_points, dem=dem, extent=[0, 972, 0, 1069])
     |
     = help: Remove definition: `test_extract_z_points_array`

tests\test_vector.py:3566:5: F811 Redefinition of unused `test_extract_z_points_array` from line 3520
     |
3564 |                              np.load('../docs/getting_started/tutorial/data/test_vector/array_rbf.npy')
3565 |                          ])
3566 | def test_extract_z_points_array(gdf_interfaces1_lines, dem):
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ F811
3567 |     from gemgis.vector import extract_xyz
3568 |     gdf_new = extract_xyz(gdf=gdf_interfaces1_lines, dem=dem, extent=[0, 972, 0, 1069])
     |
     = help: Remove definition: `test_extract_z_points_array`

Found 66 errors.
[*] 2 fixable with the `--fix` option (29 hidden fixes can be enabled with the `--unsafe-fixes` option).