Updated ws_talk.py
This commit is contained in:
parent
85dbef72dc
commit
a2e4a2b17d
|
|
@ -3,8 +3,9 @@ from websocket import create_connection
|
||||||
|
|
||||||
ws = create_connection("ws://localhost:1212/talk")
|
ws = create_connection("ws://localhost:1212/talk")
|
||||||
while True:
|
while True:
|
||||||
ws.send(payload="{'text': 123, 'username': 'bob'}")#json.dumps({"op":"addr_sub", "addr":"dogecoin_address"}))
|
ws.send(payload=b"{'text': 123, 'username': 'bob'}")#json.dumps({"op":"addr_sub", "addr":"dogecoin_address"}))
|
||||||
result = ws.recv()
|
result = ws.recv()
|
||||||
print(eval(result))
|
|
||||||
print(result)
|
print(result)
|
||||||
|
#print(eval(result))
|
||||||
|
#print(result)
|
||||||
ws.close()
|
ws.close()
|
||||||
Loading…
Reference in New Issue
Block a user