bypass cache for qobuz library items
authorMarcel van der Veldt <m.vanderveldt@outlook.com>
Fri, 17 Jun 2022 12:12:10 +0000 (14:12 +0200)
committerMarcel van der Veldt <m.vanderveldt@outlook.com>
Fri, 17 Jun 2022 12:12:10 +0000 (14:12 +0200)
music_assistant/music_providers/qobuz.py

index ffb4c37b7a4c048b6e7621764f743177292320f2..c55b50c0aa21d5a75d8788d4a6acfe32307f3a65 100644 (file)
@@ -114,28 +114,36 @@ class QobuzProvider(MusicProvider):
     async def get_library_artists(self) -> AsyncGenerator[Artist, None]:
         """Retrieve all library artists from Qobuz."""
         endpoint = "favorite/getUserFavorites"
-        for item in await self._get_all_items(endpoint, key="artists", type="artists"):
+        for item in await self._get_all_items(
+            endpoint, key="artists", type="artists", skip_cache=True
+        ):
             if item and item["id"]:
                 yield await self._parse_artist(item)
 
     async def get_library_albums(self) -> AsyncGenerator[Album, None]:
         """Retrieve all library albums from Qobuz."""
         endpoint = "favorite/getUserFavorites"
-        for item in await self._get_all_items(endpoint, key="albums", type="albums"):
+        for item in await self._get_all_items(
+            endpoint, key="albums", type="albums", skip_cache=True
+        ):
             if item and item["id"]:
                 yield await self._parse_album(item)
 
     async def get_library_tracks(self) -> AsyncGenerator[Track, None]:
         """Retrieve library tracks from Qobuz."""
         endpoint = "favorite/getUserFavorites"
-        for item in await self._get_all_items(endpoint, key="tracks", type="tracks"):
+        for item in await self._get_all_items(
+            endpoint, key="tracks", type="tracks", skip_cache=True
+        ):
             if item and item["id"]:
                 yield await self._parse_track(item)
 
     async def get_library_playlists(self) -> AsyncGenerator[Playlist, None]:
         """Retrieve all library playlists from the provider."""
         endpoint = "playlist/getUserPlaylists"
-        for item in await self._get_all_items(endpoint, key="playlists"):
+        for item in await self._get_all_items(
+            endpoint, key="playlists", skip_cache=True
+        ):
             if item and item["id"]:
                 yield await self._parse_playlist(item)