-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
STY: Using __all__; removed "noqa" comment #33143
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
STY: Using __all__; removed "noqa" comment #33143
Conversation
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.
lgtm
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.
I am personally -1 on this, I find the relative imports much clearer to signal it are all imports internally from the module.
I personally don't have a strong opinion on relative vs absolute imports, just wanted to remove the If we do want relative imports in some places, https://dev.pandas.io/docs/development/code_style.html#imports-aim-for-absolute should be updated. |
I'm with Joris on this one. |
absolute imports are recommended by PEP8 and are used 99% of the time in our code base, so I think we should go with this |
PEP8 also says:
(which I would say applies here) So I don't think PEP8 is a good reason to do this. |
I disagree, we barely use them. having a mix is SO confusing. Since we use absolute almost everywhere we should just continue to do this. |
all that said, we could have a policy to use relative in some parts of the codebase. I just don't want to mix it within a file. This file looks fine as is. But we need to define how we communicate this policy (and how its enforced). |
Is there a path forward here? I'm still OK with this |
Let's just do the |
Thanks @MomIsBestFriend |
black pandas
git diff upstream/master -u -- "*.py" | flake8 --diff