-
-
Notifications
You must be signed in to change notification settings - Fork 309
/
.flake8
121 lines (117 loc) · 4.54 KB
/
.flake8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
[flake8]
ignore =
# whitespace before ':' (Black)
E203,
# line break before binary operator (Black)
W503,
per-file-ignores =
# Files and directories which need fixes or specific exceptions
# Many of these ignores can and should be removed and the problem fixed.
# Quick reference for some of the most common errors
# F403 star import used; unable to detect undefined names
# F405 variable may be undefined, or defined from star imports
# E402 module level import not at top of file
# E501 line too long
# E722 do not use bare 'except'
# W605 invalid escape sequence
# F821 undefined name 'unicode'
# F841 local variable assigned to but never used
# E741 ambiguous variable name 'l'
man/build_html.py: E501
man/build_md.py: E501
doc/python/m.distance.py: E501
gui/scripts/d.wms.py: E501
gui/wxpython/image2target/g.gui.image2target.py: E501
gui/wxpython/photo2image/g.gui.photo2image.py: E501
gui/wxpython/psmap/*: E501
gui/wxpython/vdigit/*: F841, E722, F405, F403
gui/wxpython/animation/g.gui.animation.py: E501
gui/wxpython/tplot/g.gui.tplot.py: E501
gui/wxpython/iclass/frame.py: F405, F403
gui/wxpython/iclass/g.gui.iclass.py: E501
gui/wxpython/iclass/statistics.py: F841, F405, F403
gui/wxpython/wxplot/histogram.py: E722
gui/wxpython/wxplot/profile.py: F841, E722
gui/wxpython/wxplot/base.py: F841, E722
gui/wxpython/location_wizard/dialogs.py: F841
gui/wxpython/location_wizard/wizard.py: E722
gui/wxpython/mapdisp/main.py: E722
gui/wxpython/mapdisp/test_mapdisp.py: E501
gui/wxpython/mapdisp/statusbar.py: F841
gui/wxpython/mapswipe/g.gui.mapswipe.py: E501
gui/wxpython/mapwin/base.py: E722
gui/wxpython/mapwin/buffered.py: E722
gui/wxpython/mapwin/graphics.py: E722
gui/wxpython/startup/locdownload.py: E722, E402
gui/wxpython/timeline/g.gui.timeline.py: E501
gui/wxpython/tools/build_modules_xml.py: E722
gui/wxpython/web_services/cap_interface.py: E501
gui/wxpython/web_services/widgets.py: F841, E402
# Generated file
gui/wxpython/menustrings.py: E501
# F821 undefined name 'cmp'
# https://github.com/OSGeo/grass/issues/1809
python/grass/pydispatch/saferef.py: F821
# C wrappers call libgis.G_gisinit before importing other modules.
# TODO: Is this really needed?
python/grass/pygrass/vector/__init__.py: E402
python/grass/pygrass/raster/__init__.py: E402
python/grass/pygrass/vector/__init__.py: E402
python/grass/pygrass/raster/category.py: E721
python/grass/pygrass/utils.py: E402
python/grass/temporal/abstract_space_time_dataset.py: E722
python/grass/temporal/c_libraries_interface.py: E722
python/grass/temporal/core.py: E722
python/grass/temporal/datetime_math.py: E722
python/grass/temporal/spatial_topology_dataset_connector.py: E722
python/grass/temporal/temporal_algebra.py: E722
python/grass/temporal/temporal_granularity.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
# 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/temporal/__init__.py: F401, F403
# E402 module level import not at top of file
scripts/r.semantic.label/r.semantic.label.py: E501
scripts/g.extension/g.extension.py: E501
scripts/v.unpack/v.unpack.py: E501
scripts/v.import/v.import.py: E501
scripts/db.univar/db.univar.py: E501
scripts/i.pansharpen/i.pansharpen.py: E501
scripts/v.what.strds/v.what.strds.py: E501
# Line too long (esp. module interface definitions)
scripts/*/*.py: E501
temporal/t.rast.to.vect/t.rast.to.vect.py: E501
temporal/t.vect.algebra/t.vect.algebra.py: E501
temporal/t.rast.what/t.rast.what.py: E501
# Line too long (esp. module interface definitions)
temporal/*/*.py: E501
max-line-length = 88
# Remember to remove the exclusions from .pre-commit-config.yaml when removing here
exclude =
.git,
__pycache__,
.env,
.venv,
env,
venv,
ENV,
env.bak,
venv.bak,
# Build directories
bin.*,
dist.*,
OBJ.*,
# Test output directory
testreport,
# Not yet compliant
python/libgrass_interface_generator,
# No tests checked for now
testsuite,
builtins =
_