Worker: wait for a node process's exit status before telling a signal from a failure
This commit is contained in:
@@ -304,6 +304,10 @@ class Agent:
|
||||
while True:
|
||||
line = await loop.run_in_executor(None, worker.read_line)
|
||||
if not line:
|
||||
# The pipe closes a moment before the exit status is
|
||||
# there to read, and a signal is only told by the status.
|
||||
with contextlib.suppress(subprocess.TimeoutExpired):
|
||||
await loop.run_in_executor(None, worker.proc.wait, 1)
|
||||
await socket.send(
|
||||
json.dumps(
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user