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 amaury.forgeotdarc
Recipients amaury.forgeotdarc, christian.heimes, draghuram, gvanrossum
Date 2007-11-06.16:51:50
SpamBayes Score 0.05384388
Marked as misclassified No
Message-id <1194367910.86.0.84550784944.issue1395@psf.upfronthosting.co.za>
In-reply-to
Content
This patch goes in the right direction, but has several problems IMO:

- it reads a complete chunk for just one more byte
- the re-read should be disabled when lineends are not translated
these two are minor annoyance and can be easily corrected, but:

- there is no limit to the re-read; it can exhaust the memory if the
source is a big file with many \r (like a Mac text file)

- How does this behave if the underlying stream has not yet available
data (a socket, a terminal, or an opened file): will the re-read block
at the 129th byte until more data is available? If so, it is annoying
for a simple call to read(1).

I will try to write these test cases if you want.
History
Date User Action Args
2007-11-06 16:51:51amaury.forgeotdarcsetspambayes_score: 0.0538439 -> 0.05384388
recipients: + amaury.forgeotdarc, gvanrossum, draghuram, christian.heimes
2007-11-06 16:51:50amaury.forgeotdarcsetspambayes_score: 0.0538439 -> 0.0538439
messageid: <1194367910.86.0.84550784944.issue1395@psf.upfronthosting.co.za>
2007-11-06 16:51:50amaury.forgeotdarclinkissue1395 messages
2007-11-06 16:51:50amaury.forgeotdarccreate