-
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
] Match upstream module name comparison (A005
)
#16006
Conversation
See #15951 for the original discussion and reviews. This is just the first half of that PR (reaching parity with `flake8-builtins` without adding any new configuration options) split out for nicer changelog entries.
|
code | total | + violation | - violation | + fix | - fix |
---|---|---|---|---|---|
A005 | 34 | 26 | 8 | 0 | 0 |
Linter (preview)
ℹ️ ecosystem check detected linter changes. (+26 -8 violations, +0 -0 fixes in 4 projects; 51 projects unchanged)
apache/airflow (+20 -8 violations, +0 -0 fixes)
ruff check --no-cache --exit-zero --ignore RUF9 --no-fix --output-format concise --preview --select ALL
+ airflow/api_fastapi/logging/__init__.py:1:1: A005 Module `logging` shadows a Python standard-library module + airflow/io/__init__.py:1:1: A005 Module `io` shadows a Python standard-library module + airflow/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module - providers/common/io/src/airflow/providers/common/io/assets/__init__.py:1:1: A005 Module `io` shadows a Python standard-library module - providers/common/io/src/airflow/providers/common/io/assets/assets/__init__.py:1:1: A005 Module `io` shadows a Python standard-library module - providers/common/io/src/airflow/providers/common/io/operators/__init__.py:1:1: A005 Module `io` shadows a Python standard-library module - providers/common/io/src/airflow/providers/common/io/xcom/__init__.py:1:1: A005 Module `io` shadows a Python standard-library module + providers/common/io/tests/provider_tests/common/io/__init__.py:1:1: A005 Module `io` shadows a Python standard-library module + providers/google/src/airflow/providers/google/cloud/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module + providers/google/tests/provider_tests/google/cloud/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module + providers/hashicorp/src/airflow/providers/hashicorp/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module + providers/hashicorp/tests/provider_tests/hashicorp/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module - providers/http/src/airflow/providers/http/hooks/__init__.py:1:1: A005 Module `http` shadows a Python standard-library module - providers/http/src/airflow/providers/http/operators/__init__.py:1:1: A005 Module `http` shadows a Python standard-library module - providers/http/src/airflow/providers/http/sensors/__init__.py:1:1: A005 Module `http` shadows a Python standard-library module - providers/http/src/airflow/providers/http/triggers/__init__.py:1:1: A005 Module `http` shadows a Python standard-library module + providers/http/tests/provider_tests/http/__init__.py:1:1: A005 Module `http` shadows a Python standard-library module + providers/opsgenie/src/airflow/providers/opsgenie/typing/__init__.py:1:1: A005 Module `typing` shadows a Python standard-library module + providers/opsgenie/tests/provider_tests/opsgenie/typing/__init__.py:1:1: A005 Module `typing` shadows a Python standard-library module + providers/src/airflow/providers/amazon/aws/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module + providers/src/airflow/providers/microsoft/azure/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module + providers/tests/amazon/aws/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module + providers/tests/email/__init__.py:1:1: A005 Module `email` shadows a Python standard-library module + providers/tests/microsoft/azure/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module + providers/yandex/src/airflow/providers/yandex/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module + providers/yandex/tests/provider_tests/yandex/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module + tests/io/__init__.py:1:1: A005 Module `io` shadows a Python standard-library module + tests/secrets/__init__.py:1:1: A005 Module `secrets` shadows a Python standard-library module
bokeh/bokeh (+3 -0 violations, +0 -0 fixes)
ruff check --no-cache --exit-zero --ignore RUF9 --no-fix --output-format concise --preview --select ALL
+ examples/interaction/widgets/fileinput.py:1:1: A005 Module `fileinput` shadows a Python standard-library module + src/bokeh/io/__init__.py:1:1: A005 Module `io` shadows a Python standard-library module + src/bokeh/models/annotations/html/__init__.py:1:1: A005 Module `html` shadows a Python standard-library module
latchbio/latch (+2 -0 violations, +0 -0 fixes)
ruff check --no-cache --exit-zero --ignore RUF9 --no-fix --output-format concise --preview
+ src/latch/idl/core/types.py:1:1: A005 Module `types` shadows a Python standard-library module + src/latch/types/__init__.py:1:1: A005 Module `types` shadows a Python standard-library module
zulip/zulip (+1 -0 violations, +0 -0 fixes)
ruff check --no-cache --exit-zero --ignore RUF9 --no-fix --output-format concise --preview --select ALL
+ zerver/webhooks/json/__init__.py:1:1: A005 Module `json` shadows a Python standard-library module
Changes by rule (1 rules affected)
code | total | + violation | - violation | + fix | - fix |
---|---|---|---|---|---|
A005 | 34 | 26 | 8 | 0 | 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for taking the time to split this into its own PR!
crates/ruff_linter/src/rules/flake8_builtins/rules/stdlib_module_shadowing.rs
Outdated
Show resolved
Hide resolved
Co-authored-by: Micha Reiser <micha@reiser.io>
I just did a manual |
See #15951 for the original discussion and reviews. This is just the first half of that PR (reaching parity with
flake8-builtins
without adding any new configuration options) split out for nicer changelog entries.For posterity, here's a script for generating the module structure that was useful for interactive testing and creating the table here. The results for this branch are the same as the
Strict
column there, as expected.