Skip to content

Commit 967b84c

Browse files
WindsooonJulienPalard
authored andcommitted
bpo-35325: Doc: imp.find_module() return value documentation discrepancy (GH-11040)
1 parent 64117e0 commit 967b84c

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

Doc/library/imp.rst

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,11 @@ This module provides an interface to the mechanisms used to implement the
6666
contained in the list returned by :func:`get_suffixes` describing the kind of
6767
module found.
6868

69-
If the module does not live in a file, the returned *file* is ``None``,
70-
*pathname* is the empty string, and the *description* tuple contains empty
71-
strings for its suffix and mode; the module type is indicated as given in
72-
parentheses above. If the search is unsuccessful, :exc:`ImportError` is
73-
raised. Other exceptions indicate problems with the arguments or
74-
environment.
69+
If the module is built-in or frozen then *file* and *pathname* are both ``None``
70+
and the *description* tuple contains empty strings for its suffix and mode;
71+
the module type is indicated as given in parentheses above. If the search
72+
is unsuccessful, :exc:`ImportError` is raised. Other exceptions indicate
73+
problems with the arguments or environment.
7574

7675
If the module is a package, *file* is ``None``, *pathname* is the package
7776
path and the last item in the *description* tuple is :const:`PKG_DIRECTORY`.

0 commit comments

Comments
 (0)