I want to be able to list the installed modules and their version number on my Python Enthought distribution. When I open the terminal and type
$ help('modules')
i get
>> no Python documentation found for 'modules'
if I do the same for my standard python distro on the mac (/usr/bin/python/) it works fine although I am still missing the module version.
Any idea how to properly list all the installed modules and their corresponding version?
To list all modules:
import sys
print sys.modules
for the version information ... that's a bit tricky. Because if this information is not provided by the respective package/module you relay on the underlying packaging mechanism.
if you use pip you could do a pip show or freeze or you could use yolk.