From 2fb131e38c8663299308b84bd2a5dcd25b433a98 Mon Sep 17 00:00:00 2001 From: Hunter Hogan Date: Mon, 14 Jul 2025 22:59:19 -0500 Subject: [PATCH 1/2] Update What's new in Python 3.14: typos and misplaced item. --- Doc/whatsnew/3.14.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Doc/whatsnew/3.14.rst b/Doc/whatsnew/3.14.rst index c108a94692dca7..0e157f6acf2e57 100644 --- a/Doc/whatsnew/3.14.rst +++ b/Doc/whatsnew/3.14.rst @@ -982,7 +982,7 @@ A new flag has been added, :data:`~sys.flags.context_aware_warnings`. This flag defaults to true for the free-threaded build and false for the GIL-enabled build. If the flag is true then the :class:`warnings.catch_warnings` context manager uses a context variable for warning filters. This makes the context -manager behave predicably when used with multiple threads or asynchronous +manager behave predictably when used with multiple threads or asynchronous tasks. A new flag has been added, :data:`~sys.flags.thread_inherit_context`. This flag @@ -1583,7 +1583,7 @@ io :exc:`BlockingIOError` if the operation cannot immediately return bytes. (Contributed by Giovanni Siragusa in :gh:`109523`.) -* Add protocols :class:`io.Reader` and :class:`io.Writer` as a simpler +* Add protocols :class:`io.Reader` and :class:`io.Writer` as simpler alternatives to the pseudo-protocols :class:`typing.IO`, :class:`typing.TextIO`, and :class:`typing.BinaryIO`. (Contributed by Sebastian Rittau in :gh:`127648`.) @@ -2084,6 +2084,8 @@ typing (Contributed by Jelle Zijlstra in :gh:`105499`.) +* :class:`typing.TypeAliasType` now supports star unpacking. + unicodedata ----------- @@ -2656,8 +2658,6 @@ typing * Remove :class:`!typing.ByteString`. It had previously raised a :exc:`DeprecationWarning` since Python 3.12. -* :class:`typing.TypeAliasType` now supports star unpacking. - urllib ------ From b6fa1914d23a44d84271b00139c660e06510fdc2 Mon Sep 17 00:00:00 2001 From: Hunter Hogan Date: Tue, 15 Jul 2025 00:56:49 -0500 Subject: [PATCH 2/2] "the standard in this file is a one line gap between points and a two line gap between sections." https://github.com/python/cpython/pull/136665#discussion_r2206427707 --- Doc/whatsnew/3.14.rst | 38 +++++++++++++++++++++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/Doc/whatsnew/3.14.rst b/Doc/whatsnew/3.14.rst index 0e157f6acf2e57..5be3cdbd0d9591 100644 --- a/Doc/whatsnew/3.14.rst +++ b/Doc/whatsnew/3.14.rst @@ -122,6 +122,7 @@ it's safe to do so. This can lead to different values returned from :func:`sys.getrefcount` and :c:func:`Py_REFCNT` compared to previous versions of Python. See :ref:`below ` for details. + New features ============ @@ -151,6 +152,7 @@ within CPython itself and the community. This decision is for the future. :pep:`779` and its `acceptance `__. + .. _whatsnew314-pep734: PEP 734: Multiple interpreters in the stdlib @@ -785,6 +787,7 @@ configuration mechanisms). .. seealso:: :pep:`741`. + .. _whatsnew314-asyncio-introspection: Asyncio introspection capabilities @@ -899,6 +902,7 @@ prevent tree construction: (Contributed by Pablo Galindo, Łukasz Langa, Yury Selivanov, and Marta Gomez Macias in :gh:`91048`.) + .. _whatsnew314-tail-call: A new type of interpreter @@ -951,6 +955,7 @@ For further information on how to build Python, see (Contributed by Ken Jin in :gh:`128563`, with ideas on how to implement this in CPython by Mark Shannon, Garrett Gu, Haoran Xu, and Josh Haberman.) + .. _whatsnew314-free-threaded-cpython: Free-threaded mode @@ -1043,6 +1048,7 @@ work without modification). Free-threaded builds do not support JIT compilation. Please report any bugs or major performance regressions that you encounter! + .. seealso:: :pep:`744` Concurrent safe warnings control @@ -1058,6 +1064,7 @@ free-threaded build and false for the GIL-enabled build. (Contributed by Neil Schemenauer and Kumar Aditya in :gh:`130010`.) + Other language changes ====================== @@ -1168,6 +1175,7 @@ Other language changes .. _Jython: https://www.jython.org/ + .. _whatsnew314-pep765: PEP 765: Disallow ``return``/``break``/``continue`` that exit a ``finally`` block @@ -1315,6 +1323,7 @@ concurrent.futures buffer. (Contributed by Enzo Bonnal and Josh Rosenberg in :gh:`74028`.) + configparser ------------ @@ -1324,6 +1333,7 @@ configparser :class:`configparser.InvalidWriteError`. (Contributed by Jacob Lincoln in :gh:`129270`.) + contextvars ----------- @@ -1385,6 +1395,7 @@ ctypes * :mod:`ctypes` now supports :term:`free-threading builds `. (Contributed by Kumar Aditya and Peter Bierma in :gh:`127945`.) + curses ------ @@ -1393,12 +1404,14 @@ curses allows to change the color pair ``0``. (Contributed by Serhiy Storchaka in :gh:`133139`.) + datetime -------- * Add :meth:`datetime.time.strptime` and :meth:`datetime.date.strptime`. (Contributed by Wannes Boeykens in :gh:`41431`.) + decimal ------- @@ -1410,6 +1423,7 @@ decimal corresponding to the IEEE 754 (2008) decimal interchange formats. (Contributed by Sergey B Kirpichev in :gh:`53032`.) + difflib ------- @@ -1417,6 +1431,7 @@ difflib :class:`difflib.HtmlDiff` class now support dark mode. (Contributed by Jiahao Li in :gh:`129939`.) + dis --- @@ -1609,6 +1624,7 @@ json `. (Contributed by Tomas Roun in :gh:`131952`.) + linecache --------- @@ -1758,6 +1774,7 @@ multiprocessing :keyword:`finally` clauses to print a stack trace for the terminated process. (Contributed by Artem Pulkin in :gh:`131913`.) + operator -------- @@ -1924,6 +1941,7 @@ socket * Add many new constants. (Contributed by Serhiy Storchaka in :gh:`132734`.) + ssl --- @@ -2025,6 +2043,7 @@ tkinter :class:`!tkinter.ttk.OptionMenu`. (Contributed by Zhikang Yan in :gh:`130482`.) + turtle ------ @@ -2083,9 +2102,9 @@ typing (Contributed by Jelle Zijlstra in :gh:`105499`.) - * :class:`typing.TypeAliasType` now supports star unpacking. + unicodedata ----------- @@ -2235,6 +2254,7 @@ asyncio (Contributed by Yury Selivanov, Pablo Galindo Salgado, and Łukasz Langa in :gh:`91048`.) + base64 ------ @@ -2419,6 +2439,7 @@ Deprecated .. include:: ../deprecations/pending-removal-in-future.rst + Removed ======= @@ -2437,6 +2458,7 @@ argparse inheritance. This functionality has been deprecated since Python 3.11. (Contributed by Savannah Ostrowski in :gh:`127186`.) + ast --- @@ -2465,6 +2487,7 @@ ast Use :attr:`!ast.Constant.value` instead. (Contributed by Alex Waygood in :gh:`119562`.) + asyncio ------- @@ -2585,12 +2608,14 @@ collections.abc * Remove :class:`!collections.abc.ByteString`. It had previously raised a :exc:`DeprecationWarning` since Python 3.12. + email ----- * Remove the *isdst* parameter from :func:`email.utils.localtime`. (Contributed by Hugo van Kemenade in :gh:`118798`.) + importlib --------- @@ -2607,6 +2632,7 @@ importlib (Contributed by Jason R. Coombs and Hugo van Kemenade in :gh:`93963`.) + itertools --------- @@ -2614,6 +2640,7 @@ itertools These had previously raised a :exc:`DeprecationWarning` since Python 3.12. (Contributed by Raymond Hettinger in :gh:`101588`.) + pathlib ------- @@ -2624,6 +2651,7 @@ pathlib :meth:`~pathlib.PurePath.is_relative_to`. In previous versions, any such arguments are joined onto *other*. + pkgutil ------- @@ -2631,6 +2659,7 @@ pkgutil These had previously raised a :exc:`DeprecationWarning` since Python 3.12. (Contributed by Bénédikt Tran in :gh:`97850`.) + pty --- @@ -2639,6 +2668,7 @@ pty Use :func:`pty.openpty` instead. (Contributed by Nikita Sobolev in :gh:`118824`.) + sqlite3 ------- @@ -2652,12 +2682,14 @@ sqlite3 it will now raise a :exc:`sqlite3.ProgrammingError`. (Contributed by Erlend E. Aasland in :gh:`118928` and :gh:`101693`.) + typing ------ * Remove :class:`!typing.ByteString`. It had previously raised a :exc:`DeprecationWarning` since Python 3.12. + urllib ------ @@ -2675,6 +2707,7 @@ urllib :func:`~urllib.request.build_opener`. (Contributed by Barney Gale in :gh:`84850`.) + Others ------ @@ -2694,12 +2727,14 @@ CPython bytecode changes * Replaced the opcode ``BINARY_SUBSCR`` by :opcode:`BINARY_OP` with oparg ``NB_SUBSCR``. (Contributed by Irit Katriel in :gh:`100239`.) + Porting to Python 3.14 ====================== This section lists previously described changes and other bugfixes that may require changes to your code. + Changes in the Python API ------------------------- @@ -2733,6 +2768,7 @@ Build changes with :c:expr:`Py_NO_LINK_LIB`. (Contributed by Jean-Christophe Fillion-Robin in :gh:`82909`.) + .. _whatsnew314-pep761: PEP 761: Discontinuation of PGP signatures