Skip to content

Unexpected error fetching spotify Devices data 2024.11.0b2  #129704

@Drongo76

Description

@Drongo76

The problem

Since updating to 2024.11.0b2, the problem with Spotify still persists. Please refer to the error log for details.

Unexpected error fetching qeyvqkob Devices data
Traceback (most recent call last):
File "", line 24, in mashumaro_from_dict_json
File "/usr/local/lib/python3.12/enum.py", line 757, in call
return cls.new(cls, value)
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/enum.py", line 1171, in new
raise ve_exc
ValueError: 'TV' is not a valid DeviceType

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "", line 9, in mashumaro_from_json
File "", line 26, in mashumaro_from_dict_json
mashumaro.exceptions.InvalidFieldValue: Field "device_type" of type DeviceType in Device has invalid value 'TV'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 382, in _async_refresh
self.data = await self._async_update_data()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 279, in _async_update_data
return await self.update_method()
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/spotify/init.py", line 72, in _update_devices
return await spotify.get_devices()
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/spotifyaio/spotify.py", line 324, in get_devices
return Devices.from_json(response).devices
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 11, in mashumaro_from_json
mashumaro.exceptions.InvalidFieldValue: Field "devices" of type list[Device] in Devices has invalid value [{'id': '54b21b73084ac7eb41bcbadc049349111fdb5668', 'is_active': False, 'is_private_session': False, 'is_restricted': False, 'name': "Jürgen's Fire TV Cube", 'supports_volume': False, 'type': 'TV', 'volume_percent': 60}, {'id': '021e1a40aa9b291738e4bbd5f213b9b67af855c1', 'is_active': False, 'is_private_session': False, 'is_restricted': False, 'name': 'Web Player (Chrome)', 'supports_volume': True, 'type': 'Computer', 'volume_percent': 100}, {'id': 'b8d009fd-2f37-44a4-9618-16d2b48a75e9_amzn_1', 'is_active': False, 'is_private_session': False, 'is_restricted': False, 'name': 'Jürgens Echo Show', 'supports_volume': False, 'type': 'Speaker', 'volume_percent': 25}, {'id': 'b8d009fd-2f37-44a4-9618-16d2b48a75e9_amzn_2', 'is_active': False, 'is_private_session': False, 'is_restricted': False, 'name': 'Überall', 'supports_volume': False, 'type': 'Speaker', 'volume_percent': 25}, {'id': '04f4d3cd-ac9f-4226-9b27-28001c2fca09_amzn_1', 'is_active': False, 'is_private_session': False, 'is_restricted': False, 'name': 'Jürgens Echo', 'supports_volume': True, 'type': 'Speaker', 'volume_percent': 49}]

What version of Home Assistant Core has the issue?

2024.11.0b2

What was the last working version of Home Assistant Core?

2024.10

What type of installation are you running?

Home Assistant OS

Integration causing the issue

spotify

Link to integration documentation on our website

No response

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

Metadata

Metadata

Type

No type

Priority

None yet

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions