diff --git a/app/utils/websocket_tool.py b/app/utils/websocket_tool.py index 9c720d7..44d6c9e 100644 --- a/app/utils/websocket_tool.py +++ b/app/utils/websocket_tool.py @@ -75,12 +75,15 @@ manager = WebsocketUtil() def write(id: str, ws: List): + print(f"序列化对象{ws}") with open(f"{id}.pkl", "wb") as f: wsdump = pickle.dump(ws, f) def read(id: str): + with open(f"{id}.pkl", "rb") as f: wss = pickle.load(f) print(wss) + print(f"反序列化对象{wss}") return wss \ No newline at end of file