Skip to content

Commit

Permalink
fix close but scheduler shutdowned
Browse files Browse the repository at this point in the history
  • Loading branch information
Antoine TRAN committed Dec 4, 2023
1 parent 080144b commit 161ebda
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fastapi_websocket_rpc/websocket_rpc_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ async def recv(self):
async def close(self, code: int = 1000):
if self._websocket is not None:
# Case opened, we have something to close.
await self._websocket.close(code)
#await asyncio.get_event_loop().run_in_executor(None, self._websocket.close,code)
self._websocket.close(code)

async def handle_exception(self, exception: Exception):
try:
Expand Down

0 comments on commit 161ebda

Please sign in to comment.