Hi all,
I’m trying to configure Home Assistant to interact with my Plex Media Server.
First, I followed this procedure and I had no issues: I rebooted HA and all seems ok with no errors in the log.
Then, as I first test, I tried to play a song in one of my GoogleMini speaker, so I created a trigger with this action:
action:
service: media_player.play_media
data:
entity_id: media_player.GoogleMiniSpeaker1
media_content_id: { \“library_name\” : \“Music\”, \“artist_name\” : \“Muse\”, \“album_name\” : \“Black Holes and Revelations\”, \“track_name\” : \“Starlight\”, \“shuffle\”: \“0\” }
media_content_type: MUSIC
But when I activate the trigger nothing happened, and I have this error in the log:
Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/service.py", line 277, in _handle_service_platform_call
await getattr(entity, func)(**data)
File "/usr/local/lib/python3.6/site-packages/homeassistant/components/switch/template.py", line 154, in async_turn_on
await self._on_script.async_run(context=self._context)
File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/script.py", line 130, in async_run
await self._handle_action(action, variables, context)
File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/script.py", line 172, in _handle_action
action, variables, context)
File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/script.py", line 261, in _async_call_service
context=context
File "/usr/local/lib/python3.6/site-packages/homeassistant/helpers/service.py", line 81, in async_call_from_config
domain, service_name, service_data, blocking=blocking, context=context)
File "/usr/local/lib/python3.6/site-packages/homeassistant/core.py", line 1101, in async_call
processed_data = handler.schema(service_data)
File "/usr/local/lib/python3.6/site-packages/voluptuous/schema_builder.py", line 267, in __call__
return self._compiled([], data)
File "/usr/local/lib/python3.6/site-packages/voluptuous/schema_builder.py", line 589, in validate_dict
return base_validate(path, iteritems(data), out)
File "/usr/local/lib/python3.6/site-packages/voluptuous/schema_builder.py", line 427, in validate_mapping
raise er.MultipleInvalid(errors)
voluptuous.error.MultipleInvalid: value should be a string for dictionary value @ data['media_content_id']
What’s wrong?
Thank you in advance
Riky