Add bandit and flake8 lint run into tox.ini

This commit is contained in:
Dmitri Bogomolov 2021-11-17 20:35:53 +02:00
parent 5a167f45c7
commit b67f86146e
Signed by untrusted user: g1itch
GPG Key ID: 720A756F18DEED13
2 changed files with 11 additions and 2 deletions

View File

@ -8,6 +8,7 @@ max-line-length = 119
[flake8]
max-line-length = 119
exclude = bitmessagecli.py,bitmessagecurses,bitmessageqt,tests,umsgpack
ignore = E722,F841,W503
# E722: pylint is preferred for bare-except
# F841: pylint is preferred for unused-variable

12
tox.ini
View File

@ -23,8 +23,16 @@ skip_install = true
commands = python pybitmessage/bitmessagemain.py -t
[testenv:reset]
deps = coverage
commands = coverage erase
deps =
coverage
bandit
flake8
commands =
coverage erase
bandit -r --exit-zero -s B105,B301,B411,B413,B608 \
-x checkdeps.*,bitmessagecurses,bitmessageqt,tests pybitmessage
flake8 pybitmessage --count --select=E9,F63,F7,F82 \
--show-source --statistics
[testenv:stats]
deps = coverage