This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author exarkun
Recipients exarkun
Date 2009-05-20.17:17:11
SpamBayes Score 6.6251196e-05
Marked as misclassified No
Message-id <1242839835.2.0.379423337964.issue6071@psf.upfronthosting.co.za>
In-reply-to
Content
It used to be possible to use hashlib with arrays; it no longer seems
possible.

exarkun@charm:~$ python -c '
import sys, hashlib, array
print sys.version_info
print hashlib.sha1(array.array("b", [1, 2, 3])).hexdigest()
'
(2, 5, 2, 'final', 0)
7037807198c22a7d2b0807371d763779a84fdfcf
exarkun@charm:~$ ~/Projects/python/trunk/python -c '
import sys, hashlib, array
print sys.version_info
print hashlib.sha1(array.array("b", [1, 2, 3])).hexdigest()
'
sys.version_info(major=2, minor=7, micro=0, releaselevel='alpha', serial=0)
Traceback (most recent call last):
  File "<string>", line 4, in <module>
TypeError: object supporting the buffer API required
exarkun@charm:~$
History
Date User Action Args
2009-05-20 17:17:15exarkunsetrecipients: + exarkun
2009-05-20 17:17:15exarkunsetmessageid: <1242839835.2.0.379423337964.issue6071@psf.upfronthosting.co.za>
2009-05-20 17:17:12exarkunlinkissue6071 messages
2009-05-20 17:17:12exarkuncreate