From 20c660faa735947eb503bddce396684d70109d3a Mon Sep 17 00:00:00 2001 From: Tyler Goodlet Date: Fri, 29 Jul 2022 00:15:56 -0400 Subject: [PATCH] Add timeout on spawn error msg check --- tests/test_debugger.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/test_debugger.py b/tests/test_debugger.py index 5ede0a2..8f396e7 100644 --- a/tests/test_debugger.py +++ b/tests/test_debugger.py @@ -430,7 +430,11 @@ def test_multi_subactors( # wait for spawn error to show up spawn_err = "Attaching to pdb in crashed actor: ('spawn_error'" - while spawn_err not in before: + start = time.time() + while ( + spawn_err not in before + and (time.time() - start) < 3 + ): child.sendline('c') time.sleep(0.1) child.expect(r"\(Pdb\+\+\)")