-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathsetup.cfg
101 lines (90 loc) · 2.58 KB
/
setup.cfg
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
[flake8]
max-line-length = 88
select = C,E,F,W,B,B950
# it's not a bug that we aren't using all of hacking, ignore:
# F812: list comprehension redefines ...
# H101: Use TODO(NAME)
# H202: assertRaises Exception too broad
# H233: Python 3.x incompatible use of print operator
# H301: one import per line
# H306: imports not in alphabetical order (time, os)
# H401: docstring should not start with a space
# H403: multi line docstrings should end on a new line
# H404: multi line docstring should start without a leading new line
# H405: multi line docstring summary not separated with an empty line
# H501: Do not use self.__dict__ for string formatting
# W503: line break before binary operator
# E231: missing whitespace after ','
ignore = D203,F812,H101,H202,H233,H301,H306,H401,H403,H404,H405,H501,W503,E231
# C901: is too complex
extend-ignore =
E203,
E501,
C901
per-file-ignores =
# F401: imported but unused
# F403: import * used; unable to detect undefined names
__init__.py: F401,F403
# F405: XXX may be undefined, or defined from star imports
api_ci.py: F405
api_dev.py: F405
api_stag.py: F405
api_test.py: F405
prod.py: F405
local.py: F405, E121
local-default.py: F405
exclude =
.tox,
*/migrations/*,
*/static/CACHE/*,
docs,
node_modules,
venv,
scripts/*,
misc/local/*,
# No need to traverse our git directory
.git,
# There's no value in checking cache directories
__pycache__,
# The conf file is mostly autogenerated, ignore it
docs/source/conf.py,
# The old directory contains Flake8 2.0
old,
# This contains our built documentation
build,
# This contains builds of flake8 that we don't want to check
dist
max-complexity = 10
[pycodestyle]
max-line-length = 88
exclude = .tox,.git,*/migrations/*,*/static/CACHE/*,docs,node_modules,venv
[mypy]
python_version = 3.11
ignore_missing_imports = True
warn_unused_configs = True
plugins = mypy_django_plugin.main
show_column_numbers = True
follow_imports = normal
# be strict
disallow_untyped_calls = True
warn_return_any = True
strict_optional = True
warn_no_return = True
warn_redundant_casts = True
warn_unused_ignores = True
disallow_untyped_defs = True
check_untyped_defs = True
no_implicit_reexport = True
no_implicit_optional = False
[mypy.plugins.django-stubs]
django_settings_module = "tests.easy_app"
[mypy-*.migrations.*]
# Django migrations should not produce any errors:
ignore_errors = True
[mypy-tests.*]
ignore_errors = True
[coverage:run]
include = easy/*
omit = *migrations*, *tests*
plugins =
django_coverage_plugin