From bca1e084116335fd939c2ee226070f0428cd5de8 Mon Sep 17 00:00:00 2001 From: Luke Hodkinson Date: Sat, 4 Nov 2017 22:04:59 +1100 Subject: [PATCH] Call connection_open after websocket handshake It seems that due to (recent?) changes in the websocket library, we now need to call "connection_open" to flag that the websocket is now ready to use. I've added that call just after the call to "connection_made". --- sanic/websocket.py | 1 + 1 file changed, 1 insertion(+) diff --git a/sanic/websocket.py b/sanic/websocket.py index 37b13f3c..bc78c76f 100644 --- a/sanic/websocket.py +++ b/sanic/websocket.py @@ -90,4 +90,5 @@ class WebSocketProtocol(HttpProtocol): ) self.websocket.subprotocol = subprotocol self.websocket.connection_made(request.transport) + self.websocket.connection_open() return self.websocket