-
-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pylama does not seem to be maintained anymore (pydocstyle compatibility issues are not addressed etc...). Plus, ruff is way more faster!
- Loading branch information
1 parent
1e0240c
commit 006d092
Showing
7 changed files
with
66 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,6 +46,7 @@ coverage.xml | |
*.cover | ||
.hypothesis/ | ||
.pytest_cache/ | ||
.ruff_cache/ | ||
|
||
# Translations | ||
*.mo | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,55 @@ | ||
[tool.black] | ||
line-length = 100 | ||
exclude = "venv/" | ||
exclude = "venv/" | ||
|
||
[tool.isort] | ||
profile = "black" | ||
multi_line_output = 3 | ||
skip_gitignore = true | ||
skip = ".bzr,.direnv,.eggs,.git,.hg,.mypy_cache,.nox,.pants.d,.svn,.tox,.venv,_build,buck-out,build,dist,node_modules,venv,migrations,urls.py" | ||
|
||
[tool.ruff] | ||
select = [ | ||
"E", # pycodestyle errors | ||
"W", # pycodestyle warnings | ||
"F", # pyflakes | ||
"C", # flake8-comprehensions | ||
"B", # flake8-bugbear | ||
"C4", # flake8-comprehensions | ||
"G", # flake8-logging-format | ||
"S", # bandit | ||
"PL" # pylint | ||
] | ||
ignore = [ | ||
"E501", # line too long, handled by black | ||
"C901", # function is too complex | ||
"PLR2004", # magic value used in comparison | ||
"PLR1711", # useless `return` statement at end of function | ||
"PLC1901", # compare-to-empty-string | ||
"PLR0911", # too many return statements | ||
"PLR0912", # too many branches | ||
"PLR0915", # too many statements | ||
"B009", # do not call getattr with a constant attribute value | ||
"B904", # raise without from inside except | ||
] | ||
line-length = 100 | ||
|
||
[tool.ruff.pylint] | ||
max-args = 10 | ||
|
||
[tool.ruff.per-file-ignores] | ||
"__init__.py" = ["F401"] | ||
"tests/*.py" = ["E402", "S", "PL"] | ||
|
||
[tool.mypy] | ||
# error whenever it encounters a function definition without type annotations | ||
disallow_untyped_defs = true | ||
# error whenever a function with type annotations calls a function defined without annotations | ||
disallow_untyped_calls = true | ||
# stop treating arguments with a None default value as having an implicit Optional type | ||
no_implicit_optional = true | ||
# error whenever your code uses an unnecessary cast that can safely be removed | ||
warn_redundant_casts = true | ||
|
||
[tool.pytest.ini_options] | ||
asyncio_mode = "strict" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,5 @@ | ||
-r base.txt | ||
-r tests.txt | ||
black | ||
invoke | ||
isort | ||
pdbpp | ||
pre-commit | ||
pydocstyle<6.2.0 # because of https://github.com/PyCQA/pydocstyle/issues/621 | ||
pylama | ||
pylint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,6 @@ | ||
black | ||
isort | ||
pylint | ||
pytest | ||
pytest-mock | ||
pytest-mock | ||
ruff |