10000 bpo-23722: Fix docs for future __classcell__ changes. (GH-6999) · python/cpython@8ae8e6a · GitHub
[go: up one dir, main page]

Skip to content

Commit 8ae8e6a

Browse files
bpo-23722: Fix docs for future __classcell__ changes. (GH-6999)
1 parent 63536bd commit 8ae8e6a

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

Doc/reference/datamodel.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1968,7 +1968,7 @@ current call is identified based on the first argument passed to the method.
19681968
be propagated up to the ``type.__new__`` call in order for the class to be
19691969
initialised correctly.
19701970
Failing to do so will result in a :exc:`DeprecationWarning` in Python 3.6,
1971-
and a :exc:`RuntimeWarning` in the future.
1971+
and a :exc:`RuntimeError` in Python 3.8.
19721972

19731973
When using the default metaclass :class:`type`, or any metaclass that ultimately
19741974
calls ``type.__new__``, the following additional customisation steps are

Doc/whatsnew/3.6.rst

Lines changed: 2 additions & 1 deletion
< 48A1 td data-grid-cell-id="diff-087851b0c4f1d14e8bf2c082d2f0906bc7cccefe7b2dbb40a75f946c8b6ffa94-2264-2265-2" data-line-anchor="diff-087851b0c4f1d14e8bf2c082d2f0906bc7cccefe7b2dbb40a75f946c8b6ffa94R2265" data-selected="false" role="gridcell" style="background-color:var(--diffBlob-additionLine-bgColor, var(--diffBlob-addition-bgColor-line));padding-right:24px" tabindex="-1" valign="top" class="focusable-grid-cell diff-text-cell right-side-diff-cell left-side">+
Python 3.8.
Original file line numberDiff line numberDiff line change
@@ -2261,7 +2261,8 @@ Changes in the Python API
22612261
direct references from methods to the implicit ``__class__`` closure
22622262
variable, the implicit ``__classcell__`` namespace entry must now be passed
22632263
up to ``type.__new__`` for initialisation. Failing to do so will result in
2264-
a :exc:`DeprecationWarning` in 3.6 and a :exc:`RuntimeWarning` in the future.
2264+
a :exc:`DeprecationWarning` in Python 3.6 and a :exc:`RuntimeError` in
2265
22652266

22662267
Changes in the C API
22672268
--------------------

0 commit comments

Comments
 (0)
0