From 659481894c0c127fc57fbc48a525fc041428e289 Mon Sep 17 00:00:00 2001 From: marcelveldt Date: Sun, 20 Oct 2019 15:27:32 +0200 Subject: [PATCH] Update http_streamer.py --- music_assistant/http_streamer.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/music_assistant/http_streamer.py b/music_assistant/http_streamer.py index f25325e0..8261b7b2 100755 --- a/music_assistant/http_streamer.py +++ b/music_assistant/http_streamer.py @@ -68,8 +68,7 @@ class HTTPStreamer(): self.__stream_single, player, queue_item, resp, cancelled) # let the streaming begin! try: - while not cancelled.is_set(): - await asyncio.sleep(0.1) + await asyncio.gather(bg_task) except (asyncio.CancelledError): LOGGER.warning("stream cancelled") cancelled.set() -- 2.34.1