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.

classification
Title: sys.stdin.read won't return on EOF
Type: behavior Stage:
Components: Library (Lib) Versions: Python 3.0
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: Nosy List: benjamin.peterson
Priority: release blocker Keywords:

Created on 2008-08-01 16:06 by benjamin.peterson, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (2)
msg70565 - (view) Author: Benjamin Peterson (benjamin.peterson) * (Python committer) Date: 2008-08-01 16:06
$ ./python.exe -c "import sys; sys.stdin.read()"
^D

In 2.6, this returns, but in 3.0, it still hangs despite having gotten
EOF. When a KeyboardInterrupt is given, this is the traceback:

^CTraceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/temp/python/py3k/Lib/io.py", line 1692, in read
    decoder.decode(self.buffer.read(), final=True))
  File "/temp/python/py3k/Lib/io.py", line 923, in read
    chunk = self.raw.read()
KeyboardInterrupt
msg70566 - (view) Author: Benjamin Peterson (benjamin.peterson) * (Python committer) Date: 2008-08-01 16:25
I'm sorry. This is my oversight.
History
Date User Action Args
2022-04-11 14:56:37adminsetgithub: 47733
2008-08-01 16:25:41benjamin.petersonsetstatus: open -> closed
resolution: not a bug
messages: + msg70566
2008-08-01 16:06:07benjamin.petersoncreate