Skip to content

narrow signature of __contains__ for str-like classes #2967

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 3 commits into from
May 7, 2019

Conversation

JelleZijlstra
Copy link
Member

Fixes #2937

Copy link
Member

@ilevkivskyi ilevkivskyi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! This will likely cause some errors in internal codebases, but errors occurring because of this are most likely actual type errors, so I think we should try.

@JelleZijlstra JelleZijlstra merged commit bdb1de5 into python:master May 7, 2019
@JelleZijlstra
Copy link
Member Author

Thanks! If it turns out to cause too many issues we can take it out again.

@JelleZijlstra JelleZijlstra deleted the contains branch May 7, 2019 14:24
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.

42 in "some string" fails at runtime with TypeError but is allowed in typeshed
2 participants