-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[flake8-builtins
] Default to non-strict checking (A005
)
#16125
base: main
Are you sure you want to change the base?
Conversation
|
code | total | + violation | - violation | + fix | - fix |
---|---|---|---|---|---|
A005 | 104 | 0 | 104 | 0 | 0 |
Linter (preview)
✅ ecosystem check detected no linter changes.
Did you look through the ecosystem check? We'll have to wait with merging this until the 0.10 release. |
I just looked through the ecosystem check and it looks like what I expected. There are a lot of deeply nested I labeled with |
It should be fine. I added the |
Summary
This PR changes the default value of
lint.flake8-builtins.builtins-strict-checking
added in #15951 fromtrue
tofalse
. This also allows simplifying the default option logic and removes the dependence on preview mode.#15399 was already closed by #15951, but this change will finalize the behavior mentioned in #15399 (comment).
As an example, strict checking flags modules based on their last component, so
utils/logging.py
triggers A005. Non-strict checking checks the path to the module, soutils/logging.py
is allowed (this is the example and desired behavior from #15399 exactly) but a top-levellogging.py
orlogging/__init__.py
is still disallowed.Test Plan
Existing tests from #15951 and #16006, with the snapshot updated in
a005_module_shadowing_strict_default
to reflect the new default.