diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2015-10-01 11:16:43 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2015-10-01 11:16:43 (GMT) |
commit | 98f223dfa0440529261e921c8b9ec9a955c6d27f (patch) | |
tree | eed6e4cc0caeb944353816427e15d0d27fcbc832 /Lib/test/eintrdata | |
parent | 2c6ea295babf4100422981f4ba1dbed27974a3dc (diff) | |
download | cpython-98f223dfa0440529261e921c8b9ec9a955c6d27f.zip cpython-98f223dfa0440529261e921c8b9ec9a955c6d27f.tar.gz cpython-98f223dfa0440529261e921c8b9ec9a955c6d27f.tar.bz2 |
Issue #25277: Set a timeout of 10 minutes in test_eintr using faulthandler to
try to debug a hang on the FreeBSD 9 buildbot.
Run also eintr_tester.py with python "-u" command line option to try to get the
full output on hang/crash.
Diffstat (limited to 'Lib/test/eintrdata')
-rw-r--r-- | Lib/test/eintrdata/eintr_tester.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/test/eintrdata/eintr_tester.py b/Lib/test/eintrdata/eintr_tester.py index e1e0d91..443ccd5 100644 --- a/Lib/test/eintrdata/eintr_tester.py +++ b/Lib/test/eintrdata/eintr_tester.py @@ -9,6 +9,7 @@ sub-second periodicity (contrarily to signal()). """ import contextlib +import faulthandler import io import os import select @@ -50,6 +51,9 @@ class EINTRBaseTest(unittest.TestCase): signal.setitimer(signal.ITIMER_REAL, cls.signal_delay, cls.signal_period) + # Issue #25277: Use faulthandler to try to debug a hang on FreeBSD + faulthandler.dump_traceback_later(10 * 60, exit=True) + @classmethod def stop_alarm(cls): signal.setitimer(signal.ITIMER_REAL, 0, 0) @@ -58,6 +62,7 @@ class EINTRBaseTest(unittest.TestCase): def tearDownClass(cls): cls.stop_alarm() signal.signal(signal.SIGALRM, cls.orig_handler) + faulthandler.cancel_dump_traceback_later() @classmethod def _sleep(cls): |