Skip to content

Commit

Permalink
Quick update to v8.1 of websockets
Browse files Browse the repository at this point in the history
  • Loading branch information
CmdrNorthpaw committed Mar 5, 2020
1 parent c8baee4 commit 2999b29
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion client/client-main.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@

async def sendData():
global data
uri = 'ws://34.73.189.184:9254'
uri = 'ws://192.168.1.114:9254'
async with websockets.connect(uri) as websocket:
await websocket.send(data)

Expand Down
4 changes: 2 additions & 2 deletions server/server-main.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@ async def pasteAndSend(data):
await channel.send(f"Report: {pasteLink}")

async def reciever():
host = 'ws://localhost:9254'
host = 'ws://192.168.1.114:9254'
async with websockets.connect(host) as socket:
print('Socket server running')
data = await socket.recv()
data = pickle.loads(data)
pasteAndSend(data)

server = websockets.serve(reciever, 'localhost', 9254)
server = websockets.serve(reciever, 'localhost', 9254, ping_timeout=None)
asyncio.get_event_loop().run_until_complete(server)

bot.run(discordKey)

0 comments on commit 2999b29

Please sign in to comment.