开发者

Python - problem in importing new module - libgmail

I downloaded Python module libgmail from sourceforge and extracted all the files in the archive. The archive had setup.py, so I went to that directory in command prompt and did

setup.py install 

I am getting the following error message

I:\libgmail-0.1.11>setup.py install
Traceback (most recent call last):
  File "I:\libgmail-0.1.11\setup.py", line 7, in ?
    import libgmail
  File "I:\libgmail-0.1.11\libgmail.py", line 36, in ?
    import mechanize as ClientCookie
ImportError: No module named mechanize

This may 开发者_JAVA技巧be trivial, but I am new to python. So plz guide what to do.

please note, I am using python 2.4 and using Windows-XP.

Thank you

MicroKernel


I think this lib depends on this one:

http://wwwsearch.sourceforge.net/mechanize/

Try installing it first.


You need to download and install the module called mechanize. Depending on your operating system (ie. Linux), your package manager probably has something for this, otherwise you will need to google it, and follow it's installation instructions.


easy_install mechanize

If this doesn't work, you need to fix your PATH environment variable to include path to your python installation directory\scripts. easy_install will save you a lot of time in future.

P.S.: Python 2.4 is 6 years old, you should really consider at least 2.6.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜