Message327095
I think one bug here is that codecs readers use str.splitlines() internally. The splitlines method treats a bunch of different characters as line separators, unlike io.<file>.readlines(). So, you end up with different behavior between doing iter(codecs.getreader(...)) and iter(io.open(...)).
We can argue if str.splitlines() is doing the correct thing, see the table here:
https://docs.python.org/3.8/library/stdtypes.html#str.splitlines
However, it seems clearer to me that readlines() on a codecs reader and on a file object should really be splitting lines on the same characters. |
|
Date |
User |
Action |
Args |
2018-10-04 22:53:00 | nascheme | set | recipients:
+ nascheme, lemburg, doerwalter, belopolsky, vstinner, ezio.melotti, r.david.murray, serhiy.storchaka, wpk |
2018-10-04 22:53:00 | nascheme | set | messageid: <1538693580.59.0.545547206417.issue18291@psf.upfronthosting.co.za> |
2018-10-04 22:53:00 | nascheme | link | issue18291 messages |
2018-10-04 22:53:00 | nascheme | create | |
|