-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.cfg
101 lines (97 loc) · 3.1 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]
no-isort-config = true
max-line-length = 120
max-line-complexity = 20
exclude =
.cache,
.git,
__pycache__,
old,
build,
dist,
venv
.virtualenv
.mypy_cache
ignore =
# "Coding" magic comment
C101
# Missing trailing comma in Python 3.6+
C816
# Backslash that is used for line breaking
N400
# Double quotes forbidding
Q000
# Trailing comma, supported by Black
C812, C813, C815
# RST docstrings -- not used
RST
# Docstring in `__init__`
D107
# Requires all classes to have a base class
WPS306
# Requires boolean arguments to be passed as keywords
WPS425
# f-strings forbidding
WPS305
# relative imports
WPS300
# Found context manager with too many assignments - usually good for readability
WPS316
# Found incorrect multi-line parameters - handled by black.
WPS317
# "Found incorrect order of methods in a class" – requires private methods to be after all
# public ones.
WPS338
# "Found shadowed class attribute" - false positive for dataclasses.
WPS601
# Found wrong metadata variable: __all__ (???)
WPS410
# Found a line that starts with a dot - handled by black
WPS348
# Found bad magic module function: __getattr__ (false-positive for class level attributes)
WPS413
# "Found too short name" - it's ok for list comprehensions, lambdas etc.
WPS111
# Found `finally` in `try` block without `except`
WPS501
# "Found subclassing a builtin" - it's required for typed enums.
WPS600
# "Found using `@staticmethod`" – static methods are good for self-documenting the code,
# they also provide a little bit of performance optimization.
WPS602
# W503 line break before binary operator
W503
# Missing parameter(s) in Docstring: - ctx
DAR101
# Missing docstring in magic method
D105
# Missing "Returns" in Docstring:
DAR201
# Missing "Yields" in Docstring
DAR301
# Missing exception(s) in Raises section
DAR401
# Found `%` string formatting
WPS323
# Found an unnecessary blank line before a bracket - handled by Black
WPS355
per-file-ignores=
# Using `print` in tasks, allow to have more than 10 tasks.
# WPS421 - Found wrong function call: print
tasks.py:T001,WPS202,WPS421
# S101 - using asserts.
# D103 - test docstrings.
# WPS202 - "Found too many module members"
# WPS204 - Found overused expression - This kind of DRY is not applicable for tests.
# WPS219 - "Found too deep access level"
# WPS226 - Found string constant over-use
# WPS432 - Found magic number.
# WPS441 - "Found control variable used after block" - normal for mock patches.
# WPS442 - Found outer scope names shadowing for module fixtures
# WPS520 - "found compare with falsy constant"
./tests/unit/test_*.py:S101,D103,WPS202,WPS204,WPS219,WPS226,WPS432,WPS441,WPS442,WPS520
./tests/unit/**/test_*.py:S101,D103,WPS202,WPS204,WPS219,WPS226,WPS432,WPS441,WPS442,WPS520
[mypy]
python_version = 3.7
show_error_context = True
ignore_missing_imports = True