core: Error in Sonos Integration, battery
The problem
No sensors for Sonos Move, comparing to new release. Neither battery nor charging. I’m using Sonos S1, if this is related to the error and malfunction below.
https://www.home-assistant.io/integrations/sonos/#battery-support
What is version of Home Assistant Core has the issue?
core-2021.5.0
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant Container
Integration causing the issue
Sonos
Link to integration documentation on our website
https://www.home-assistant.io/integrations/sonos/#battery-support
Example YAML snippet
No response
Anything in the logs that might be useful for us?
2021-05-06 15:48:39 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/sonos/speaker.py", line 261, in async_update_device_properties
await self.async_update_battery_info(battery_dict)
File "/usr/src/homeassistant/homeassistant/components/sonos/speaker.py", line 270, in async_update_battery_info
if is_charging == self.charging:
File "/usr/src/homeassistant/homeassistant/components/sonos/speaker.py", line 289, in charging
return self.power_source != "BATTERY"
File "/usr/src/homeassistant/homeassistant/components/sonos/speaker.py", line 284, in power_source
return self.battery_info["PowerSource"]
TypeError: 'NoneType' object is not subscriptable
Additional information
No response
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 35 (34 by maintainers)
Gotcha! Didn’t see .4 before. But directly tried after your post:
No errors anymore during boot and actions.
👍
More than great!
Yes, it is as you posted:
Sorry, didn’t see this before. Was sure that it was completely empty last time.