set_data(path, data) Optional abstract method which writes the specified bytes to a file path. Any intermediate directories
abstractmethod get_source(fullname) An abstract method to return the source of a module. It is returned as a text string using
static source_to_code(data, path='') Create a code object from Python source. The data
get_code(fullname) Returns None as extension modules lack a code object.
class importlib.machinery.ModuleSpec(name, loader, *, origin=None, loader_state=None, is_package=None) A specification for a
class importlib.machinery.SourcelessFileLoader(fullname, path) A concrete implementation of importlib.abc.FileLoader
path_mtime(path) Optional abstract method which returns the modification time for the specified path.
is_package(fullname) Determines if the module is a package based on path.
invalidate_caches() An optional method which, when called, should invalidate any internal cache used by the finder. Used by
importlib.util.find_spec(name, package=None) Find the spec for a module, optionally relative
Page 14 of 15