From e084925f3d12d49c172d6c3deae6e5c8566b2494 Mon Sep 17 00:00:00 2001 From: Tyler Goodlet Date: Mon, 5 Jul 2021 14:48:45 -0400 Subject: [PATCH] Shield hard kill call? --- tractor/_spawn.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tractor/_spawn.py b/tractor/_spawn.py index 678250b9d..62e650b58 100644 --- a/tractor/_spawn.py +++ b/tractor/_spawn.py @@ -212,7 +212,8 @@ async def spawn_subactor( # since trio does this internally on ``__aexit__()`` log.debug(f"Attempting to kill {proc}") - await do_hard_kill(proc) + with trio.CancelScope(shield=True): + await do_hard_kill(proc) async def new_proc(