diff options
author | Olivier Gayot <olivier.gayot@sigexec.com> | 2025-08-18 11:37:51 +0200 |
---|---|---|
committer | Olivier Gayot <olivier.gayot@sigexec.com> | 2025-08-18 11:56:22 +0200 |
commit | 6881f41f8e10bf6f7fd806454f8b8359b9f3d325 (patch) | |
tree | 9320edc909858f56bb2a20370cc85abdf16aa5e8 /swiftstory/interface/ws.py | |
parent | 53d81d71d071543b8dbc24d6f16cbde98f5cc3ce (diff) |
swiftstory: move out of legacy websockets 14.0 implementationwebsockets-new-impl
https://websockets.readthedocs.io/en/stable/howto/upgrade.html
Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
Diffstat (limited to 'swiftstory/interface/ws.py')
-rw-r--r-- | swiftstory/interface/ws.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/swiftstory/interface/ws.py b/swiftstory/interface/ws.py index 082ed1a..e9150dd 100644 --- a/swiftstory/interface/ws.py +++ b/swiftstory/interface/ws.py @@ -7,7 +7,7 @@ import logging from typing import Union import websockets.exceptions -from websockets.server import WebSocketServerProtocol +from websockets.asyncio.server import ServerConnection from swiftstory.client import Client from swiftstory.exception import WrongAction, JoinError @@ -20,7 +20,7 @@ class WebsocketsInterface: def __init__(self, game_manager: GameManager): self.game_manager = game_manager - async def connection_handler(self, websocket: WebSocketServerProtocol, path: str) -> None: + async def connection_handler(self, websocket: ServerConnection) -> None: """ Coroutine that handles one websocket connection. """ client = Client(websocket, self.game_manager) |