If you want a comma-delimited list of the group’s members, then you don’t need to iterate through expand’s result (i.e. don’t use a for-loop with expand).
He’s trying this with a light group, which doesn’t have the entity_id attribute. It’s a shot in the dark if a light group works with expand and judging by his last post, I would say it doesn’t.
Well, the smaller code for filtering groups will come handy since it seems I’ll have to use groups anyway, so thanks for that @123 . Which brings me to another question, how can I add brightness and (for some groups) temperature controls to a group in the UI?
you’d have to get inventive with automations and input_numbers. Or use that light group. And there is a universal climate component too. But you still won’t be able to break out he entity_id’s from those devices because they emulate a physical device, which doesn’t have those attributes.