MD5 module Pythonicity
Sat Oct 15 08:56:14 CEST 2005
"Fredrik Lundh" <fredrik at pythonware.com> writes:
> > Forcing every digest module to add code to cater for just one of many
> > use cases is most likely a waste of time.
> here's the hash API specification, btw:
I agree with you and Mike that a file checksum function isn't that
important. I use the hash modules all the time and can't think of a
single time I've ever used one to hash an entire file. However, PEP
247 shows that the modules are supposed to have a common API. So if
there was some actual reason to have a file-hashing operation, it
would be done by implementing it once and having it call a hash module
that's passed as a parameter, similar to the HMAC module, rather than
implementing the file operation in every different hash module.
More information about the Python-list