Of course it’s possible that a switch is controlling some other sort of load, but it’s much much more likely they’re controlling a light. I have 50 switches in my house and only one controls a bath fan. Why not reverse the functionality and make a switch a light unless you list somewhere for it to be treated as only a switch?
Edit: Or why with the zwave integration can’t I decide switches are lights instead of wrapping the switch with light: and having two entities. It just feels like a hack…
A standard on/off light is technically a switch. You can already assign a switch to be a light while still only having the on/off functionality. A light which is not just on/off such as RGB or a Dimmer etc is not a switch because it is more than just on/off. That make sense?
I disagree too. My Tasmota switches (Sonoff/Shelly 1) are indeed switches, but using setoption30 they are recognized as lights in HA. The other switches I have (plenty of them) are mostly power monitoring plugs, none of which control a light.
Dimmers are also a form of switch just with added functionality. I get the point but it would be nice if there was some way to change the type without ending up with two entities. That greatly complicates things that act on all entities of a certain type. Like my All Off at Night setup…those devices get two messages or I have to manually include the switches that aren’t wrapped as lights. If I don’t wrap them then things that act on all lights is more difficult.
I just think it sows confusion for new users and complicates the setup overall.
it’s much much more likely they’re controlling a light IN YOUR HOUSE. There, I fixed it for you.
I think a switch is a component that allows you to control its binary state. I think the majority of the switches in my setup not only are not lights, but they are not even physical switches (they set mqtt topics, send specific infrared commands, call webhooks, etc etc)
Treating all switches as lights is obviously bad approach.
IMO it’s integration which is responsible for entity domain declartion. And this is the place where user should be able to set it up to match his needs.
For example, having mqtt devices you can decide to use mqtt switch or mqtt light.
Other integrations should give option to assign entity to required group.
OP didnt’t mention what switch integration he is using btw.
But I’d have to potentially list 60+ switches/lights. And by populating a list with what is on I still end up sending two commands to the light-wrapped switches. The fact that you can have a mixed group doesn’t help the issue at all.
Yes, but also the key thing that’s being overlooked here is that:
Switches are pure on/off entities
Lights have a brightness and/or colour control too
That’s the functional difference between lights and switches. Sure, for a human the differences are more subtle, but this is a computer program, not a human