[flake8] max-line-length = 100 exclude = fietsboek/alembic extend-ignore = E203 per-file-ignores = fietsboek/models/__init__.py:F401 [tox] envlist = python,pylint,pylint-tests,flake,mypy,black,isort # This can be removed in tox 4 as it will be the default: isolated_build = true [testenv] deps = poetry skip_install = true passenv = TERM commands_pre = poetry install -v --with testing commands = pytest {posargs} [testenv:pylint] commands_pre = poetry install -v --with linters commands = pylint --rcfile=pylint.toml fietsboek [testenv:pylint-tests] allowlist_externals = bash commands_pre = poetry install -v --with linters,testing commands = bash -c "pylint --rcfile=pylint.tests.toml tests/**/*.py" [testenv:flake] # This is a bit of a hack since flake8 specifies Python 3.8 as minimum required # version, while fietsboek only specifices 3.7. Thus, we manually install # flake8 via pip and bypass poetry's locking- commands_pre = poetry install -v pip install flake8 commands = flake8 fietsboek [testenv:sphinx] allowlist_externals = make changedir={toxinidir}{/}doc commands_pre = poetry install -v --with docs commands = sphinx-apidoc -d 1 -f -M -e -o developer/module/ ../fietsboek "upd_*" make html [testenv:mypy] commands_pre = poetry install --with types commands = mypy fietsboek [testenv:black] deps = black commands_pre = commands = black --diff --check fietsboek [testenv:isort] deps = isort commands_pre = commands = isort --check --diff fietsboek