Skip to content

Commit b740d58

Browse files
committed
remove TransportClosed except in subscribe
1 parent a2a22b3 commit b740d58

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

gql/transport/phoenix_channel_websockets.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ async def _handle_answer(
368368
else:
369369
await super()._handle_answer(answer_type, answer_id, execution_result)
370370

371-
def _remove_listener(self, query_id) -> None:
371+
def _remove_listener(self, query_id: int) -> None:
372372
"""If the listener was a subscription, remove that information."""
373373
try:
374374
subscription_id = self._find_existing_subscription(query_id)

gql/transport/websockets.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -502,7 +502,7 @@ async def subscribe(
502502
)
503503
break
504504

505-
except (asyncio.CancelledError, GeneratorExit, TransportClosed) as e:
505+
except (asyncio.CancelledError, GeneratorExit) as e:
506506
log.debug(f"Exception in subscribe: {e!r}")
507507
if listener.send_stop:
508508
await self._send_stop_message(query_id)

0 commit comments

Comments
 (0)