sys.std* streams have many other issues.
>>> sys.stdin.readable()
Traceback (most recent call last):
File "<pyshell#4>", line 1, in <module>
sys.stdin.readable()
AttributeError: readable
>>> sys.stdout.writable()
Traceback (most recent call last):
File "<pyshell#5>", line 1, in <module>
sys.stdout.writable()
AttributeError: writable
>>> sys.stdout.newlines
Traceback (most recent call last):
File "<pyshell#8>", line 1, in <module>
sys.stdout.newlines
AttributeError: newlines
>>> sys.stdin.read(1)
Traceback (most recent call last):
File "<pyshell#3>", line 1, in <module>
sys.stdin.read(1)
AttributeError: read
And some other.
Here is a patch that fixes almost all IDLE sys.std* issues. |