summaryrefslogtreecommitdiff
path: root/Doc/library/pkgutil.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/library/pkgutil.rst')
-rw-r--r--Doc/library/pkgutil.rst17
1 files changed, 9 insertions, 8 deletions
diff --git a/Doc/library/pkgutil.rst b/Doc/library/pkgutil.rst
index 7c4f9121fa..13ea7b9b33 100644
--- a/Doc/library/pkgutil.rst
+++ b/Doc/library/pkgutil.rst
@@ -74,15 +74,17 @@ support.
Retrieve a :pep:`302` module loader for the given *fullname*.
- This is a convenience wrapper around :func:`importlib.find_loader` that
- sets the *path* argument correctly when searching for submodules, and
- also ensures parent packages (if any) are imported before searching for
- submodules.
+ This is a backwards compatibility wrapper around
+ :func:`importlib.util.find_spec` that converts most failures to
+ :exc:`ImportError` and only returns the loader rather than the full
+ :class:`ModuleSpec`.
.. versionchanged:: 3.3
Updated to be based directly on :mod:`importlib` rather than relying
on the package internal PEP 302 import emulation.
+ .. versionchanged:: 3.4
+ Updated to be based on :pep:`451`
.. function:: get_importer(path_item)
@@ -109,14 +111,13 @@ support.
not already imported, its containing package (if any) is imported, in order
to establish the package ``__path__``.
- This function uses :func:`iter_importers`, and is thus subject to the same
- limitations regarding platform-specific special import locations such as the
- Windows registry.
-
.. versionchanged:: 3.3
Updated to be based directly on :mod:`importlib` rather than relying
on the package internal PEP 302 import emulation.
+ .. versionchanged:: 3.4
+ Updated to be based on :pep:`451`
+
.. function:: iter_importers(fullname='')