How to check version of Python under CGI

Joonas Paalasmaa joonas.paalasmaa at iki.fi
Thu Jun 13 06:42:11 EDT 2002


Johann wrote:
> Thanx. Do you know how to check what modules are installed? E.g. I
> would like to check if PYANA or other xml modules are installed.

try:
     import somemodule
     print "somemodule installed"
except ImportError:
     print "somemodule not installed"




More information about the Python-list mailing list