From 45ca4e3bf436b4ae9db4dd5423e0e50f2a5d9d34 Mon Sep 17 00:00:00 2001 From: Paul Nilsson Date: Tue, 10 Dec 2024 12:18:57 +0100 Subject: [PATCH] Fixed blocking problem --- pilot/info/jobdata.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pilot/info/jobdata.py b/pilot/info/jobdata.py index c9e41ad6..dba0726a 100644 --- a/pilot/info/jobdata.py +++ b/pilot/info/jobdata.py @@ -1088,7 +1088,8 @@ def collect_zombies(self, depth: int = None): for zombie in self.zombies: try: logger.info(f"zombie collector waiting for pid {zombie}") - _id, _ = os.waitpid(zombie, os.WNOHANG if current_depth else 0) + # dangerous, can lead to blocking : _id, _ = os.waitpid(zombie, os.WNOHANG if current_depth else 0) + _id, _ = os.waitpid(zombie, os.WNOHANG) except OSError as exc: logger.info(f"harmless exception when collecting zombies: {exc}") zombies_to_remove.append(zombie)