Skip to content
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

[pep8-naming] Don't flag from imports following conventional import names (N817) #12946

Merged
merged 3 commits into from
Aug 17, 2024

Conversation

MichaReiser
Copy link
Member

Summary

Fixes #12940

#12922 changes N817 to not flag imports that follow an import convention.
I missed to handle from .. import imports as part of this PR. This PR implements the same logic for from .. import imports.

Test Plan

Added test

@MichaReiser MichaReiser added the bug Something isn't working label Aug 17, 2024
Copy link
Contributor

github-actions bot commented Aug 17, 2024

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

✅ ecosystem check detected no linter changes.

@MichaReiser MichaReiser enabled auto-merge (squash) August 17, 2024 11:53
@MichaReiser MichaReiser merged commit 96802d6 into main Aug 17, 2024
17 checks passed
@MichaReiser MichaReiser deleted the fix-n817-from-import branch August 17, 2024 12:05
@darosio
Copy link

darosio commented Aug 21, 2024

Could you please confirm that this fix is working also for jupyter (.ipynb) files?
Thank you.

@dhruvmanila
Copy link
Member

@darosio I think this should work for Jupyter notebooks as well. Is there an issue that you're facing?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

N817 not correctly detecting from xml.etree import ElementTree as ET
4 participants