1
0
mirror of https://github.com/EDCD/EDMarketConnector.git synced 2025-04-13 07:47:14 +03:00

Added noqa, docstring, and fstring linters

Additionally this removed one linter that was for preferring .format to
modulo formatting, as the new fstring linter does both
This commit is contained in:
A_D 2020-09-09 17:13:13 +02:00
parent b50ed893ae
commit 054c2a09c7
No known key found for this signature in database
GPG Key ID: 4BE9EB7DF45076C4
2 changed files with 16 additions and 4 deletions

16
.flake8
View File

@ -17,9 +17,6 @@ per-file-ignores = ./EDMC.py:E402
# https://github.com/Melevir/flake8-cognitive-complexity
# Provides cognitive complexity checking
# https://github.com/gforcada/flake8-pep3101
# Marks modulo-formatting as an error, as .format formatting is clearer and preferred in this codebase
# https://github.com/adamchainz/flake8-comprehensions
# Checks list/dict/set/* comprehensions for simplification or replacement
@ -29,5 +26,18 @@ per-file-ignores = ./EDMC.py:E402
# https://github.com/best-doctor/flake8-annotations-coverage
# Checks code for type annotations
# https://pypi.org/project/flake8-isort/
# Ensures imports are well sorted
# https://pypi.org/project/flake8-noqa/
# Ensures that noqa statements are correctly formed
# https://github.com/MichaelKim0407/flake8-use-fstring
# Prefers fstrings over .format and modulo based formatters
max-cognitive-complexity = 15
# require that all noqa directves disable specific errors
noqa-require-code = True
docstring-convention = numpy

View File

@ -3,11 +3,13 @@ flake8==3.8.3
flake8-annotations-coverage==0.0.4
flake8-cognitive-complexity==0.0.2
flake8-comprehensions==3.2.3
flake8-pep3101==1.3.0
flake8-polyfill==1.0.2
flake8-json
flake8-isort==3.0.1
pep8-naming==0.11.1
flake8-noqa==1.0.5
flake8-docstrings==1.5.0
flake8-use-fstring==1.1
# Code formatting tools
autopep8==1.5.3