So, if you are like me and having a big list of entities it’s very likely missd a few while creating groups and views.
After searching a bit in Home Assistant Community forums i have found this amazing script that takes all the UnGroupd emtities and places that in a view.
In this Article i’ll show you how to use this python script.
The first thing we shuold do is add a Directory named python_scrips right under Home-Assistant Config dir:
Now, create a files calld populate_catchall_group.py and add the following content into the file and save it:
Save the file and close i2
Now, in Home-Assistant configuration file “configuration.yaml” add the next line to tell home assistant load the script:
* Using “!include_dir_merge_list” will cause Home Assistant to load all the files in the given path”.
In this stage we will create an empty group/view so the script will attach the UnGroupd entities to it. to this add the next lines into groups.yaml:
and save it.
In this stage we will add an Automation to tell Home-Assistant run the script at startup. to do this add the next lines into “automations.yaml”:
Save the file and restrt Home Assistant
Alongside with the automation we can also call the script manualy from Home-Assistant frontend using “Call Service” in the developer panel.
Search: “python_script.populate_catchall_group” and press the “Call Service” button: