Marc-Andre Lemburg added the comment:
On 25.04.2013 10:14, Nick Coghlan wrote:
>
> Nick Coghlan added the comment:
>
> A more consistent alternative conversion:
>
> "...".encode("base64") => codecs.encode("...", "base64_codec")
> "...".encode("rot13") => codecs.encode("...", "rot_13")
> "...".encode("zlib") => codecs.encode("...", "zlib_codec")
> "...".encode("hex") => codecs.encode("...", "hex_codec")
> "...".encode("bz2") => codecs.encode("...", "bz2_codec")
>
> "...".decode("base64") => codecs.decode("...", "base64_codec")
> "...".decode("rot13") => codecs.decode("...", "rot_13")
> "...".decode("zlib") => codecs.decode("...", "zlib_codec")
> "...".decode("hex") => codecs.decode("...", "hex_codec")
> "...".decode("bz2") => codecs.decode("...", "bz2_codec")
It would be better to add back the aliases we had for these codecs.
----------
nosy: +lemburg
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue17823>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com