Widened errors caught from os.kill()

This commit is contained in:
richardpaulhudson 2022-08-24 19:14:41 +02:00
parent 40416b1a3f
commit 1bf82db1e6

View File

@ -303,7 +303,7 @@ def _process_worker_status_messages(
for other_cmd_info in (c for c in cmd_infos if c.state.name == "running"):
try:
os.kill(cast(int, other_cmd_info.pid), SIGTERM)
except ProcessLookupError:
except: # different errors on different OS
# the subprocess the main process is trying to kill could already
# have completed, and the message from the worker process notifying
# the main process about this could still be in the queue