mirror of
https://github.com/django/daphne.git
synced 2025-04-21 17:22:03 +03:00
Don't keep doing keepalives if main loop dies
This commit is contained in:
parent
b9f07475b7
commit
c937c4da6d
|
@ -66,4 +66,5 @@ class WebsocketAsyncioInterface(object):
|
|||
for protocol in self.factory.protocols.values():
|
||||
if time.time() - protocol.last_keepalive > expiry_window:
|
||||
protocol.sendKeepalive()
|
||||
self.loop.call_later(1, self.keepalive_sender)
|
||||
if self.loop.is_running():
|
||||
self.loop.call_later(1, self.keepalive_sender)
|
||||
|
|
Loading…
Reference in New Issue
Block a user