From 412554c9d4409432289a6fa24826d9dbb62785aa Mon Sep 17 00:00:00 2001 From: iopapamanoglou Date: Thu, 7 Nov 2024 13:49:03 +0100 Subject: [PATCH] fix lock --- src/faebryk/libs/util.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/faebryk/libs/util.py b/src/faebryk/libs/util.py index 4467074e..2f34a72a 100644 --- a/src/faebryk/libs/util.py +++ b/src/faebryk/libs/util.py @@ -1212,7 +1212,7 @@ def global_lock(lock_file_path: Path, timeout_s: float | None = None): try: pid = int(lock_file_path.read_text()) except ValueError: - lock_file_path.unlink() + lock_file_path.unlink(missing_ok=True) continue assert pid != os.getpid() if not psutil.pid_exists(pid):