This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author martin.panter
Recipients Mike Pomraning, SilentGhost, martin.panter, vstinner
Date 2016-01-01.09:01:29
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1451638889.68.0.248338851045.issue25942@psf.upfronthosting.co.za>
In-reply-to
Content
Doesn’t this scenario apply equally to run(), or check_output() in 3.4?

I suspect the explicit p.wait() call is not needed either. The context manager should already be calling wait().

One possible problem that I can think of: if you set a timeout, then interrupt the call with KeyboardInterrupt or similar, the context manager will now wait without without a timeout. Demo:

# Hit Ctrl+C before the 3 s timeout, and it will delay 10 s
call('trap "" INT && sleep 10', shell=True, timeout=3)
History
Date User Action Args
2016-01-01 09:01:29martin.pantersetrecipients: + martin.panter, vstinner, SilentGhost, Mike Pomraning
2016-01-01 09:01:29martin.pantersetmessageid: <1451638889.68.0.248338851045.issue25942@psf.upfronthosting.co.za>
2016-01-01 09:01:29martin.panterlinkissue25942 messages
2016-01-01 09:01:29martin.pantercreate