Skip to content

Re-export code from _ast into ast #1515

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

Merged
merged 2 commits into from
Aug 3, 2017

Conversation

ilinum
Copy link
Contributor

@ilinum ilinum commented Aug 3, 2017

After mypy started hiding imported names in stubs unless from ... import ... is used, we found an error with stubs of ast module.

It looks like ast module should re-export everything in _ast and according to PEP 484, it can do that by doing from _ast import *, so this is what this PR does.

@gvanrossum
Copy link
Member

The flake8 linter doesn't like * imports. I wonder if we should just disable that rule in the config file.

@ilinum
Copy link
Contributor Author

ilinum commented Aug 3, 2017

Hmm, I think we should disable the rule.

But if other people think otherwise, I am happy to fix the import.

@gvanrossum
Copy link
Member

gvanrossum commented Aug 3, 2017 via email

@ilinum
Copy link
Contributor Author

ilinum commented Aug 3, 2017

Submitted #1519 to allow star imports.

@gvanrossum
Copy link
Member

gvanrossum commented Aug 3, 2017 via email

@ilinum
Copy link
Contributor Author

ilinum commented Aug 3, 2017

Merged and pushed!

@gvanrossum gvanrossum merged commit 3f9fafb into python:master Aug 3, 2017
@ilinum ilinum deleted the reexport_all_in_ast branch August 3, 2017 23:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants