]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-123299: Copyedit "What's New in Python 3.14" (#125438)
authorHugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Tue, 15 Oct 2024 07:39:15 +0000 (10:39 +0300)
committerGitHub <noreply@github.com>
Tue, 15 Oct 2024 07:39:15 +0000 (10:39 +0300)
Doc/deprecations/c-api-pending-removal-in-3.14.rst
Doc/deprecations/c-api-pending-removal-in-3.15.rst
Doc/deprecations/c-api-pending-removal-in-future.rst
Doc/deprecations/index.rst
Doc/deprecations/pending-removal-in-3.13.rst
Doc/deprecations/pending-removal-in-3.14.rst
Doc/deprecations/pending-removal-in-3.15.rst
Doc/deprecations/pending-removal-in-3.16.rst
Doc/deprecations/pending-removal-in-future.rst
Doc/whatsnew/3.14.rst

index d16da66c29abe7ebe2d9f31f780fd56abd902291..9e10bf2691e5c8508d710f5741ea91b37b69bc6c 100644 (file)
@@ -1,4 +1,4 @@
-Pending Removal in Python 3.14
+Pending removal in Python 3.14
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 * The ``ma_version_tag`` field in :c:type:`PyDictObject` for extension modules
index e3974415e0cc89a9be47718dcbb2773a99bdcc12..1bb49e5b4874f2e79d175420f90c7ce2c024f1de 100644 (file)
@@ -1,4 +1,4 @@
-Pending Removal in Python 3.15
+Pending removal in Python 3.15
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 * The bundled copy of ``libmpdecimal``.
index 0c3ae52b87ff74c1dd8daede6e1018c83f27c731..8fc1c80c35d0925ac79431be0fb75e33d5e57bb4 100644 (file)
@@ -1,4 +1,4 @@
-Pending Removal in Future Versions
+Pending removal in future versions
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 The following APIs are deprecated and will be removed,
index a9efb0bc744335a694365a046d4232603960f5e4..bac6e3f18d4594c77f0486b467624678a12d4276 100644 (file)
@@ -7,7 +7,7 @@ Deprecations
 
 .. include:: pending-removal-in-future.rst
 
-C API Deprecations
+C API deprecations
 ------------------
 
 .. include:: c-api-pending-removal-in-3.15.rst
index 89790497816e836ef561774a9007cc46b115b83e..2fd2f12cc6a2c42a3cb92069bb5f60ac603853ce 100644 (file)
@@ -1,4 +1,4 @@
-Pending Removal in Python 3.13
+Pending removal in Python 3.13
 ------------------------------
 
 Modules (see :pep:`594`):
index de30f4695059ed249da865c57b46d7628ee1ed48..b8791b8d6c387e5633e88e029e007509546f2db1 100644 (file)
@@ -1,4 +1,4 @@
-Pending Removal in Python 3.14
+Pending removal in Python 3.14
 ------------------------------
 
 * The import system:
index a55fb6bea3fdaac2f91962f08eb2b081dbd73e98..17029b8d4773bdba89595745eadefee67fb6f704 100644 (file)
@@ -1,4 +1,4 @@
-Pending Removal in Python 3.15
+Pending removal in Python 3.15
 ------------------------------
 
 * The import system:
@@ -63,7 +63,7 @@ Pending Removal in Python 3.15
 
   * The undocumented keyword argument syntax for creating
     :class:`~typing.NamedTuple` classes
-    (e.g. ``Point = NamedTuple("Point", x=int, y=int)``)
+    (for example, ``Point = NamedTuple("Point", x=int, y=int)``)
     has been deprecated since Python 3.13.
     Use the class-based syntax or the functional syntax instead.
 
index fc2ef33de5e5cc50e0f2db0cffe5b43634d9afda..fac500d34742ca753708e95e75bb3c79adae95ff 100644 (file)
@@ -1,15 +1,6 @@
-Pending Removal in Python 3.16
+Pending removal in Python 3.16
 ------------------------------
 
-* :mod:`builtins`:
-
-  * Bitwise inversion on boolean types, ``~True`` or ``~False``
-    has been deprecated since Python 3.12,
-    as it produces surprising and unintuitive results (``-2`` and ``-1``).
-    Use ``not x`` instead for the logical negation of a Boolean.
-    In the rare case that you need the bitwise inversion of
-    the underlying integer, convert to ``int`` explicitly (``~int(x)``).
-
 * :mod:`array`:
 
   * The ``'u'`` format code (:c:type:`wchar_t`)
@@ -20,11 +11,19 @@ Pending Removal in Python 3.16
 
 * :mod:`asyncio`:
 
-   * :mod:`asyncio`:
-     :func:`!asyncio.iscoroutinefunction` is deprecated
-     and will be removed in Python 3.16,
-     use :func:`inspect.iscoroutinefunction` instead.
-     (Contributed by Jiahao Li and Kumar Aditya in :gh:`122875`.)
+  * :func:`!asyncio.iscoroutinefunction` is deprecated
+    and will be removed in Python 3.16,
+    use :func:`inspect.iscoroutinefunction` instead.
+    (Contributed by Jiahao Li and Kumar Aditya in :gh:`122875`.)
+
+* :mod:`builtins`:
+
+  * Bitwise inversion on boolean types, ``~True`` or ``~False``
+    has been deprecated since Python 3.12,
+    as it produces surprising and unintuitive results (``-2`` and ``-1``).
+    Use ``not x`` instead for the logical negation of a Boolean.
+    In the rare case that you need the bitwise inversion of
+    the underlying integer, convert to ``int`` explicitly (``~int(x)``).
 
 * :mod:`shutil`:
 
index 3f9cf6f208221ab87aee082bf6a8ac1c5c6f1634..f916797c07a068c69e9e20313ba4c5607fcb0838 100644 (file)
@@ -1,4 +1,4 @@
-Pending Removal in Future Versions
+Pending removal in future versions
 ----------------------------------
 
 The following APIs will be removed in the future,
index 25e69a59bdec62f10608d8f798d861a8df91f836..b106578fe9e8b0119011656026f3a18800e82430 100644 (file)
@@ -1,6 +1,6 @@
 
 ****************************
-  What's New In Python 3.14
+  What's new in Python 3.14
 ****************************
 
 :Editor: TBD
@@ -56,7 +56,7 @@ For full details, see the :ref:`changelog <changelog>`.
    so it's worth checking back even after reading earlier versions.
 
 
-Summary -- Release highlights
+Summary -- release highlights
 =============================
 
 .. This section singles out the most important changes in Python 3.14.
@@ -67,12 +67,12 @@ Summary -- Release highlights
 
 
 
-New Features
+New features
 ============
 
-.. _whatsnew-314-pep649:
+.. _whatsnew314-pep649:
 
-PEP 649: Deferred Evaluation of Annotations
+PEP 649: deferred evaluation of annotations
 -------------------------------------------
 
 The :term:`annotations <annotation>` on functions, classes, and modules are no
@@ -150,12 +150,12 @@ In Python 3.7, :pep:`563` introduced the ``from __future__ import annotations``
 directive, which turns all annotations into strings. This directive is now
 considered deprecated and it is expected to be removed in a future version of Python.
 However, this removal will not happen until after Python 3.13, the last version of
-Python without deferred evaluation of annotations, reaches its end of life.
+Python without deferred evaluation of annotations, reaches its end of life in 2029.
 In Python 3.14, the behavior of code using ``from __future__ import annotations``
 is unchanged.
 
 
-Improved Error Messages
+Improved error messages
 -----------------------
 
 * When unpacking assignment fails due to incorrect number of variables, the
@@ -172,16 +172,16 @@ Improved Error Messages
      ValueError: too many values to unpack (expected 3, got 4)
 
 
-Other Language Changes
+Other language changes
 ======================
 
 * Incorrect usage of :keyword:`await` and asynchronous comprehensions
   is now detected even if the code is optimized away by the :option:`-O`
-  command line option. For example, ``python -O -c 'assert await 1'``
+  command-line option. For example, ``python -O -c 'assert await 1'``
   now produces a :exc:`SyntaxError`. (Contributed by Jelle Zijlstra in :gh:`121637`.)
 
 * Writes to ``__debug__`` are now detected even if the code is optimized
-  away by the :option:`-O` command line option. For example,
+  away by the :option:`-O` command-line option. For example,
   ``python -O -c 'assert (__debug__ := 1)'`` now produces a
   :exc:`SyntaxError`. (Contributed by Irit Katriel in :gh:`122245`.)
 
@@ -191,7 +191,7 @@ Other Language Changes
   (Contributed by Serhiy Storchaka in :gh:`84978`.)
 
 
-New Modules
+New modules
 ===========
 
 * :mod:`annotationlib`: For introspecting :term:`annotations <annotation>`.
@@ -199,7 +199,7 @@ New Modules
   (Contributed by Jelle Zijlstra in :gh:`119180`.)
 
 
-Improved Modules
+Improved modules
 ================
 
 argparse
@@ -214,7 +214,7 @@ ast
 ---
 
 * Add :func:`ast.compare` for comparing two ASTs.
-  (Contributed by Batuhan Taskaya and Jeremy Hylton in :issue:`15987`.)
+  (Contributed by Batuhan Taskaya and Jeremy Hylton in :gh:`60191`.)
 
 * Add support for :func:`copy.replace` for AST nodes.
   (Contributed by Bénédikt Tran in :gh:`121141`.)
@@ -246,6 +246,12 @@ decimal
   :meth:`Decimal.from_number() <decimal.Decimal.from_number>`.
   (Contributed by Serhiy Storchaka in :gh:`121798`.)
 
+datetime
+--------
+
+* Add :meth:`datetime.time.strptime` and :meth:`datetime.date.strptime`.
+  (Contributed by Wannes Boeykens in :gh:`41431`.)
+
 dis
 ---
 
@@ -254,9 +260,10 @@ dis
   This feature is added to the following interfaces via the *show_positions*
   keyword argument:
 
-  - :class:`dis.Bytecode`,
-  - :func:`dis.dis`, :func:`dis.distb`, and
-  - :func:`dis.disassemble`.
+  - :class:`dis.Bytecode`
+  - :func:`dis.dis`
+  - :func:`dis.distb`
+  - :func:`dis.disassemble`
 
   This feature is also exposed via :option:`dis --show-positions`.
   (Contributed by Bénédikt Tran in :gh:`123165`.)
@@ -310,7 +317,8 @@ json
   of the error.
   (Contributed by Serhiy Storchaka in :gh:`122163`.)
 
-* Enable the :mod:`json` module to work as a script using the :option:`-m` switch: ``python -m json``.
+* Enable the :mod:`json` module to work as a script using the :option:`-m`
+  switch: :program:`python -m json`.
   See the :ref:`JSON command-line interface <json-commandline>` documentation.
   (Contributed by Trey Hunner in :gh:`122873`.)
 
@@ -325,12 +333,6 @@ operator
   (Contributed by Raymond Hettinger and Nico Mexis in :gh:`115808`.)
 
 
-datetime
---------
-
-* Add :meth:`datetime.time.strptime` and :meth:`datetime.date.strptime`.
-  (Contributed by Wannes Boeykens in :gh:`41431`.)
-
 os
 --
 
@@ -357,11 +359,11 @@ pathlib
 pdb
 ---
 
-* Hard-coded breakpoints (:func:`breakpoint` and :func:`pdb.set_trace`) now
+* Hardcoded breakpoints (:func:`breakpoint` and :func:`pdb.set_trace`) now
   reuse the most recent :class:`~pdb.Pdb` instance that calls
   :meth:`~pdb.Pdb.set_trace`, instead of creating a new one each time.
   As a result, all the instance specific data like :pdbcmd:`display` and
-  :pdbcmd:`commands` are preserved across hard-coded breakpoints.
+  :pdbcmd:`commands` are preserved across hardcoded breakpoints.
   (Contributed by Tian Gao in :gh:`121450`.)
 
 * Add a new argument *mode* to :class:`pdb.Pdb`. Disable the ``restart``
@@ -391,9 +393,9 @@ symtable
 
 * Expose the following :class:`symtable.Symbol` methods:
 
-  * :meth:`~symtable.Symbol.is_free_class`
-  * :meth:`~symtable.Symbol.is_comp_iter`
   * :meth:`~symtable.Symbol.is_comp_cell`
+  * :meth:`~symtable.Symbol.is_comp_iter`
+  * :meth:`~symtable.Symbol.is_free_class`
 
   (Contributed by Bénédikt Tran in :gh:`120029`.)
 
@@ -472,11 +474,11 @@ ast
 * Remove the following classes. They were all deprecated since Python 3.8,
   and have emitted deprecation warnings since Python 3.12:
 
-  * :class:`!ast.Num`
-  * :class:`!ast.Str`
   * :class:`!ast.Bytes`
-  * :class:`!ast.NameConstant`
   * :class:`!ast.Ellipsis`
+  * :class:`!ast.NameConstant`
+  * :class:`!ast.Num`
+  * :class:`!ast.Str`
 
   Use :class:`ast.Constant` instead. As a consequence of these removals,
   user-defined ``visit_Num``, ``visit_Str``, ``visit_Bytes``,
@@ -501,16 +503,16 @@ asyncio
 * Remove the following classes and functions. They were all deprecated and
   emitted deprecation warnings since Python 3.12:
 
+  * :func:`!asyncio.get_child_watcher`
+  * :func:`!asyncio.set_child_watcher`
+  * :meth:`!asyncio.AbstractEventLoopPolicy.get_child_watcher`
+  * :meth:`!asyncio.AbstractEventLoopPolicy.set_child_watcher`
   * :class:`!asyncio.AbstractChildWatcher`
-  * :class:`!asyncio.SafeChildWatcher`
-  * :class:`!asyncio.MultiLoopChildWatcher`
   * :class:`!asyncio.FastChildWatcher`
-  * :class:`!asyncio.ThreadedChildWatcher`
+  * :class:`!asyncio.MultiLoopChildWatcher`
   * :class:`!asyncio.PidfdChildWatcher`
-  * :meth:`!asyncio.AbstractEventLoopPolicy.get_child_watcher`
-  * :meth:`!asyncio.AbstractEventLoopPolicy.set_child_watcher`
-  * :func:`!asyncio.get_child_watcher`
-  * :func:`!asyncio.set_child_watcher`
+  * :class:`!asyncio.SafeChildWatcher`
+  * :class:`!asyncio.ThreadedChildWatcher`
 
   (Contributed by Kumar Aditya in :gh:`120804`.)
 
@@ -623,14 +625,14 @@ Changes in the Python API
   (Contributed by Serhiy Storchaka in :gh:`69998`.)
 
 
-Build Changes
+Build changes
 =============
 
 
-C API Changes
+C API changes
 =============
 
-New Features
+New features
 ------------
 
 * Add :c:func:`PyLong_GetSign` function to get the sign of :class:`int` objects.
@@ -640,17 +642,17 @@ New Features
   object:
 
   * :c:func:`PyUnicodeWriter_Create`
+  * :c:func:`PyUnicodeWriter_DecodeUTF8Stateful`
   * :c:func:`PyUnicodeWriter_Discard`
   * :c:func:`PyUnicodeWriter_Finish`
+  * :c:func:`PyUnicodeWriter_Format`
   * :c:func:`PyUnicodeWriter_WriteChar`
-  * :c:func:`PyUnicodeWriter_WriteUTF8`
-  * :c:func:`PyUnicodeWriter_WriteUCS4`
-  * :c:func:`PyUnicodeWriter_WriteWideChar`
-  * :c:func:`PyUnicodeWriter_WriteStr`
   * :c:func:`PyUnicodeWriter_WriteRepr`
+  * :c:func:`PyUnicodeWriter_WriteStr`
   * :c:func:`PyUnicodeWriter_WriteSubstring`
-  * :c:func:`PyUnicodeWriter_Format`
-  * :c:func:`PyUnicodeWriter_DecodeUTF8Stateful`
+  * :c:func:`PyUnicodeWriter_WriteUCS4`
+  * :c:func:`PyUnicodeWriter_WriteUTF8`
+  * :c:func:`PyUnicodeWriter_WriteWideChar`
 
   (Contributed by Victor Stinner in :gh:`119182`.)
 
@@ -671,14 +673,14 @@ New Features
 * Add new functions to convert C ``<stdint.h>`` numbers from/to Python
   :class:`int`:
 
-  * :c:func:`PyLong_FromInt32`
-  * :c:func:`PyLong_FromInt64`
-  * :c:func:`PyLong_FromUInt32`
-  * :c:func:`PyLong_FromUInt64`
   * :c:func:`PyLong_AsInt32`
   * :c:func:`PyLong_AsInt64`
   * :c:func:`PyLong_AsUInt32`
   * :c:func:`PyLong_AsUInt64`
+  * :c:func:`PyLong_FromInt32`
+  * :c:func:`PyLong_FromInt64`
+  * :c:func:`PyLong_FromUInt32`
+  * :c:func:`PyLong_FromUInt64`
 
   (Contributed by Victor Stinner in :gh:`120389`.)
 
@@ -701,20 +703,20 @@ New Features
 
 * Add functions to configure the Python initialization (:pep:`741`):
 
+  * :c:func:`Py_InitializeFromInitConfig`
+  * :c:func:`PyInitConfig_AddModule`
   * :c:func:`PyInitConfig_Create`
   * :c:func:`PyInitConfig_Free`
+  * :c:func:`PyInitConfig_FreeStrList`
   * :c:func:`PyInitConfig_GetError`
   * :c:func:`PyInitConfig_GetExitCode`
-  * :c:func:`PyInitConfig_HasOption`
   * :c:func:`PyInitConfig_GetInt`
   * :c:func:`PyInitConfig_GetStr`
   * :c:func:`PyInitConfig_GetStrList`
-  * :c:func:`PyInitConfig_FreeStrList`
+  * :c:func:`PyInitConfig_HasOption`
   * :c:func:`PyInitConfig_SetInt`
   * :c:func:`PyInitConfig_SetStr`
   * :c:func:`PyInitConfig_SetStrList`
-  * :c:func:`PyInitConfig_AddModule`
-  * :c:func:`Py_InitializeFromInitConfig`
 
   (Contributed by Victor Stinner in :gh:`107954`.)