Skip to content

Commit 4791a8a

Browse files
gh-93626: Set the release for __future__.annotations to None (GH-93628)
Co-authored-by: Guido van Rossum <gvanrossum@gmail.com>
1 parent 7bd67d1 commit 4791a8a

File tree

3 files changed

+11
-3
lines changed

3 files changed

+11
-3
lines changed

Doc/whatsnew/3.11.rst

+7
Original file line numberDiff line numberDiff line change
@@ -336,6 +336,13 @@ See :pep:`681` for more details.
336336
(Contributed by Jelle Zijlstra in :gh:`91860`. PEP written by
337337
Erik De Bonte and Eric Traut.)
338338

339+
PEP 563 May Not Be the Future
340+
-----------------------------
341+
342+
* :pep:`563` Postponed Evaluation of Annotations, ``__future__.annotations``
343+
that was planned for this release has been indefinitely postponed.
344+
See `this message <https://mail.python.org/archives/list/python-dev@python.org/message/VIZEBX5EYMSYIJNDBF6DMUMZOCWHARSO/>`_ for more information.
345+
339346
Other Language Changes
340347
======================
341348

Lib/__future__.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
to use the feature in question, but may continue to use such imports.
3434
3535
MandatoryRelease may also be None, meaning that a planned feature got
36-
dropped.
36+
dropped or that the release version is undetermined.
3737
3838
Instances of class _Feature have two corresponding methods,
3939
.getOptionalRelease() and .getMandatoryRelease().
@@ -96,7 +96,7 @@ def getMandatoryRelease(self):
9696
"""Return release in which this feature will become mandatory.
9797
9898
This is a 5-tuple, of the same form as sys.version_info, or, if
99-
the feature was dropped, is None.
99+
the feature was dropped, or the release date is undetermined, is None.
100100
"""
101101
return self.mandatory
102102

@@ -143,5 +143,5 @@ def __repr__(self):
143143
CO_FUTURE_GENERATOR_STOP)
144144

145145
annotations = _Feature((3, 7, 0, "beta", 1),
146-
(3, 11, 0, "alpha", 0),
146+
None,
147147
CO_FUTURE_ANNOTATIONS)
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Set ``__future__.annotations`` to have a ``None`` mandatoryRelease to indicate that it is currently 'TBD'.

0 commit comments

Comments
 (0)