]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-42135 Correct version slated for importlib.find_loader removal (GH-28312)
authorHugo van Kemenade <hugovk@users.noreply.github.com>
Mon, 13 Sep 2021 22:57:50 +0000 (01:57 +0300)
committerGitHub <noreply@github.com>
Mon, 13 Sep 2021 22:57:50 +0000 (15:57 -0700)
importlib.find_loader should also be slated for 3.12 like the others in GH-25169 and as documented in https://docs.python.org/3.11/whatsnew/3.10.html#deprecated.

Lib/importlib/__init__.py
Misc/NEWS.d/next/Library/2021-09-13-19-32-58.bpo-42135.1ZAHqR.rst [new file with mode: 0644]

index a510f08db48a89589b1dcba7714aa09ef3dcd33e..ce61883288aa350f877cd3b3caaeb6865f888bab 100644 (file)
@@ -79,7 +79,7 @@ def find_loader(name, path=None):
 
     """
     warnings.warn('Deprecated since Python 3.4 and slated for removal in '
-                  'Python 3.10; use importlib.util.find_spec() instead',
+                  'Python 3.12; use importlib.util.find_spec() instead',
                   DeprecationWarning, stacklevel=2)
     try:
         loader = sys.modules[name].__loader__
diff --git a/Misc/NEWS.d/next/Library/2021-09-13-19-32-58.bpo-42135.1ZAHqR.rst b/Misc/NEWS.d/next/Library/2021-09-13-19-32-58.bpo-42135.1ZAHqR.rst
new file mode 100644 (file)
index 0000000..983b46e
--- /dev/null
@@ -0,0 +1,3 @@
+Fix typo: ``importlib.find_loader`` is really slated for removal in Python 3.12 not 3.10, like the others in GH-25169.
+
+Patch by Hugo van Kemenade.