diff --git a/Doc/whatsnew/3.14.rst b/Doc/whatsnew/3.14.rst index c108a94692dca7..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 @@ -982,7 +987,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 @@ -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 --- @@ -1583,7 +1598,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`.) @@ -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,6 +2102,8 @@ typing (Contributed by Jelle Zijlstra in :gh:`105499`.) +* :class:`typing.TypeAliasType` now supports star unpacking. + unicodedata ----------- @@ -2233,6 +2254,7 @@ asyncio (Contributed by Yury Selivanov, Pablo Galindo Salgado, and Łukasz Langa in :gh:`91048`.) + base64 ------ @@ -2417,6 +2439,7 @@ Deprecated .. include:: ../deprecations/pending-removal-in-future.rst + Removed ======= @@ -2435,6 +2458,7 @@ argparse inheritance. This functionality has been deprecated since Python 3.11. (Contributed by Savannah Ostrowski in :gh:`127186`.) + ast --- @@ -2463,6 +2487,7 @@ ast Use :attr:`!ast.Constant.value` instead. (Contributed by Alex Waygood in :gh:`119562`.) + asyncio ------- @@ -2583,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 --------- @@ -2605,6 +2632,7 @@ importlib (Contributed by Jason R. Coombs and Hugo van Kemenade in :gh:`93963`.) + itertools --------- @@ -2612,6 +2640,7 @@ itertools These had previously raised a :exc:`DeprecationWarning` since Python 3.12. (Contributed by Raymond Hettinger in :gh:`101588`.) + pathlib ------- @@ -2622,6 +2651,7 @@ pathlib :meth:`~pathlib.PurePath.is_relative_to`. In previous versions, any such arguments are joined onto *other*. + pkgutil ------- @@ -2629,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 --- @@ -2637,6 +2668,7 @@ pty Use :func:`pty.openpty` instead. (Contributed by Nikita Sobolev in :gh:`118824`.) + sqlite3 ------- @@ -2650,13 +2682,13 @@ 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. -* :class:`typing.TypeAliasType` now supports star unpacking. 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 pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy