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 vstinner
Recipients David.Edelsohn, db3l, gvanrossum, koobs, larry, ncoghlan, neologix, pitrou, python-dev, sbt, skrah, vstinner
Date 2013-11-21.10:17:14
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1385029035.96.0.00502441214031.issue19652@psf.upfronthosting.co.za>
In-reply-to
Content
asyncio_subprocess_watchdog.patch:

* add test_asyncio.watchdog.setup_watchdog(): use faulthandler.dump_traceback_later() to kill the process if it hangs more than 'timeout' seconds (do nothing if faulthandler is not present, eg. on other Python VMs than CPython)
* add SubprocessTestsMixin.debug_info(): return returncode, stdout, stderr
* use debug_info() on functions using subprocess may may hang

The patch should give more information on the child process if it hangs. I didn't see the test_asyncio hang on "AMD64 Snow Leop 3.x" recently. The hang is probably random :-/

I chose a default timeout of 5 minutes, it should be enough for the short tests of test_asyncio. You may set the timeout to 15 minutes if a buildbot is too slow. Or set the timeout to 1 minute if you prefer to not hang a buildbot too long.

I tested asyncio_subprocess_watchdog.patch manually with a shorter timeout and by adding time.sleep(60) in echo.py, echo2.py and echo3.py.
History
Date User Action Args
2013-11-21 10:17:16vstinnersetrecipients: + vstinner, gvanrossum, db3l, ncoghlan, pitrou, larry, skrah, neologix, python-dev, sbt, koobs, David.Edelsohn
2013-11-21 10:17:15vstinnersetmessageid: <1385029035.96.0.00502441214031.issue19652@psf.upfronthosting.co.za>
2013-11-21 10:17:15vstinnerlinkissue19652 messages
2013-11-21 10:17:15vstinnercreate