You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add support for classmethod property from python3.9 #11619
It might be worth noting that there are currently active discussions on whether to deprecate the ability to stack @classmethod on top of @property, as it's responsible for a lot of bugs in cpython
It might be worth noting that there are currently active discussions on whether to deprecate the ability to stack @classmethod on top of @property, as it's responsible for a lot of bugs in cpython
To update: this behaviour has now been deprecated in 3.11 (python/cpython#92379)
This has been deprecated in python 3.11 it is still correct syntax in python <3.11.
However, it is still semantically incorrent and mypy is right in complaining (the property decorator is not returning what you think it returns).
Maybe one could simply improve the error message for this case?
Activity
AlexWaygood commentedon Nov 25, 2021
It might be worth noting that there are currently active discussions on whether to deprecate the ability to stack
@classmethodon top of@property, as it's responsible for a lot of bugs in cpythonAlexWaygood commentedon May 29, 2022
To update: this behaviour has now been deprecated in 3.11 (python/cpython#92379)
headtr1ck commentedon Sep 29, 2022
This has been deprecated in python 3.11 it is still correct syntax in python <3.11.
However, it is still semantically incorrent and mypy is right in complaining (the property decorator is not returning what you think it returns).
Maybe one could simply improve the error message for this case?
Remove abstract class property
karlicoss commentedon Mar 20, 2023
Would it be possible to change the error category from
miscto something more specific? Then it would be easy to suppress it on older python versionshauntsaninja commentedon Apr 27, 2023
This behaviour has been deprecated in CPython, so mypy will not be adding support for it.
[GraphAPI] Use custom descriptor for Graph.current class property (#4…
[GraphAPI] Use custom descriptor for Graph.current class property (#4…