-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.flake8
29 lines (28 loc) · 1.06 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
[flake8]
exclude =
*.egg-info,
.git,
.mypy_cache
.nox,
.pytest_cache,
__pycache__,
# * A001 variable is shadowing a python builtin -> we need to have "id", "filter", ...
# * A002 argument is shadowing a python builtin -> we need to have "id", "filter", ...
# * ANN101 Missing type annotation for self in method
# * ANN102 Missing type annotation for cls in class method
# * ANN401 Disallow typing.Any -> We want to use this
# * W503 line break before binary operator
# * B008 function calls for default values - this is used heavily by pydantic/fastapi
ignore = A001,A002,A003,ANN101,ANN102,ANN401,B305,C901,E704,N8,W503,B008,F405,F821
# * commands allow print statements (T201)
# * Allow undefined names in migrations (F821)
# * Allow unused imports in __init__.py (F401)
# * No annotations in tests and fixtures required (ANN)
# * Special treatment for test fixtures and tests (F811)
per-file-ignores =
__init__.py: F401
*_fixture.py: E501,ANN,F811
test_*.py: E501,ANN,F811,F401
conftest.py: E501,ANN,F811
max-complexity = 5
max-line-length = 115