flask-uwsgi-websocket icon indicating copy to clipboard operation
flask-uwsgi-websocket copied to clipboard

How to properly close a websocket

Open shanecarey17 opened this issue 7 years ago • 0 comments

Closing the websocket with

ws.close()

appears to delay the close and the client receives an abnormal close code (1006)

websockets.exceptions.ConnectionClosed: WebSocket connection is closed: code = 1006 (connection closed abnormally [internal]), no reason

what is the proper way to close the websocket?

shanecarey17 avatar Jan 11 '18 17:01 shanecarey17