Not exactly an answer to the question you posed, but I found myself in a similar situation not long ago where I wanted to add flake8 to CI for a large codebase that had many violations to the rules we wanted to enforce. I found it useful to automatically add a #noqa to the preexisting violations before turning flake8 on so that no new violations could be introduced while the others were handled or ignored.
I have a small script which does that in-place if you think that would be helpful (https://gist.github.com/AlexRiina/d8dfd39d2c6c4b121c8776070a2272dc) which you can run like
flake8 > flake8_violations python noqaer.py
(standard warning that running random scripts on your codebase without understanding what they do is a bad idea and that this is provided without warranty that it'll work and not mess up your codebase)
On Fri, Jan 14, 2022, 8:18 AM Kristoffel Pirard firstname.lastname@example.org wrote:
You're seeking a technical solution to unreasonable requests being made by people of your project. Set boundaries. Put your foot down.
I was about to answer something like this: the team has to follow. As all changes, though, this goes with some struggle.
Stuff that may help resolving that struggle:
- help them configure their beloved editors
- help them avoid mistakenly committing: https://pre-commit.com/ helped
us a lot
- stick to an agreed-upon version of flake8
Kind regards Kristoffel _______________________________________________ code-quality mailing list -- email@example.com To unsubscribe send an email to firstname.lastname@example.org https://mail.python.org/mailman3/lists/code-quality.python.org/ Member address: email@example.com