mirror of
https://github.com/python/cpython.git
synced 2025-12-08 06:10:17 +00:00
gh-85076: Document exceptions that can be raised by importlib.import_module (GH-94662)
This commit is contained in:
parent
af58a6f883
commit
66ef16105a
1 changed files with 4 additions and 0 deletions
|
|
@ -124,6 +124,10 @@ Functions
|
||||||
need to call :func:`invalidate_caches` in order for the new module to be
|
need to call :func:`invalidate_caches` in order for the new module to be
|
||||||
noticed by the import system.
|
noticed by the import system.
|
||||||
|
|
||||||
|
If the module cannot be imported, :func:`import_module` will raise
|
||||||
|
:exc:`ImportError` or an appropriate subclass like
|
||||||
|
:exc:`ModuleNotFoundError`.
|
||||||
|
|
||||||
.. versionchanged:: 3.3
|
.. versionchanged:: 3.3
|
||||||
Parent packages are automatically imported.
|
Parent packages are automatically imported.
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue