i hade a question about action.
this is my yaml code:
`action:
service: cover.open_cover
entity_id: >
{% for device in states -%}
{%- if Cover.lower() in device.entity_id -%}
{{ device.entity_id }}
{%- endif -%}
{%- endfor -%}`
this raises an error.
does anyone how to handle this.
OpenCoverIntent:
action:
- service: cover.open_cover
data_template:
entity_id: >
{% for device in states -%}
{%- if Cover.lower() in device.entity_id -%}
{{ device.entity_id }},
{%- endif -%}
{%- endfor -%}
i got his error:
ERROR (MainThread) [homeassistant.core] Invalid service data for cover.open_cover: Entity ID is an invalid entity id for dictionary value @ data[âentity_idâ]. Got âcover.bad_gross_io0203519077805265811,cover.bad_klein_io0203519077809104199,â
Seems like I saw someone run into this in another thread. Generating a list of entity_idâs wasnât working. Itâs like HA sees it as one string instead of a list. Not sure how to create a list in Jinja (templates), but casting as a list might take care of that.