Skip to content

Fix __instancecheck__ definitions#9291

Merged
AlexWaygood merged 1 commit intopython:mainfrom
sobolevn:fix-instancecheck
Nov 28, 2022
Merged

Fix __instancecheck__ definitions#9291
AlexWaygood merged 1 commit intopython:mainfrom
sobolevn:fix-instancecheck

Conversation

@sobolevn
Copy link
Copy Markdown
Member

@sobolevn sobolevn commented Nov 28, 2022

@github-actions
Copy link
Copy Markdown
Contributor

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

Copy link
Copy Markdown
Member

@AlexWaygood AlexWaygood left a comment

Choose a reason for hiding this comment

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

The data model docs also seem to confirm that these should usually return bool in subclasses!

@AlexWaygood
Copy link
Copy Markdown
Member

AlexWaygood commented Nov 28, 2022

It looks like these methods have been annotated as returning Any since the dawn of time: 4a1674a

@AlexWaygood AlexWaygood merged commit ea2ccc3 into python:main Nov 28, 2022
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