I want to turn off all lights in the front and backyard.
One lamp excluded, a security lamp that turns on movement.
so i made a script to turn off all lamps in the two areas.
I tagged all lights with tag lampen except the security lamp.
And i used the tag in the script.
But still the security light goes off!
i expected an or within areas and label_id, but an and between label_id and area_id
I’m not even sure I understand what “an or within areas and label_id” actually means. Should only one Area’s lights be turned off if multiple are listed?
"Turn the kitchen lights OR the bathroom lights off... it doesn't really matter which one"
Targets follow simple AND logic. If you don’t want every light entity in an Area affected, don’t target that Area with a light action.
Since you have labelled everything but the security light, you should only need to target the Label:
… unless there are also lights with that Label but in other Areas that shouldn’t turn off, then you would need to use templating to get the intersection of the lists.