]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
fixup! lock.ops.unlock_one_safe: Invert run-match logic
authorZack Cerza <zack@cerza.org>
Thu, 11 Dec 2025 02:11:30 +0000 (19:11 -0700)
committerDan Mick <dan.mick@redhat.com>
Fri, 12 Dec 2025 09:18:37 +0000 (01:18 -0800)
teuthology/lock/ops.py

index d11b9af71a44c30df4dc01d88ad9d2c18a797379..1db9daad14ac81d747ce408c062260684c23eec0 100644 (file)
@@ -200,7 +200,7 @@ def unlock_one_safe(name: str, owner: str, run_name: str = "", job_id: str = "")
         if job_id and not maybe_job.endswith(f"{run_name}/{job_id}"):
             log.info("Not unlocking {name} since it is running {maybe_job}, not {run_name}/{job_id}")
             return False
-        elif not maybe_job.endswith(run_name):
+        elif not not job_id and maybe_job.endswith(run_name):
             log.info(f"Not unlocking {name} since it is running {maybe_job}, not {run_name}")
             return False
         else: