-
Notifications
You must be signed in to change notification settings - Fork 90
Update isort command #137
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
Update isort command #137
Conversation
lovelydinosaur
left a comment
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.
Seems legit to me. Anyone else have an issue with this?
| force_grid_wrap=0 | ||
| include_trailing_comma=True | ||
| known_first_party=h11, test | ||
| known_third_party=pytest |
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.
Aren't these still valid and useful?
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.
They're now unnecessary as any imports from the directories that isort is sorting will be considered first party. The options can be left but they will serve no function.
Let me know if you want me to remove them.
|
@memst Would it be easier to just use |
|
Removing all of the config could be a good idea. The only option that currently does something for the repository and isn't included in
Currently from typing import Any, cast, Dict, List, Tuple, UnionBlack (also default) from typing import Any, Dict, List, Tuple, Union, castComplete diff with `--profile Black`:The option can be added through commandline ( isort --profile black --dt h11 bench examples fuzzOther settings that would change, but don't impact the current code: |
949d06f to
b9f99b9
Compare
pquentin
left a comment
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.
Looks good to me! (But you'll need an approval from someone on the python-hyper org)
|
I think you also need to update the tox isort command. |
|
Thanks |
Isort 5.0.0 has been released over a year ago and many options have been deprecated as they are now the default behaviour.
Current command for isort in
CONTRIBUTING.mdcauses an error:The PR removes all arguments that are unnecessary in the current version.
If support for the old versoin of isort is still needed, a compromise can be reached by using the command:
In that case the old version will work but skip the
__init__.pyfile, and the new version will work but give deprecation warnings.