Closed danrauch closed 2 years ago
I'll need to do some additional testing, but I suspect the CLI call that gets generated from #335 is causing any exclude
directives in the config file to get overwritten.
flake8 ... --config=XXX --exclude=XXX
There are three some approaches I can see to resolve this:
extend-exclude
in the config fileextend-exclude
when appending to CLI args (since it gets appended after the config file)exclude
args, and extend the list sent to the CLI exclude
arg instead.I would think (2) would be good, but it will change behavior a bit, specifically, in the case where the config file doesn't have an exclude
directive, the default excludes for flake8 will be in play when they wouldn't before: .svn,CVS,.bzr,.hg,.git,__pycache__,.tox,.nox,.eggs,*.egg
, it's an acceptable trade-off to me.
(1) and (2) don't work.
We'll need to implement (3)
Edit: I'm implementing a fix
Since commit a72d149eac6cebdcf6e47cf4a6feaf46ed7778d8 "exclude" parameters defined in the ament_flake8.ini file are ignored.
Steps to reproduce: