From c6a1ee78fdeaca563f1a1676bd53c59bcd32ef4b Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Thu, 29 Jan 2026 15:20:16 -0800 Subject: [PATCH] [python] In tests, print deployment status while waiting for it to change. We've seen timeouts in places where they shouldn't happen. This ought to help understand what's happening. Signed-off-by: Ben Pfaff --- python/tests/platform/helper.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/python/tests/platform/helper.py b/python/tests/platform/helper.py index 32aa123e88..7929f4c73b 100644 --- a/python/tests/platform/helper.py +++ b/python/tests/platform/helper.py @@ -127,7 +127,8 @@ def wait_for_deployment_status( - If 'desired' is a function, until it returns true when passed the deployment status. """ - deadline = time.time() + timeout_s + start = time.time() + deadline = start + timeout_s last = None while time.time() < deadline: r = get_pipeline(name, "status") @@ -135,7 +136,10 @@ def wait_for_deployment_status( time.sleep(0.25) continue obj = r.json() - last = obj.get("deployment_status") + status = obj.get("deployment_status") + if status != last: + print(f"After {time.time() - start:.1f} seconds: status is {status}") + last = status if last == desired if isinstance(desired, str) else desired(last): return obj time.sleep(0.25)