flox <[email protected]> added the comment:
Definitely, zlib.compress should raise a TypeError (like bz2 does).
>>> import bz2, zlib
>>> bz2.compress('abc')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: argument 1 must be bytes or buffer, not str
>>> zlib.compress('abc')
b"x\x9cKLJ\x06\x00\x02M\x01'"
Someone can review the patch and merge it?
----------
nosy: +flox
versions: +Python 3.2 -Python 3.0
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue4757>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com