-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
CONTRIBUTING: Add @deprecated, other updates #11005
Conversation
Fixes python#11004. I started out just documenting conventions with `@deprecated`, but found some other things in need of updates. - PEP 585 and 612 are now fully supported - Add several other PEPs that we fully support - Use updated links to PEPs - Split off a few sections from the long "Conventions" section - PEP 688 was accepted
|
||
A few guidelines for how to use it: | ||
|
||
* In the standard library, apply the decorator only in Python versions |
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.
Commented in the issue, but I think it would be nice to be more aggressive in cases where an appropriate replacement already exists. (I couldn't quite tell if there was consensus in the issue, if there was then that's fine!)
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.
I agree now, reworded the section to say we should apply it to versions where a good replacement exists.
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.
The header "The following features are partially supported:" could be removed, since the list was removed.
@srittau I'm actually going to move PEP 702 into that section as there are some bugs that mean we can't use it in certain contexts yet. |
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.
This is great, thanks!
I'm guessing pytype just doesn't like have two decorators stacked anywhere in a stub. I'm guessing it also crashes if you try to deprecate an abstractmethod |
Probably, I guess it's not worth listing exactly which decorators are problematic. |
Fixes #11002.
I started out just documenting conventions with
@deprecated
, butfound some other things in need of updates.