CodeQL library for Python
codeql/python-all 0.12.1 (changelog, source)
Search

Member predicate Import::getAnImportedModuleName

Gets the name of an imported module. For example, for the import statement import bar which is a relative import in package “foo”, this would return “foo.bar”. The import statement from foo import bar would return foo and foo.bar

string getAnImportedModuleName()