From e9e6c523d954391ed4f7c715011e53893bb8118b Mon Sep 17 00:00:00 2001 From: Stijn Tintel Date: Wed, 17 Jan 2024 14:27:08 +0200 Subject: [PATCH] wake: increase WakeSession timeout With a WakeSession timeout of 200ms, some people frequently experience double wakes. Testing has shown that 400ms greatly reduces those double wakes, and does not introduce other issues. Let's make 400ms the default. --- app/internal/wake.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/internal/wake.py b/app/internal/wake.py index c259ad3a..0d5430ad 100644 --- a/app/internal/wake.py +++ b/app/internal/wake.py @@ -27,7 +27,7 @@ def add_event(self, event): log.debug(f"WakeSession {self.id} adding event {event}") self.events.append(event) - async def cleanup(self, timeout=200): + async def cleanup(self, timeout=400): await asyncio.sleep(timeout / 1000) max_volume = -1000.0 winner = None