Skip to content

Commit eeb6f02

Browse files
committed
ignore StopAsyncIteration when shutting down
1 parent 6942032 commit eeb6f02

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

trio_asyncio/base.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -787,6 +787,8 @@ async def _main_loop_exit(self):
787787
await self._main_loop_one(no_wait=True)
788788
except trio.WouldBlock:
789789
break
790+
except StopAsyncIteration:
791+
pass
790792

791793
# Kill off unprocessed work
792794
self._cancel_fds()

0 commit comments

Comments
 (0)