Make sure to wait trio processes on teardown

drop_cloudpickle
Tyler Goodlet 2020-07-20 19:50:47 -04:00
parent 0b305fd78a
commit 4516febe26
1 changed files with 3 additions and 1 deletions

View File

@ -168,11 +168,13 @@ async def run_in_process(async_fn, *args, **kwargs):
stdin=subprocess.PIPE stdin=subprocess.PIPE
) )
# send over func to call
await p.stdin.send_all(encoded_job) await p.stdin.send_all(encoded_job)
yield p yield p
#return cloudpickle.loads(p.stdout) # wait for termination
await p.wait()
async def new_proc( async def new_proc(