Possible Duplicate:
Unable to get a list of installed Python modules
How do I print a list of all the modules that are available for import from within my script in Python3?
Possible Duplicate:
Unable to get a list of installed Python modules
How do I print a list of all the modules that are available for import from within my script in Python3?
To access the list of all installed modules accessible via sys.path
programmatically rather than inside an interactive session, you can use pkgutil.iter_modules()
.