Message96295
Martin,
actually, I was trying to convert some piece of code from python2 to
python3. And this statement was not converted by 2to3:
"x.decode('base64').decode('zlib')"
So, I read the official documentation, and found no hint about the
removal of these codecs.
For my specific use case, I can use "zlib.decompress" and
"base64.decodebytes", but I find that the ".encode()" and ".decode()"
helpers were useful in Python 2.
I don't know all the background of the removal of these codecs. But I
try to contribute to Python, and help Python 3 become at least as
featureful, and useful, as Python 2.
So, after reading the above comments, I think we may end up with
following changes:
* restore the "bytes-to-bytes" codecs in the "encodings" package
* then create new helpers on bytes objects (either
".transform()/.untransform()" or ".encodebytes()/.decodebytes") |
|
Date |
User |
Action |
Args |
2009-12-12 15:40:29 | flox | set | recipients:
+ flox, lemburg, loewis, skip.montanaro, georg.brandl, benjamin.peterson |
2009-12-12 15:40:29 | flox | set | messageid: <1260632429.18.0.94666723444.issue7475@psf.upfronthosting.co.za> |
2009-12-12 15:40:27 | flox | link | issue7475 messages |
2009-12-12 15:40:26 | flox | create | |
|