emanspeaks / pyls-flake8

Python Language Server plugin for Flake8
MIT License
24 stars 5 forks source link

Urecognized arguments with flake8 7.0.0 #12

Open e11bits opened 9 months ago

e11bits commented 9 months ago

With flake8 version 7.0.0 the settings from a setup.cfg are not properly converted to arguments for flake8:

[flake8]
exclude = build,.git,.tox,./tests/.env
extend-ignore = E203
max-line-length = 88
per-file-ignores =
    django/core/cache/backends/filebased.py:W601
    django/core/cache/backends/base.py:W601
    django/core/cache/backends/redis.py:W601
    tests/cache/tests.py:W601

Will result in an error:

flake8: error: unrecognized arguments: --extendIgnore=E203 --perFileIgnores=django/core/cache/backends/filebased.py:W601,django/core/cache/backends/base.py:W601,django/core/cache/backends/redis.py:W601,tests/cache/tests.py:W601

The call should be instead:

flake8 --extend-ignore=E203 --per-file-ignores=django/core/cache/backends/filebased.py:W601,django/core/cache/backends/base.py:W601,django/core/cache/backends/redis.py:W601,tests/cache/tests.py:W601 some.py
feakuru commented 8 months ago

can confirm that this also happens for setting extend-ignore in the .flake8 file