diff --git a/src/modules/stream_notifications/twitch/webhook.py b/src/modules/stream_notifications/twitch/webhook.py index 467c245..f21aea6 100644 --- a/src/modules/stream_notifications/twitch/webhook.py +++ b/src/modules/stream_notifications/twitch/webhook.py @@ -104,14 +104,9 @@ class TwitchService: ) logger.info("Twitch service started") - while True: - await sleep(0.1) + await eventsub._keep_loop_alive() finally: - await eventsub.unsubscribe_all() await eventsub.stop() - - await sleep(10) - await self.twitch.close() raise RuntimeError("Twitch service stopped")