Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Python: Python

ImportError: No module named _md5

 

 

Python python RSS feed   Index | Next | Previous | View Threaded


neridaj at gmail

Jun 30, 2008, 10:33 PM

Post #1 of 3 (728 views)
Permalink
ImportError: No module named _md5

Hello,

Does anyone know how to fix this error when trying to build MySQL-
python-1.2.2:

python setup.py build
Traceback (most recent call last):
File "setup.py", line 5, in <module>
import ez_setup; ez_setup.use_setuptools()
File "/Users/jasonnerida/Downloads/MySQL-python-1.2.2/ez_setup.py",
line 83, in use_setuptools
egg = download_setuptools(version, download_base, to_dir,
download_delay)
File "/Users/jasonnerida/Downloads/MySQL-python-1.2.2/ez_setup.py",
line 111, in download_setuptools
import urllib2, shutil
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/
lib/python2.5/urllib2.py", line 91, in <module>
import hashlib
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/
lib/python2.5/hashlib.py", line 133, in <module>
md5 = __get_builtin_constructor('md5')
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/
lib/python2.5/hashlib.py", line 60, in __get_builtin_constructor
import _md5
ImportError: No module named _md5

I then tried installing py25-hashlib via macports, which never
completes:

sudo port install py25-hashlib
Password:
Waiting for lock on /opt/local/var/macports/build/
_opt_local_var_macports_sources_rsync.macports.org_release_ports_python_py25-
hashlib/work/.macports.py25-hashlib.state

Do I need to completely reinstall python? I'm using 2.5.2 which
shipped with Leopard.

Thanks for any help,

Jason
--
http://mail.python.org/mailman/listinfo/python-list


robert.kern at gmail

Jul 1, 2008, 1:14 PM

Post #2 of 3 (709 views)
Permalink
Re: ImportError: No module named _md5 [In reply to]

neridaj[at]gmail.com wrote:
> Hello,
>
> Does anyone know how to fix this error when trying to build MySQL-
> python-1.2.2:
>
> python setup.py build
> Traceback (most recent call last):
> File "setup.py", line 5, in <module>
> import ez_setup; ez_setup.use_setuptools()
> File "/Users/jasonnerida/Downloads/MySQL-python-1.2.2/ez_setup.py",
> line 83, in use_setuptools
> egg = download_setuptools(version, download_base, to_dir,
> download_delay)
> File "/Users/jasonnerida/Downloads/MySQL-python-1.2.2/ez_setup.py",
> line 111, in download_setuptools
> import urllib2, shutil
> File "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/
> lib/python2.5/urllib2.py", line 91, in <module>
> import hashlib
> File "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/
> lib/python2.5/hashlib.py", line 133, in <module>
> md5 = __get_builtin_constructor('md5')
> File "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/
> lib/python2.5/hashlib.py", line 60, in __get_builtin_constructor
> import _md5
> ImportError: No module named _md5
>
> I then tried installing py25-hashlib via macports, which never
> completes:
>
> sudo port install py25-hashlib
> Password:
> Waiting for lock on /opt/local/var/macports/build/
> _opt_local_var_macports_sources_rsync.macports.org_release_ports_python_py25-
> hashlib/work/.macports.py25-hashlib.state
>
> Do I need to completely reinstall python? I'm using 2.5.2 which
> shipped with Leopard.

Delete the directory

/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_python_py25-hashlib/

and try building py25-hashlib again.

--
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless enigma
that is made terrible by our own mad attempt to interpret it as though it had
an underlying truth."
-- Umberto Eco

--
http://mail.python.org/mailman/listinfo/python-list


alokkat at gmail

Jul 3, 2008, 3:18 PM

Post #3 of 3 (704 views)
Permalink
ImportError: No module named _md5 [In reply to]

I am trying to move from python 2.4 to python 2.5.2. After compiling the
python 2.5.2, I found it is throwing "ImportError: No module named _md5".

I found this topic on the mailing list, but no solution to fix it.

Can someone help me out. It will be highly appreciated.

Regards
Alok

Python python RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.