Add a code linting tool chain
- use flake8 as the main and pylint as the auxiliary linter - install flake8 with the following plug-ins: + flake8-annotations => enforce type annotations for functions/classes + flake8-black => ensure black would not make any changes + flake8-expression-complexity + wemake-python-styleguide, which packages the following: * darglint * flake8-bandit * flake8-broken-line * flake8-bugbear * flake8-commas * flake8-comprehensions * flake8-debugger * flake8-docstrings * flake8-eradicate * flake8-isort * flake8-rst-docstrings * flake8-string-format * flake8-quotes * pep8-naming - configure flake8 & friends in a rather explicit and strict way - isort needed to be downgraded to ^4.3.21 due to a conflict with pylint and wemake-python-styleguide: + provide TODO's to remove the parts that "fix" isort - use mypy for static type checking - add a nox session "lint" that runs flake8, mypy, and pylint - lint all source files
Loading
Please register or sign in to comment