I tried to look for "md5" in the "lib" folder of python's installation
directory and there were 3 files present, but there is no module by the
name "_md5". Actually, I am using Python 2.6.2. (Using an older version,
as I had problems cross-compiling the newer version(s)).

What I believe is that at runtime, cherokee-admin tries to look for "md5"
module of Python in the "lib" folder of the file system, but as I have
installed Python at a different location ( in my case: /python ), it is
not able to find "md5" module and import it. I hope this is the problem.

Do you have any idea how can this be resolved?

Thanks.

> On 21/12/2010, at 10:28, Mahendra Liya wrote:
>
>>  File
>> "/my_app/webservers/cherokee/share/cherokee/admin/CTK/CTK/Downloader.py",
>> line 25, in <module>
>>    import urllib2
>>  File "/python/lib/python2.6/urllib2.py", line 91, in <module>
>>    import hashlib
>>  File "/python/lib/python2.6/hashlib.py", line 136, in <module>
>>    md5 = __get_builtin_constructor('md5')
>>  File "/python/lib/python2.6/hashlib.py", line 63, in
>> __get_builtin_constructor
>>    import _md5
>> ImportError: No module named _md5
>
> Cherokee-admin imports urllib2.
>
>> The traceback shows the error with an underscore at the beginning ie
>> "_md5" and not "md5".
>
> As far as I recall, there used to be a 'md5' module in Python that was
> deprecated in favor of 'hashlib'.
>
> It looks to me like the _md5 were a native binary module that, by some
> reason, were missing on your embedded system.
>
>> Also, you say that 'Cherokee-admin' does not import the md5 (or probably
>> you mean _md5) module directly. So how can the md5 module be imported.
>> Is
>> "_md5" indicating something wrong?
>
> Cherokee-admin imports urllib2 and hashlib. I could not tell you why, but
> those modules try to import the _md5 module.  It looks like a problem with
> your Python set up, actually.
>
> For the record, this is what you see on regular desktop environments
> (Linux, MacOS X, etc):
> ==========
> Python 2.4.6 (#1, Oct 15 2009, 11:10:21)
> [GCC 4.2.1 (Apple Inc. build 5646)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
>>>> import urllib2
>>>> import md5
>>>> import _md5
> Traceback (most recent call last):
>   File "<stdin>", line 1, in ?
> ImportError: No module named _md5
>>>>
> ==========
>
> Cheers!
>
> --
> Octality
> http://www.octality.com/
>

_______________________________________________
Cherokee mailing list
[email protected]
http://lists.octality.com/listinfo/cherokee

Reply via email to