This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients Arfrever, docs@python, jaraco, jgeralnik, pitrou, r.david.murray, serhiy.storchaka, zach.ware
Date 2012-06-15.15:44:55
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1339775096.6648.163.camel@raxxla>
In-reply-to <1339772660.2.0.797575168594.issue15068@psf.upfronthosting.co.za>
Content
> Forget other filelike objects. The FileInput class only works with actual files,

No. sys.stdin can be reassigned before using FileInput. And FileInput
has openhook parameter (for read compressed files or get files from Web,
for example).

>  so the readlines function should always return at least as many bytes as its first parameter. Is this assumption wrong?

qwert
'qwert\n'

You type five characters "qwert" end press <Enter>. Python immediately
receives these six characters, and returns a result of
sys.stdin.readline(1000). Only six characters, and no one symbol more,
because more characters you have not entered yet.

I believe that for such questions will be more appropriate to use a
mailing list (python-list@python.org, or newsgroup
gmane.comp.python.general on news://news.gmane.org), and not bugtracker.
History
Date User Action Args
2012-06-15 15:44:56serhiy.storchakasetrecipients: + serhiy.storchaka, jaraco, pitrou, Arfrever, r.david.murray, docs@python, zach.ware, jgeralnik
2012-06-15 15:44:55serhiy.storchakalinkissue15068 messages
2012-06-15 15:44:55serhiy.storchakacreate