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
Commented Import sorting #1396
Comments
Hi @jameswinegar, I'm sorry you are getting that incorrect grouping! I added a test case with the exact code and settings that you shared to the isort regression test suite and am unable to reproduce: ff1ccda. Is it possible that you encountered this on an older version of isort or that there are additional settings used beyond those shared? If updating to the latest isort version doesn't fix your issue, posting the output of Thanks! ~Timothy |
I wasn't able to reproduce either with just the import header. I have found a different bug when trying to reproduce. For now, let's assume that the original one I tried to articulate is solved. Given the below
However, with this modification
Config
|
Hi @jameswinegar, Thanks for digging further into your issue! Using the above example, I was able to add an additional regression test and resolve that issue. It is fixed in develop and will be deployed with release 5.5.0 of isort. Thanks! ~Timothy |
Just encountered this issue (semicolon breaking sort), tracked it's cause down and then was pleased to find it's already been fixed! |
This change has just been deployed to PyPI in version 5.5.0 Thanks! ~Timothy |
We've been using isort significantly across projects recently, and we've seen significant improvement in the capabilities.
We have one sticking issue across projects with commented imports. It would be nicer if these commented imports were section aware. Below is our most common example, but it also applies to a strictly commented import as well.
Setup.cfg
Before isort
After isort (Actual)
After isort (Expected)
The text was updated successfully, but these errors were encountered: