View Single Post
Old 04-28-2011, 02:20 PM   #193
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,462
Karma: 27757440
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
kiwidude: You can use a tuple directly as a key for a dict, you dont have to convert to a string.

Try verifying that the hashes are actually the same for your different files with a different hashing tool, just to ensure there isn't a bug with the hashlib library (although I find that rather unlikely).

If they are indeed hash collisions, then you can have a final check that compares reported duplicates byte-to-byte. Since there are very few of these, it shouldn't be slow.
kovidgoyal is offline   Reply With Quote