-
-
Notifications
You must be signed in to change notification settings - Fork 32k
gh-134370 Added clarification on instances annotations #134387
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
gh-134370 Added clarification on instances annotations #134387
Conversation
Instances of classes cannot have annotations, however sometimes they will erroneously have the __annotations__ attribute
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.
These changes look good to me. I would like @JelleZijlstra to also review from a typing perspective. Thank you @AlexKautz.
I also swapped a |
Thanks @AlexKautz for the PR, and @JelleZijlstra for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14. |
Sorry, @AlexKautz and @JelleZijlstra, I could not cleanly backport this to
|
GH-134509 is a backport of this pull request to the 3.14 branch. |
[Hello from PyCon sprints!]
Instances of classes cannot have annotations,
however sometimes they will erroneously have the
annotations attribute.
@python/proofreaders could you take a look? This is my first Python documentation writing so I'm sure there's a mistake somewhere :).
📚 Documentation preview 📚: https://cpython-previews--134387.org.readthedocs.build/