Author terry.reedy
Recipients Weird, amaury.forgeotdarc, benjamin.peterson, chn, denversc, georg.brandl, jmfauth, kevinwatters, terry.reedy, trentm, twhitema
Date 2012-02-12.23:14:31
SpamBayes Score 7.72232e-09
Marked as misclassified No
Message-id <1329088472.37.0.857080718393.issue3905@psf.upfronthosting.co.za>
In-reply-to
Content
In 3.2.2, starting IDLE from a Command Prompt, I get the same error as Denver. Starting IDLE 'normally', from the icon, there is no error. So even though Command Prompt detaches pythonw in some way and gives me a new prompt to do something else, there is something different about the pythonw process that trips up subprocess.

Changing ["python", "-c", "print(32)"] to ["notepad"] gives the same result. Running in the interactive interpreted eliminated the error. So does changing stdin=None to stdin=subprocess.PIPE eliminates the error and brings up Notepad, which seems to operate normally. (I am guessing that it ignores stdin, etc.).

I see that that the latter was known in the original post and plausibly diagnosed by Trent Mick, but never fixed because it was not obvious how to do so.

Can the WindowsError be caught in subproccess, and if it is this error (6), follow the alternate patch that is used for NULL returns? Could that cause worse problems that the current situation?

If this is unfixable due to Windows behavior, perhaps we should say something in the doc.
History
Date User Action Args
2012-02-12 23:14:32terry.reedysetrecipients: + terry.reedy, georg.brandl, amaury.forgeotdarc, kevinwatters, benjamin.peterson, trentm, jmfauth, twhitema, Weird, denversc, chn
2012-02-12 23:14:32terry.reedysetmessageid: <1329088472.37.0.857080718393.issue3905@psf.upfronthosting.co.za>
2012-02-12 23:14:31terry.reedylinkissue3905 messages
2012-02-12 23:14:31terry.reedycreate