From d46b1ba5c5db9cc7745872549597e3206eea604a Mon Sep 17 00:00:00 2001 From: Florian Wilde Date: Sat, 10 Oct 2026 23:43:40 +0200 Subject: [PATCH] test: Wettlauf beim Lesen von /proc//stat abfangen Co-Authored-By: Claude Opus 5.5 --- tests/test_linux_backend.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/test_linux_backend.py b/tests/test_linux_backend.py index fa4dd3b..570fe2e 100644 --- a/tests/test_linux_backend.py +++ b/tests/test_linux_backend.py @@ -127,7 +127,7 @@ def _alive(pid: int) -> bool: try: with open(f"/proc/{pid}/stat") as fh: return fh.read().split(")")[-1].split()[0] != "Z" - except FileNotFoundError: + except (FileNotFoundError, ProcessLookupError): # verschwindet beim Lesen → ESRCH return False