don't close websocket when mailbox is deleted
This made sense for ServerSentEvent channels (which has no purpose once the channel was gone), but not so much for websockets. And it prevented testing duplicate-close.
This commit is contained in:
parent
f044ef0efa
commit
399efb374c
|
@ -194,7 +194,7 @@ class WebSocketRendezvous(websocket.WebSocketServerProtocol):
|
|||
def _send(event):
|
||||
self.send("message", message=event)
|
||||
def _stop():
|
||||
self._reactor.callLater(0, self.transport.loseConnection)
|
||||
pass
|
||||
for old_message in self._mailbox.add_listener(self, _send, _stop):
|
||||
_send(old_message)
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user