I am getting an error message when I try open the media browser from any of my squeezebox media players. I get the error only with squeezebox and not any other media players. Prior to adding media file to the media folder I would get a “no media found” message, but after adding media (.mp3 files only) I get the following.
Logger: homeassistant.components.websocket_api.http.connection
Source: components/squeezebox/browse_media.py:153
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 11:29:14 AM (3 occurrences)
Last logged: 11:29:26 AM
[281473383879632] Error handling message: Unknown error
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/decorators.py", line 18, in _handle_async_response
await func(hass, connection, msg)
File "/usr/src/homeassistant/homeassistant/components/media_player/__init__.py", line 1066, in websocket_browse_media
payload = await player.async_browse_media(media_content_type, media_content_id)
File "/usr/src/homeassistant/homeassistant/components/squeezebox/media_player.py", line 584, in async_browse_media
return await library_payload(self._player)
File "/usr/src/homeassistant/homeassistant/components/squeezebox/browse_media.py", line 153, in library_payload
result = await player.async_browse(
File "/usr/local/lib/python3.8/site-packages/pysqueezebox/player.py", line 645, in async_browse
return await self._lms.async_browse(category, limit=limit, **kwargs)
File "/usr/local/lib/python3.8/site-packages/pysqueezebox/server.py", line 233, in async_browse
items = await self.async_get_category(item_type, limit, search)
File "/usr/local/lib/python3.8/site-packages/pysqueezebox/server.py", line 305, in async_get_category
return self.__dict__[category][2][:limit]
TypeError: 'NoneType' object is not subscriptable
Anyone else have this error?
I know enough to get into trouble but not enough to get myself out. I’m sure the logs are giving me all the info I need and I am just missing it.
Running a Home Assistant Blue machine so nothing custom.
I have not found a solution for this. I have been able to browes/play media that is stored on a network drive (synology server). I can not browse media stored locally on my home assistant server. One possible solution (I have not tested this) is to share the HA media folder to the network and then setup your squeeze box server to look there. Probably not the best idea but may be a workaround.
Hi, thanks for the answer.
Sadly, that’s not a good workaround for me…
I have a dedicated LMS and tons of music on and the HA is also an dedicated box with only HA on.
Don’t wan’t to mix…
I have this same issue, where media browsing is unavailable and returns an unknown error. I am able to resolve the issue by restarting the Frigate add-on.
I am not yet certain why this is happening, though.
Just for the sake of it: did anyone get closer to a solution?
I installed piCorePlayer and then via that also the LMS on an old Pi1, added the spotty plugin to connect to my spotify account, added the squeezebox integration to HA, and had the following experience:
mediabrowser error
then started a spotify playlist via the LMS web frontend
player in lovelace let’s me control the playlist and shows the album art
another try gives me the mediabrowser, but without the playlist button
i play around a bit more in the LMS frontend, adding playlists to favorites etc
switch back to the HA dashboard, try to open the mediabtrowser => again the error, and since then consistent
Quite a bummer I have to say, I was hoping to finally have the spotify integration for HA where I dont need to “side-control” things in another browser tab or on my phone…
Is someone familiar with the “etiquette” of pypi.org? There is an email address on there, but I’m not sure if it increases or horribly decreases the chance for a fix if I just send an email directly
For the ones who are still online here sometimes: let’s collect a few more infos.
Where is your LMS running?
On your HA device or separately?
Which hardware?
How does your library look like on LMS? (local files, web radios, spotify or other plugins, …?)
My setup:
piCorePlayer and LMS running together on an old Pi1
HA is running on a Pi3+
my LMS currently only uses the spotty Spotify plugin connected to my premium account, no local or network files
Hi! I just saw this thread. I’ll take a look and see what broke. At some point media browser was working for the Squeezebox integration, but I don’t use it regularly myself.
Thanks so much! Let me know if it helps to throw everything together in github as well for this case still. Whatever makes things easier for you, I’m so happy
Actually the setting is set to “yes”, or: already was from the start. I just realised though that the plugin needs a kind-of sub-plugin, a helper app, and there are various ones offered. I might try out another one…
Thank you for bringing this up again. I am still using a work around.
My setup:
Home Assistant on a Home Assistant Blue
Pi3+ running piCorePlayer and LMS
4 - speakers around the house with a PiZeroW running piCorePlayer
Synology for all my media files (mostly audiobooks and a few MP3 file for alerts and announcements)
I have moved all my media files to my Synology and it has been working for the most part. One problem with pulling from a network folder is sometimes it takes a few seconds to load the file. This creates awkward pauses between the alert sound and announcement. Or the announcement will run over the alert sound.
Okay, a complete rescan didnt make a difference. Is there by the way a certain endpoint/method that I can directly test against (via ssh or postman or whatever), for which the current media browser breaks? Then I would play around a bit more with various settings.
Thanks so much again for the quick reaction including the pull request etc.!
Oh, I think there might actually be another underlying issue:
As mentioned: my LMS and piCorePlayer are running on a first-generation Raspberry Pi.
Maybe the Pi is just too slow to provide the whole 800+ songs spotify library before a timeout kicks in?