Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #38198

Re: ERROR:root:code for hash md5 was not found

Newsgroups comp.lang.python
Date 2013-02-05 07:10 -0800
References <f777e948-02ca-45d3-a858-73e0003d7bcc@t13g2000vbt.googlegroups.com> <4F0D7274.9080905@gmail.com>
Message-ID <d5e905d5-e469-4e23-910e-662602e00514@googlegroups.com> (permalink)
Subject Re: ERROR:root:code for hash md5 was not found
From bidzina_kapanadze@iliauni.edu.ge

Show all headers | View raw


On Wednesday, January 11, 2012 12:28:52 PM UTC+1, Laurent Claessens wrote:
> Le 11/01/2012 12:19, mike a �crit :
> 
> > Hi,
> 
> >
> 
> > We are running are running Python program on Redhat 5.5.
> 
> >
> 
> > When executing our program we get the following error ( see below).
> 
> >
> 
> > Any ideas what this is due to?
> 
> 
> 
> On my computer hashlib has "md5" :
> 
> 
> 
> 
> 
> 
> 
> Python 2.6.6 (r266:84292, Sep 15 2010, 16:22:56)
> 
> [GCC 4.4.5] on linux2
> 
> Type "help", "copyright", "credits" or "license" for more information.
> 
> >>> import hashlib
> 
> >>> h=hashlib.new("md5")
> 
> >>> h.update("Hello")
> 
> >>> h.hexdigest()
> 
> 'd992641f1b2b9c08b569c0a17c4e7cb8'
> 
> 
> 
> While if I ask for a hash method that hashlib does not know, I get the 
> 
> same error as you :
> 
> 
> 
>  >>> g=hashlib.new("bla")
> 
> Traceback (most recent call last):
> 
>    File "<stdin>", line 1, in <module>
> 
>    File "/usr/lib/python2.6/hashlib.py", line 101, in __hash_new
> 
>      return __get_builtin_constructor(name)(string)
> 
>    File "/usr/lib/python2.6/hashlib.py", line 80, in 
> 
> __get_builtin_constructor
> 
>      raise ValueError, "unsupported hash type"
> 
> ValueError: unsupported hash type
> 
> 
> 
> 
> 
> You should give us a more comprehensive example of your problem.
> 
> 
> 
> Laurent

Dear Laurent,

I have encountered similar problem and your suggestion was helpful. Thanks a lot!

Sincerely,

Bidzina Kapanadze,
Abastumani Astrophysical Observatory,
Ilia State University, Tbilisi, Georgia

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: ERROR:root:code for hash md5 was not found bidzina_kapanadze@iliauni.edu.ge - 2013-02-05 07:10 -0800

csiph-web