On 2008-09-10, Wojtek Walczak <[EMAIL PROTECTED]> wrote: > On Wed, 10 Sep 2008 19:12:28 +0200, Python wrote: >> [EMAIL PROTECTED]:~% echo "test" > test.txt >> >> [EMAIL PROTECTED]:~% md5 test.txt >> MD5 (test.txt) = d8e8fca2dc0f896fd7cb4cb0031ba249 > >> >>> import md5 >> >>> md5.new("/Volumes/data/Arno/test.txt").hexdigest() >> '90364ed45b452d43378629c20543a81d' > > > Works for me: > >>>> import md5 >>>> f = open('test.txt').read() >>>> md5.new(f).hexdigest() > 'd8e8fca2dc0f896fd7cb4cb0031ba249' >>>> > > IOW, don't pass the path to the file to md5.new, but the contents > of this file. > > The strange thing is that >>>> md5.new("/Volumes/data/Arno/test.txt").hexdigest() > returns '8dd66a1592e2a8c3ab160822fb237f4d' on my machine.
Same here. -- Grant Edwards grante Yow! What PROGRAM are they at watching? visi.com -- http://mail.python.org/mailman/listinfo/python-list