Marcus Gröber added the comment:

I came across this today as well. A short way of summarizing this error seems 
to be:

Reading a file using readline (or "for line in file") fails, if the following 
two conditions are true:

•       A codec (e.g. UTF-8) for a multi-byte encoding is used, and
•       The first line of the file is at least 73 bytes long, and contains a 
multi-byte-sequence that starts before offset 72, and ends after offset 72

At least for UTF-8 input files, it may be possible to work around this by 
opening the input file without a codec, and then applying decode("utf-8") to 
each line.

----------
nosy: +Marcus.Gröber

_______________________________________
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

Reply via email to