Having flake8 extensions install at system level will break projects and there is no way to disable them
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 3.8k
- Forks
- 356
- PR merge metrics
- No merged PRs in 30d
Description
In GitLab by @ssbarnea on Apr 30, 2016, 14:27
Here is a very simple to replicate use case, just install flake8-docstrings and now run flake8 on any project that was already using it.
You will have a change of over 99% to fail passing the flake8 tests, and there is no way to disable those plugins from inside the setup.cfg.
I raise a bug month than a month ago on flake8-docstrigs regarding this issue and got no reply at all, it seems that the project not maintained at all.
Assuming that that's not an isolated case we need a way to assure that the linting settings are locked within the setup.cfg, so the final result will not depend on whichever additional modules you may have installed on your system-modules.
I know that someone with inevitably try to propose a virtual environment with --no-site-packages but please remember that those are not always possible, there are several use-cases where people are forced to import system-packages (like on continous integration systems where you cannot afford to increase the footprint of each build with 500MB just because your projects is using numpy and pandas).
Flake8 needs an option to tell it to use a specific list of plugins and to ignore others.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue by installing flake8-docstrings and running flake8 on a project with settings in setup.cfg. Start by tracing how flake8 discovers plugins and reads setup.cfg, then define how an explicit plugin list or ignore setting should behave. Done means system-installed extensions no longer change results when the project configuration excludes them.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100