From 71bb87aa3a249af37ec68d00b0a5853f58923f1e Mon Sep 17 00:00:00 2001 From: Tyler Goodlet Date: Fri, 9 Nov 2018 01:53:15 -0500 Subject: [PATCH] Drop deprecated trio error --- tractor/_ipc.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tractor/_ipc.py b/tractor/_ipc.py index 6e2349e..52b1ca5 100644 --- a/tractor/_ipc.py +++ b/tractor/_ipc.py @@ -30,7 +30,7 @@ class StreamQueue: try: data = await self.stream.receive_some(2**10) log.trace(f"received {data}") # type: ignore - except trio.BrokenStreamError: + except trio.BrokenResourceError: log.error(f"Stream connection {self.raddr} broke") return @@ -127,7 +127,7 @@ class Channel: assert self.squeue try: return await self.squeue.get() - except trio.BrokenStreamError: + except trio.BrokenResourceError: if self._autorecon: await self._reconnect() return await self.recv() @@ -191,7 +191,7 @@ class Channel: # # optimization, passing None through all the # # time is pointless # await self.squeue.put(sent) - except trio.BrokenStreamError: + except trio.BrokenResourceError: if not self._autorecon: raise await self.aclose()