Skip to content

Commit

Permalink
Allow Chromecast provider to handle/avoid images which are "too big" (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
ijc authored and marcelveldt committed Dec 23, 2024
1 parent 51b8eb5 commit cd723de
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion music_assistant/controllers/player_queues.py
Original file line number Diff line number Diff line change
Expand Up @@ -1261,7 +1261,7 @@ def player_media_from_queue_item(self, queue_item: QueueItem, flow_mode: bool) -
album.name if (album := getattr(queue_item.media_item, "album", None)) else ""
)
if queue_item.image:
media.image_url = self.mass.metadata.get_image_url(queue_item.image)
media.image_url = self.mass.metadata.get_image_url(queue_item.image, size=512)
return media

async def get_artist_tracks(self, artist: Artist) -> list[Track]:
Expand Down
2 changes: 1 addition & 1 deletion music_assistant/providers/chromecast/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -675,7 +675,7 @@ async def update_flow_metadata(self, castplayer: CastPlayer) -> None:
# update metadata of current item chromecast
if media_controller.status.media_custom_data["queue_item_id"] != current_item.queue_item_id:
image_url = (
self.mass.metadata.get_image_url(current_item.image)
self.mass.metadata.get_image_url(current_item.image, size=512)
if current_item.image
else MASS_LOGO_ONLINE
)
Expand Down
2 changes: 1 addition & 1 deletion scripts/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ if [ -d "$env_name" ]; then
echo "Virtual environment '$env_name' already exists."
else
echo "Creating Virtual environment..."
python -m venv .venv
${PYTHON:-python} -m venv .venv
fi
echo "Activating virtual environment..."
source .venv/bin/activate
Expand Down

0 comments on commit cd723de

Please sign in to comment.