Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 21 additions & 21 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ pylint = "4.0.2"
pytest = "8.4.2"
pytest-asyncio = "1.3.0"
pytest-cov = "7.0.0"
ruff = "0.13.3"
ruff = "0.14.5"
safety = "3.7.0"
yamllint = "1.37.1"
syrupy = "5.0.0"
Expand Down
16 changes: 8 additions & 8 deletions src/spotifyaio/spotify.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import asyncio
from dataclasses import dataclass
from importlib import metadata
from typing import TYPE_CHECKING, Any, Callable, Concatenate, Self
from typing import TYPE_CHECKING, Any, Concatenate, Self

from aiohttp import ClientSession
from aiohttp.hdrs import METH_DELETE, METH_GET, METH_POST, METH_PUT
Expand Down Expand Up @@ -79,7 +79,7 @@
from spotifyaio.util import get_identifier

if TYPE_CHECKING:
from collections.abc import Awaitable
from collections.abc import Awaitable, Callable

from spotifyaio import SimplifiedAlbum, SimplifiedTrack, Track

Expand Down Expand Up @@ -275,7 +275,7 @@ async def are_albums_saved(self, album_ids: list[str]) -> dict[str, bool]:
params: dict[str, Any] = {"ids": ",".join(identifiers)}
response = await self._get("v1/me/albums/contains", params=params)
body: list[bool] = orjson.loads(response) # pylint: disable=no-member
return dict(zip(identifiers, body))
return dict(zip(identifiers, body, strict=False))

async def is_album_saved(self, album_id: str) -> bool:
"""Check if album is saved."""
Expand Down Expand Up @@ -395,7 +395,7 @@ async def are_audiobooks_saved(self, audiobook_ids: list[str]) -> dict[str, bool
params: dict[str, Any] = {"ids": ",".join(identifiers)}
response = await self._get("v1/me/audiobooks/contains", params=params)
body: list[bool] = orjson.loads(response) # pylint: disable=no-member
return dict(zip(identifiers, body))
return dict(zip(identifiers, body, strict=False))

@catch_json_decode_error
async def get_categories(self) -> list[Category]:
Expand Down Expand Up @@ -495,7 +495,7 @@ async def are_episodes_saved(self, episode_ids: list[str]) -> dict[str, bool]:
params: dict[str, Any] = {"ids": ",".join(identifiers)}
response = await self._get("v1/me/episodes/contains", params=params)
body: list[bool] = orjson.loads(response) # pylint: disable=no-member
return dict(zip(identifiers, body))
return dict(zip(identifiers, body, strict=False))

async def is_episode_saved(self, episode_id: str) -> bool:
"""Check if episode is saved."""
Expand Down Expand Up @@ -868,7 +868,7 @@ async def are_shows_saved(self, show_ids: list[str]) -> dict[str, bool]:
params: dict[str, Any] = {"ids": ",".join(identifiers)}
response = await self._get("v1/me/shows/contains", params=params)
body: list[bool] = orjson.loads(response) # pylint: disable=no-member
return dict(zip(identifiers, body))
return dict(zip(identifiers, body, strict=False))

async def is_show_saved(self, show_id: str) -> bool:
"""Check if show is saved."""
Expand Down Expand Up @@ -922,7 +922,7 @@ async def are_tracks_saved(self, track_ids: list[str]) -> dict[str, bool]:
params: dict[str, Any] = {"ids": ",".join(identifiers)}
response = await self._get("v1/me/tracks/contains", params=params)
body: list[bool] = orjson.loads(response) # pylint: disable=no-member
return dict(zip(identifiers, body))
return dict(zip(identifiers, body, strict=False))

async def is_track_saved(self, track_id: str) -> bool:
"""Check if track is saved."""
Expand Down Expand Up @@ -1019,7 +1019,7 @@ async def are_accounts_followed(
params: dict[str, Any] = {"type": follow_type, "ids": ",".join(identifiers)}
response = await self._get("v1/me/following/contains", params=params)
body: list[bool] = orjson.loads(response) # pylint: disable=no-member
return dict(zip(identifiers, body))
return dict(zip(identifiers, body, strict=False))

@catch_json_decode_error
async def is_following_playlist(self, playlist_id: str) -> bool:
Expand Down
Loading