ws
This commit is contained in:
parent
7061757f27
commit
f68f33cd34
@ -75,12 +75,15 @@ manager = WebsocketUtil()
|
|||||||
|
|
||||||
|
|
||||||
def write(id: str, ws: List):
|
def write(id: str, ws: List):
|
||||||
|
print(f"序列化对象{ws}")
|
||||||
with open(f"{id}.pkl", "wb") as f:
|
with open(f"{id}.pkl", "wb") as f:
|
||||||
wsdump = pickle.dump(ws, f)
|
wsdump = pickle.dump(ws, f)
|
||||||
|
|
||||||
|
|
||||||
def read(id: str):
|
def read(id: str):
|
||||||
|
|
||||||
with open(f"{id}.pkl", "rb") as f:
|
with open(f"{id}.pkl", "rb") as f:
|
||||||
wss = pickle.load(f)
|
wss = pickle.load(f)
|
||||||
print(wss)
|
print(wss)
|
||||||
|
print(f"反序列化对象{wss}")
|
||||||
return wss
|
return wss
|
Loading…
x
Reference in New Issue
Block a user