PyDocs

Importing Modules

importlib.util

Utility code for constructing importers, etc.
Symbols in importlib.util

_

_incompatible_extension_module_restrictions
A context manager that can temporarily skip the compatibility check.

c

cache_from_source
Given the path to a .py file, return the path to its .pyc file.

d

decode_source
Decode bytes representing source code and return the string.

f

find_spec
Return the spec for the specified module.

l

LazyLoader
A loader that creates a module which defers loading until attribute access.

m

MAGIC_NUMBER
The bytes which represent the bytecode version number.
module_from_spec
Create a module based on the provided spec.

r

resolve_name
Resolve a relative module name to an absolute one.

s

source_from_cache
Given the path to a .pyc.
source_hash
Return the hash of *source_bytes* as used in hash-based pyc files.
spec_from_file_location
Return a module spec based on a file location.
spec_from_loader
Return a module spec based on various loader methods.