pkgutil.find_loader()

pkgutil.find_loader(fullname)[source]

Find a PEP 302 “loader” object for fullname

If fullname contains dots, path must be the containing package’s __path__. Returns None if the module cannot be found or imported. This function uses iter_importers(), and is thus subject to the same limitations regarding platform-specific special import locations such as the Windows registry.