Call `actor.cancel(None)` from root to avoid mismatch with (any future) meth sig changes

pre_pretty_struct_dep_commit_b54cb66
Tyler Goodlet 2024-02-22 14:45:08 -05:00
parent 5eb62b3e9b
commit 4d0df1bb4a
2 changed files with 1 additions and 4 deletions

View File

@ -364,7 +364,6 @@ def test_local_task_fanout_from_stream(
'inf_streamer',
enable_modules=[__name__],
)
# with trio.fail_after(3):
async with (
p.open_context(inf_streamer) as (ctx, _),
ctx.open_stream() as stream,

View File

@ -253,9 +253,7 @@ async def open_root_actor(
# tempn.start_soon(an.exited.wait)
logger.cancel("Shutting down root actor")
await actor.cancel(
requesting_uid=actor.uid,
)
await actor.cancel(None) # self cancel
finally:
_state._current_actor = None