Move Pylint config from the Makefile to pyproject.toml
pyproject.toml
Pylint 2.5.0 adds pyproject.toml
support.
-
Add pylint rules into the pyproject.toml
file instead of the.pylintrc
. Example. -
Remove now useless configuration (enabled, disabled, jobs) to pylint
make rule
New reports
Passing the (de)activations from the CLI to the pyproject.toml
causes R0801
and R0401
Fix following issues:
-
Fix R0801: Similar lines in 2 files
coming from bma jsonschema definitions where we most likely won't fix -
Fix examples/load_scuttlebutt_file.py:1:0: R0401: Cyclic import (duniterpy.key -> duniterpy.key.ascii_armor) (cyclic-import)
.pylintrc
.pylintrc
-
Commit .pylintrc
configuration file as follow: pylint --generate-rcfile > .pylintrc
pylint --disable=C,R0902,R0903,R0904,R0912,R0913,R0914,R0915,W0613 --enable=C0121,C0202,C0321 --jobs=0 --generate-rcfile > .pylintrc
References
- https://github.com/PyCQA/pylint/issues/617
- https://github.com/laike9m/Cyberbrain/blob/master/pyproject.toml#L50-L54
- https://github.com/search?l=TOML&q=%22tool.pylint%22&type=Code
- https://github.com/PyCQA/pylint/issues/3181
- https://github.com/PyCQA/pylint/issues/3630
- https://github.com/PyCQA/pylint/blob/master/doc/user_guide/run.rst
Edited by Moul