Message253547
Under Windows, if I do FreeConsole and then subprocess.call with redirected stdin or stdout or stderr, then subprocess.call fails. The only solution is either DO NOT redirect any handle OR to redirect ALL of them. The problem lies in function _get_handles at subprocess.py:810 (Python 2.7.10), which does:
* GetStdHandle
* DuplicateHandle via _make_inheritable.
DuplicateHandle fails if called on stdin, stdout or stderr after FreeConsole.
$ cygstart /mnt/c/utils/Python35/python.exe testcase.py fails
$ cygstart /mnt/c/utils/Python35/python.exe testcase.py works1
$ cygstart /mnt/c/utils/Python35/python.exe testcase.py works2
$ cygstart /mnt/c/utils/Python35/python.exe testcase.py works3 |
|
Date |
User |
Action |
Args |
2015-10-27 15:33:15 | George Prekas | set | recipients:
+ George Prekas |
2015-10-27 15:33:14 | George Prekas | set | messageid: <1445959994.99.0.328533880523.issue25492@psf.upfronthosting.co.za> |
2015-10-27 15:33:14 | George Prekas | link | issue25492 messages |
2015-10-27 15:33:14 | George Prekas | create | |
|