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

Fail to remove import matplotlib.pyplot as plt #284

Closed
Tracked by #271
ThomasParistech opened this issue Mar 3, 2023 · 3 comments
Closed
Tracked by #271

Fail to remove import matplotlib.pyplot as plt #284

ThomasParistech opened this issue Mar 3, 2023 · 3 comments
Assignees
Labels
bug Something isn't working changelog Changes should be written to the changelog file. test
Milestone

Comments

@ThomasParistech
Copy link

Thanks for the great lib.

However when I run the command unimport $(find . -name '*.py') --remove, it always fails to remove unused import matplotlib.pyplot as plt.

This is the only bug that I've noticed, but It happens systematically with this import.

Any idea ?

I'm using unimport==0.14.1.

Many thanks

@hakancelikdev
Copy link
Owner

Thanks for your kind words I am thrilled to hear that! and thanks you open the issue,

This problem occurs when your import type is as follows, I will solve it as soon as possible, in addition, in the new version of unimport, you no longer need to use the --remove flag, --remove is now the default.

import a.b as x

@hakancelikdev hakancelikdev self-assigned this Mar 29, 2023
@hakancelikdev hakancelikdev added bug Something isn't working changelog Changes should be written to the changelog file. test labels Mar 29, 2023
@hakancelikdev hakancelikdev added this to the 1.0.0 milestone Mar 29, 2023
@hakancelikdev hakancelikdev mentioned this issue Mar 29, 2023
9 tasks
hakancelikdev added a commit that referenced this issue Mar 29, 2023
@hakancelikdev
Copy link
Owner

Can you try again, after installing https://pypi.org/project/unimport/0.15.0/

@ThomasParistech
Copy link
Author

Can you try again, after installing https://pypi.org/project/unimport/0.15.0/

It works, many thanks 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working changelog Changes should be written to the changelog file. test
Projects
Status: Done
Development

No branches or pull requests

2 participants