Help understanding import error

ctoomey at gmail.com ctoomey at gmail.com
Wed Feb 13 20:58:57 CET 2013


I'm using TortoiseHg on Windows, which is implemented in python and includes python (2.7.3) as dlls and a bunch of python modules bunded into a library.zip file.  I'm trying to use an extension whose __init__.py does the following import:

    from distutils.version import LooseVersion

and am getting the error message "*** failed to import extension reviewboard from C:\Program Files\TortoiseHg\reviewboard: No module named version"

The thing I don't get is that the library.zip file contains distutils\version.pyo and looking at the text in that it does contain LooseVersion.  Also, many other library modules are imported and used without problem, and this extension works fine on my Linux box.

Any ideas what could be causing this and how to fix it?

thx,
Chris



More information about the Python-list mailing list