From dd15e22fb1cebda571bc3972247e72f1b74dc15b Mon Sep 17 00:00:00 2001 From: lilydjwg Date: Thu, 4 Apr 2024 19:49:57 +0800 Subject: [PATCH] minor fix for unbound variables --- lilac2/systemd.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lilac2/systemd.py b/lilac2/systemd.py index b6bfab6b..5b30b067 100644 --- a/lilac2/systemd.py +++ b/lilac2/systemd.py @@ -79,6 +79,7 @@ def _poll_cmd(pid: int) -> Generator[None, None, None]: except OSError as e: if e.errno == 22: return + raise poll = select.poll() poll.register(pidfd, select.POLLIN) @@ -98,6 +99,7 @@ def poll_rusage(name: str, deadline: float) -> tuple[RUsage, bool]: done_state = ['exited', 'failed'] try: + cgroup = '' time_start = time.monotonic() while True: pid, cgroup, state = _get_service_info(name)