-
Notifications
You must be signed in to change notification settings - Fork 45
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
Discussion on the ordering of library imports #182
Comments
Totally agree! This would follow better PEP8 conventions.
or case 2:
? PEP8 doesn't specify this case. |
I like the first proposal better. May I ask you to only upvote the guideline you would like to be implemented? This means you should remove the upvote from the first proposal if you'd like to vote for another one. |
Ok, let's try again, It seems that we agree to follow PEP8 conventions. Is the difference you see between just following alphabetical order (case 2) vs import/from distinctions (case 1)? |
Oh, I follow you. I'd rather have import first, then from. |
Then, final vote:
or 🚀 for case 2 (strict alphabetical order):
|
after voting, should we make a bit PR to change the order in all the files? |
Don't worry @vinferrer, I'll take care of it. Just make sure that whatever you're working in right now follows the new guidelines before merging! |
sure |
Summary
Each one of us has got a different way of ordering the library imports and I believe we should have some guidelines to follow. The idea is that we are all on the same page. Also, this should make reading and reviewing the code easier on the eye.
The following is a possible guideline:
where each set of imports is in alphabetical order, ideally separated by a blank line.
If you agree on making the suggested guideline the default, please upvote. If you have a better suggestion, please comment on this issue. I will keep this issue open for a week and will open a PR that updates the imports with whatever guideline has got the most upvotes once the issue is closed.
Tagging the most active members in the project: @smoia, @vinferrer, @rmarkello, @RayStick.
Next Steps
The text was updated successfully, but these errors were encountered: