[New-bugs-announce] [issue12362] General Windows stdout redirection not working
report at bugs.python.org
Sun Jun 19 13:54:29 CEST 2011
New submission from CrouZ <alfred.theorin at gmail.com>:
Steps to repeat:
* Create the script foo.py consisting of the line: print("foo")
* Run: foo.py > bar
2.7.2: The file bar is created but empty. Prints the following message on exit:
close failed in file object destructor:
sys.excepthook is missing
3.1.4: The file bar is created but empty. No printouts indicating that something went wrong.
All: The file bar has the content foo.
sys.stdout, and probably also sys.stderr, do not appear to be set up properly.
2.7.2: stdout is set to a file but performing any operations on it throws the exception: IOError: [Errno 9] Bad file descriptor
3.1.4: stdout is set to None
All: python foo.py > bar
Windows 7 Ultimate SP1 x64 (6.1.7601)
Python 2.7.2 and 3.1.4 installed with the msi-installer including Registering Extensions.
title: General Windows stdout redirection not working
versions: Python 2.7, Python 3.1
Python tracker <report at bugs.python.org>
More information about the New-bugs-announce