Skip to content

Commit

Permalink
Postpone module.__loader__ deprecation to Python 3.16 (#126482)
Browse files Browse the repository at this point in the history
  • Loading branch information
hugovk authored Nov 10, 2024
1 parent 9d08423 commit 450db61
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
7 changes: 0 additions & 7 deletions Doc/deprecations/pending-removal-in-3.14.rst
Original file line number Diff line number Diff line change
@@ -1,13 +1,6 @@
Pending removal in Python 3.14
------------------------------

* The import system:

* Setting :attr:`~module.__loader__` on a module while
failing to set :attr:`__spec__.loader <importlib.machinery.ModuleSpec.loader>`
is deprecated. In Python 3.14, :attr:`!__loader__` will cease to be set or
taken into consideration by the import system or the standard library.

* :mod:`argparse`: The *type*, *choices*, and *metavar* parameters
of :class:`!argparse.BooleanOptionalAction` are deprecated
and will be removed in 3.14.
Expand Down
7 changes: 7 additions & 0 deletions Doc/deprecations/pending-removal-in-3.16.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
Pending removal in Python 3.16
------------------------------

* The import system:

* Setting :attr:`~module.__loader__` on a module while
failing to set :attr:`__spec__.loader <importlib.machinery.ModuleSpec.loader>`
is deprecated. In Python 3.16, :attr:`!__loader__` will cease to be set or
taken into consideration by the import system or the standard library.

* :mod:`array`:

* The ``'u'`` format code (:c:type:`wchar_t`)
Expand Down
4 changes: 2 additions & 2 deletions Doc/reference/datamodel.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1028,9 +1028,9 @@ this approach.
using the :class:`types.ModuleType` constructor.
Previously the attribute was optional.

.. deprecated-removed:: 3.12 3.14
.. deprecated-removed:: 3.12 3.16
Setting :attr:`!__loader__` on a module while failing to set
:attr:`!__spec__.loader` is deprecated. In Python 3.14,
:attr:`!__spec__.loader` is deprecated. In Python 3.16,
:attr:`!__loader__` will cease to be set or taken into consideration by
the import system or the standard library.

Expand Down

0 comments on commit 450db61

Please sign in to comment.