gh-117764: Add docstrings and signatures for the types of None, Ellipsis and NotImplemented by serhiy-storchaka · Pull Request #117813 · python/cpython (original) (raw)
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})
… Ellipsis and NotImplemented
diegorusso pushed a commit to diegorusso/cpython that referenced this pull request
browniebroke added a commit to browniebroke/django-rest-framework that referenced this pull request
Python 3.13 introduced docstrings for None: python/cpython#117813
In Python 3.12, this is an empty string:
➜ python3.12
Python 3.12.6 (main, Sep 10 2024, 19:06:17) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> d = None
>>> d.__doc__
>>>
In Python 3.13, it's no longer empty:
➜ python3.13
Python 3.13.0rc2+ (heads/3.13:660baa1, Sep 10 2024, 18:57:50) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> d = None
>>> d.__doc__
'The type of the None singleton.'
>>>
Adding a check in the inspector that get the view description out the view function docstring to cath this edge case.
browniebroke added a commit to browniebroke/django-rest-framework that referenced this pull request
Python 3.13 introduced docstrings for None: python/cpython#117813
In Python 3.12, this is an empty string:
➜ python3.12
Python 3.12.6 (main, Sep 10 2024, 19:06:17) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> d = None
>>> d.__doc__
>>>
In Python 3.13, it's no longer empty:
➜ python3.13
Python 3.13.0rc2+ (heads/3.13:660baa1, Sep 10 2024, 18:57:50) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> d = None
>>> d.__doc__
'The type of the None singleton.'
>>>
Adding a check in the inspector that get the view description out the view function docstring to cath this edge case.
browniebroke added a commit to browniebroke/django-rest-framework that referenced this pull request
Python 3.13 introduced docstrings for None: python/cpython#117813
In Python 3.12, this is an empty string:
➜ python3.12
Python 3.12.6 (main, Sep 10 2024, 19:06:17) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> d = None
>>> d.__doc__
>>>
In Python 3.13, it's no longer empty:
➜ python3.13
Python 3.13.0rc2+ (heads/3.13:660baa1, Sep 10 2024, 18:57:50) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> d = None
>>> d.__doc__
'The type of the None singleton.'
>>>
Adding a check in the inspector that get the view description out the view function docstring to catch this edge case.
auvipy pushed a commit to encode/django-rest-framework that referenced this pull request
Add support for Python 3.13
Fix extracting tox env with -dev Python versions
Fix view description inspection in Python 3.13
Python 3.13 introduced docstrings for None: python/cpython#117813
In Python 3.12, this is an empty string:
➜ python3.12
Python 3.12.6 (main, Sep 10 2024, 19:06:17) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> d = None
>>> d.__doc__
>>>
In Python 3.13, it's no longer empty:
➜ python3.13
Python 3.13.0rc2+ (heads/3.13:660baa1, Sep 10 2024, 18:57:50) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> d = None
>>> d.__doc__
'The type of the None singleton.'
>>>
Adding a check in the inspector that get the view description out the view function docstring to catch this edge case.