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

Trailing comment prevents removal of unused imports #106

Open
Zac-HD opened this issue Mar 19, 2022 · 0 comments
Open

Trailing comment prevents removal of unused imports #106

Zac-HD opened this issue Mar 19, 2022 · 0 comments

Comments

@Zac-HD
Copy link
Member

Zac-HD commented Mar 19, 2022

For example, I would expect

import unused_module  # lorem ipsum

to be either deleted entirely or replaced with

# lorem ipsum

but isort skips all import lines with comments, including from a import b lines. This both seems like a bug in itself, and makes autoflake more difficult to combine with other tools.

Zac-HD added a commit to Zac-HD/shed that referenced this issue Mar 19, 2022
I'm hoping to instead get this fixed upstream with PyCQA/autoflake#106 or PyCQA/isort#1913
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant