From e83aa79bc9f9b840d1ba59b267da7ae2f3eac970 Mon Sep 17 00:00:00 2001 From: Alexandru Mahmoud Date: Tue, 30 Jul 2024 13:53:37 -0400 Subject: [PATCH] not any not -> all --- lib/galaxy/jobs/runners/util/pykube_util.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/galaxy/jobs/runners/util/pykube_util.py b/lib/galaxy/jobs/runners/util/pykube_util.py index 19fda9d68a02..0c4861bf22ae 100644 --- a/lib/galaxy/jobs/runners/util/pykube_util.py +++ b/lib/galaxy/jobs/runners/util/pykube_util.py @@ -95,8 +95,8 @@ def find_pod_object_by_name(pykube_api, job_name, namespace=None): def is_pod_running(pykube_api, pod, namespace=None): - is_running = not any( - c.get("state", {}).get("running", {}).get("startedAt", False) == False + is_running = all( + c.get("state", {}).get("running", {}).get("startedAt", False) for c in pod.obj["status"].get("containerStatuses", []) ) if pod.obj["status"].get("phase") == "Running" and is_running: