Skip to content

Add csv.__version__ #7357

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
Feb 22, 2022
Merged

Add csv.__version__ #7357

merged 2 commits into from
Feb 22, 2022

Conversation

AlexWaygood
Copy link
Member

We previously discussed this in #6398, and decided not to include it in the stub. However, it is declared as a publicly exported object in the module's __all__ at runtime, so not including it in the stub creates an inconsistency in the stub's __all__ (see #7356). Moreover, there doesn't really seem to be any harm in adding it to the stub. So, I think we should add it.

@github-actions
Copy link
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@Akuli
Copy link
Collaborator

Akuli commented Feb 22, 2022

I still would prefer if csv.VERSION didn't show up in autocompletions.

@AlexWaygood
Copy link
Member Author

AlexWaygood commented Feb 22, 2022

I still would prefer if csv.VERSION didn't show up in autocompletions.

I get that, but I feel like it's a CPython bug rather than a typeshed bug if the __version__ attribute is really out of date but is explicitly listed in __all__ anyway.

@Akuli
Copy link
Collaborator

Akuli commented Feb 22, 2022

Because it starts with _, it will likely go to the end of a long autocompletion list anyway.

@Akuli Akuli merged commit 22c3cc4 into python:master Feb 22, 2022
@AlexWaygood AlexWaygood deleted the csv branch February 22, 2022 18:12
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.

3 participants