Closed aerozinga closed 2 years ago
media_player documentation media_player source (message by IssueLinks)
Hey there @home-assistant/core, mind taking a look at this issue as it has been labeled with an integration (media_player
) you are listed as a code owner for? Thanks!
(message by CodeOwnersMention)
same problem here on a Sangean WFR28C Radio using :
log:
Logger: homeassistant.components.media_player
Source: components/frontier_silicon/media_player.py:157
Integration: Media player (documentation, issues)
First occurred: 09:21:32 (1 occurrences)
Last logged: 09:21:32
frontier_silicon: Error on device update!
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 446, in _async_add_entity
await entity.async_device_update(warning=False)
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 702, in async_device_update
await task
File "/usr/src/homeassistant/homeassistant/components/frontier_silicon/media_player.py", line 157, in async_update
mode.label: mode.key for mode in await afsapi.get_modes()
File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 577, in get_modes
self.__modes = [
File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 578, in <listcomp>
PlayerMode(key=k, **v) # type: ignore
TypeError: PlayerMode.__init__() missing 2 required positional arguments: 'streamable' and 'modetype'
using frontier_silicon as media player platform:
# Sangean WFR28C
- platform: frontier_silicon
host: 192.168.178.31
name: Keukenradio
Same issue as others, is a fix planned?
Logger: homeassistant.components.media_player Source: components/frontier_silicon/media_player.py:157 Integration: Media player (documentation, issues) First occurred: 22:47:14 (1 occurrences) Last logged: 22:47:14
frontier_silicon: Error on device update!
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 446, in _async_add_entity
await entity.async_device_update(warning=False)
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 702, in async_device_update
await task
File "/usr/src/homeassistant/homeassistant/components/frontier_silicon/media_player.py", line 157, in async_update
mode.label: mode.key for mode in await afsapi.get_modes()
File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 577, in get_modes
self.modes = [
File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 578, in
I'm getting similar thing for Yamaha reciever, so maybe this is something bigger in media_player
integration.
Logger: homeassistant.components.media_player
Source: components/yamaha/media_player.py:127
Integration: Media Player (documentation, issues)
First occurred: 09:17:45 (1 occurrences)
Last logged: 09:17:45
Error while setting up yamaha platform for media_player
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 250, in _async_setup_platform
await asyncio.shield(task)
File "/usr/src/homeassistant/homeassistant/components/yamaha/media_player.py", line 150, in async_setup_platform
receivers = await hass.async_add_executor_job(_discovery, config_info)
File "/usr/local/lib/python3.10/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/src/homeassistant/homeassistant/components/yamaha/media_player.py", line 127, in _discovery
for recv in rxv.find():
File "/usr/local/lib/python3.10/site-packages/rxv/__init__.py", line 19, in find
return [RXV(**ri._asdict()) for ri in ssdp.discover(timeout=timeout)]
File "/usr/local/lib/python3.10/site-packages/rxv/ssdp.py", line 68, in discover
m = re.search(r"LOCATION:(.+)", res.decode('utf-8'), re.IGNORECASE)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0: invalid start byte
media_player:
- platform: yamaha
zone_ignore:
- "Zone_2"
I'm getting similar thing for Yamaha reciever, so maybe this is something bigger in
media_player
integration.Logger: homeassistant.components.media_player Source: components/yamaha/media_player.py:127 Integration: Media Player (documentation, issues) First occurred: 09:17:45 (1 occurrences) Last logged: 09:17:45 Error while setting up yamaha platform for media_player Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 250, in _async_setup_platform await asyncio.shield(task) File "/usr/src/homeassistant/homeassistant/components/yamaha/media_player.py", line 150, in async_setup_platform receivers = await hass.async_add_executor_job(_discovery, config_info) File "/usr/local/lib/python3.10/concurrent/futures/thread.py", line 58, in run result = self.fn(*self.args, **self.kwargs) File "/usr/src/homeassistant/homeassistant/components/yamaha/media_player.py", line 127, in _discovery for recv in rxv.find(): File "/usr/local/lib/python3.10/site-packages/rxv/__init__.py", line 19, in find return [RXV(**ri._asdict()) for ri in ssdp.discover(timeout=timeout)] File "/usr/local/lib/python3.10/site-packages/rxv/ssdp.py", line 68, in discover m = re.search(r"LOCATION:(.+)", res.decode('utf-8'), re.IGNORECASE) UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0: invalid start byte
media_player: - platform: yamaha zone_ignore: - "Zone_2"
This one seems not to be related. I use frontier_silicon with a yamaha receiver. Yamaha is working fine. But I have similar error messages concerning frontier_silicon.
Sam for me with pure Radio. No problems before 2022.7
`Logger: homeassistant.components.media_player Source: components/frontier_silicon/media_player.py:157 Integration: Mediaplayer (documentation, issues) First occurred: 18:07:58 (2 occurrences) Last logged: 18:07:58
frontier_silicon: Error on device update!
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 446, in _async_add_entity
await entity.async_device_update(warning=False)
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 702, in async_device_update
await task
File "/usr/src/homeassistant/homeassistant/components/frontier_silicon/media_player.py", line 157, in async_update
mode.label: mode.key for mode in await afsapi.get_modes()
File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 577, in get_modes
self.modes = [
File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 578, in
`
Maybe @wlcrs can take a look, as https://github.com/home-assistant/core/pull/69371 updated the fsapi dependencies for this integration.
Thank you for tagging me in the issue. When I have time later today I will try to release a fix for the afsapi library: it seems that your radios release less attributes than the one I tested against.
Let me know if I can help with testing some api calls against my radio.
I took a first look yesterday and in my case it says, that modtype
is missing, but my test api-calls had that argument on in the resulting xml.
Not solved. Now I got this:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 514, in async_update_ha_state
await self.async_device_update()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 709, in async_device_update
raise exc
File "/usr/src/homeassistant/homeassistant/components/frontier_silicon/media_player.py", line 186, in async_update
self._attr_sound_mode = (await afsapi.get_eq_preset()).label
AttributeError: 'NoneType' object has no attribute 'label'
That one them you don't changed to optional. I think something else is wrong. Maybe we can really help with some test API-calls againt our radios and provide the resulting XMLs.
Please let us know which URL we should test.
I'll try to release a fix tomorrow for that issue that was already reported in #74949 . You're welcome to also contribute the URL's that I posted there to make sure that I cover all frontier_silicon versions
OK. I'll provide my result in that issue. Thanks.
Posted this in the incorrect issue; https://github.com/home-assistant/core/issues/74949#issuecomment-1186222443 Denver IR110 frontier_silicon still not working correctly after updating to 2022.7.5.
Device only exposes Volume controls, but nothing else.
Same issue as others, is a fix planned?
Logger: homeassistant.components.media_player Source: components/frontier_silicon/media_player.py:157 Integration: Media player (documentation, issues) First occurred: 22:47:14 (1 occurrences) Last logged: 22:47:14
frontier_silicon: Error on device update! Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 446, in _async_add_entity await entity.async_device_update(warning=False) File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 702, in async_device_update await task File "/usr/src/homeassistant/homeassistant/components/frontier_silicon/media_player.py", line 157, in async_update mode.label: mode.key for mode in await afsapi.get_modes() File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 577, in get_modes self.__modes = [ File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 578, in PlayerMode(key=k, v) # type: ignore TypeError: PlayerMode.init**() missing 2 required positional arguments: 'streamable' and 'modetype'
Since the afsapi 0.2.5 update: solved for me. Much thanks.
The problem
media player integration stopped working for frontier_silicon. worked fine until 2022.06
the log error message: `Logger: homeassistant.components.media_player Source: components/frontier_silicon/media_player.py:157 Integration: Media player (documentation, issues) First occurred: 12:04:41 (1 occurrences) Last logged: 12:04:41 frontier_silicon: Error on device update!
Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 446, in _async_add_entity await entity.async_device_update(warning=False) File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 702, in async_device_update await task File "/usr/src/homeassistant/homeassistant/components/frontier_silicon/media_player.py", line 157, in async_update mode.label: mode.key for mode in await afsapi.get_modes() File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 577, in get_modes self.modes = [ File "/usr/local/lib/python3.10/site-packages/afsapi/api.py", line 578, in
PlayerMode(key=k, **v) # type: ignore
TypeError: PlayerMode. init__() missing 1 required positional argument: 'modetype'`
the config.yaml setting `media_player:
What version of Home Assistant Core has the issue?
2022.07
What was the last working version of Home Assistant Core?
2022.06
What type of installation are you running?
Home Assistant Container
Integration causing the issue
silicon_frontier
Link to integration documentation on our website
No response
Diagnostics information
not available
Example YAML snippet
Anything in the logs that might be useful for us?
Additional information
No response