]> granicus.if.org Git - python/commitdiff
bpo-37574: Mention helper functions for find_spec documentation (GH-14739)
authorjdkandersson <51036209+jdkandersson@users.noreply.github.com>
Tue, 10 Sep 2019 16:06:22 +0000 (02:06 +1000)
committerSteve Dower <steve.dower@python.org>
Tue, 10 Sep 2019 16:06:22 +0000 (17:06 +0100)
Doc/library/importlib.rst

index 0976360c69651f2c0b069cea1b627986b5149fc8..54ca8b8b50a44e0b82bce0493b6a5fd339b8861c 100644 (file)
@@ -274,6 +274,8 @@ ABC hierarchy::
       parent package. If a spec cannot be found, ``None`` is returned.
       When passed in, ``target`` is a module object that the finder may
       use to make a more educated guess about what spec to return.
+      :func:`importlib.util.spec_from_loader` may be useful for implementing
+      concrete ``MetaPathFinders``.
 
       .. versionadded:: 3.4
 
@@ -323,7 +325,8 @@ ABC hierarchy::
       within the :term:`path entry` to which it is assigned.  If a spec
       cannot be found, ``None`` is returned.  When passed in, ``target``
       is a module object that the finder may use to make a more educated
-      guess about what spec to return.
+      guess about what spec to return. :func:`importlib.util.spec_from_loader`
+      may be useful for implementing concrete ``PathEntryFinders``.
 
       .. versionadded:: 3.4