STINNER Victor added the comment: >>> codecs.utf_8_decode('\u20ac'.encode('utf8')[:2]) ('', 0)
Oh... codecs.CODEC_decode are incremental decoders? I misunderstood completly this. "The bug is an issue in the design of codecs.Stream* classes: incremental decoders and encoders should be used instead of classic decoders/encoders." Hum, I suppose that the issue cannot be reproduded with TextIOWrapper, just because io.TextIOWrapper and codecs.StreamReader use different buffer sizes. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue15278> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com