exclude-setting has no effect
woutervh opened this issue · 3 comments
woutervh commented
platform linux -- Python 3.5.5, pytest-3.5.0, py-1.5.3, flake8-1.0.0,
[flake8]
max-line-length = 120
exclude=.git,__pycache__,vendor
[tool:pytest]
flake8-exclude=.git,__pycache__,vendor
when running pytest --flake8 with config above, my vendor-package is not excluded.
these settings do not seem to have any effect.
cblegare commented
I also think I have this issue. Flake8 checks takes forever when run with pytest
tholo commented
The exclude setting in [flake8] is used when running flake8 independently. When running under pytest, you want to use "norecursedirs" setting in [tool:pytest], like:
[flake8]
exclude = .venv,.tox,.git,dist,build
[tool:pytest]
norecursedirs = .venv .tox .git dist build
danmichaelo commented
Hm, that's not really a solution if you want to exclude the test directory. I was expecting something like this to work:
[pytest]
flake8-max-line-length = 100
flake8-ignore = E501 W602 W503 F403
flake8-exclude = test
but it didn't.