My entire house is in-wall GE Z-Wave light switches and half of the outlets - to include fan controls.
Occasionally, I have noticed after an upgrade or reboot, some of my existing switches (seems to be the same four or five) create an extra entity. The entity is always a “switch” - but it is non-functional.
This extra entity causes no problems except Spook reports it and Apple HomeKit picks it up and reports it as non-functional.
I login, delete it (as the normal functional switch is fine)
Only to have it occasionally return - randomly
I have switches where I have done that and I also see both a light and a switch. But, it shows up as hidden and both work, which is different from the image you posted.
Now I’m curious. I assume the only way HA might determine a switch is a “light” is maybe during the interview process. There’s no binary “light” command class from my basic understanding – just the SwitchBinary (37) command class.
Again, I don’t think this is your issue. It’s just that in your image you have both a switch and a light entity which is what the “Switch as X” integration does. But in your case is seems the switch is disabled, which “Switch as X” doesn’t do – it just marks it as hidden.
If you look at config/.storage/core.entity_registry do the two entites have the same created time?
I just now used “Switch as X” to change a switch to a light: