[issue26016] io.TextIOWrapper.tell() report 65bit number when mix readline() + tell()

Martin Panter report at bugs.python.org
Tue Jan 5 15:20:23 EST 2016


Martin Panter added the comment:

The documentation for tell() <https://docs.python.org/3/library/io.html#io.TextIOBase.tell> says that it returns an opaque number. Depending on the codec used, it might have to record the state of the text decoder, CRLF decoder, byte position, etc, all in that number. So I don’t think the return value being large is a bug.

Perhaps the change in behaviour from Python 2 is due to Issue 11114. Also, Issue 25849 was recently opened about text file seeking.

----------
nosy: +martin.panter

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26016>
_______________________________________


More information about the Python-bugs-list mailing list