[Windows] Invalid handle with subprocesses with py2exe

Bug #543762 reported by Stani
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Phatch
Fix Released
Critical
Stani

Bug Description

Problem and solution are described here:
http://www.py2exe.org/index.cgi/Py2ExeSubprocessInteractions

Tags: windows
Revision history for this message
Stani (stani) wrote :

lib/system.py

# call pipes
# see http://www.py2exe.org/index.cgi/Py2ExeSubprocessInteractions
NULL_PIPE = file('nul', 'a')
STDOUT_STDERR_PIPES = {
        'stdin': NULL_PIPE,
        'stdout': subprocess.PIPE,
        'stderr': subprocess.PIPE,
}
NO_PIPES = {
        'stdin': NULL_PIPE,
        'stdout': NULL_PIPE,
        'stderr': NULL_PIPE,
}
try:
    # prevent subprocesses from showing console windows
    import win32process
    STDOUT_STDERR_PIPES['creationflags'] = win32process.CREATE_NO_WINDOW
    NO_PIPES['creationflags'] = win32process.CREATE_NO_WINDOW
except ImportError:
    pass

Changed in phatch:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.