home-assistant-cli icon indicating copy to clipboard operation
home-assistant-cli copied to clipboard

group and "light switch" entities missing from `entity list`

Open shaver opened this issue 5 years ago • 3 comments

A couple of kinds of entities don't show up in entity list:

  • groups
  • light switch entities, as described here: https://www.home-assistant.io/integrations/light.switch/

I've been using hass-cli to do batch configuration of stuff, and this confused me for a fair while!

shaver avatar May 14 '20 22:05 shaver

Is this possibly because those entities don't have devices?

shaver avatar May 15 '20 15:05 shaver

I think not having a unique ID is the problem with entities not showing up. Add a unique_id to the entity and it will appear. Many of my devices are MQTT based and I created them manually a long time ago without the new 'discovery' ability or adding the unique_id. As soon as I add this attribute, the entity appears here in hass-cli and I can now assign it an 'Area'. Still can not see entities in Areas views in HA, 2020.12.1.

deepcoder avatar Jan 01 '21 21:01 deepcoder

Sorry to comment on an old issue, but this is also happening for me with some hygrostats. They don't show up with hass-cli entity list | grep hygrostat, but I do see them with the state command:

# hass-cli state list | grep hygrostat
binary_sensor.second_floor_bathroom_hygrostat                                            Second Floor Bathroom Hygrostat                                              off                                         2022-09-14T02:07:01.755933+00:00
binary_sensor.ensuite_bathroom_hygrostat                                                 Ensuite Bathroom Hygrostat                                                   off                                         2022-09-14T02:07:01.756262+00:00
binary_sensor.laundry_closet_hygrostat                                                   Laundry Closet Hygrostat                                                     off                                         2022-09-14T02:07:01.756560+00:00

I think a good workaround is to use the state list command instead of entity list. It has more information and isn't missing any entities.

ndbroadbent avatar Sep 14 '22 02:09 ndbroadbent