Can't delete legacy yaml group entity to move to helper group - solved

A quick FYI in case it helps anyone.

I’ve been using Home Assistant for years. I had grouped many lights together via yaml - as was the way, way back when eg in configuration.yaml I would have something like:

  - platform: group
    name: LED light strips
    entities:
      - light.fireplace
      - light.kitchenbench

Now I was wanting to expose the groups to voice assistant but couldn’t because I hadn’t bothered to give each group a unique ID when I made them back in the dark ages. I added in a unique ID in the config, but it made no change. Right. So lazy as I am it was clearly time to bite the bullet and move over to recreating the groups under the helper option (ie settings/devices/helper).

Went in and found I could not remove the old group via the gui. Fair enough - removed it from configuration.yaml and rebooted. Old group still there. No option to delete it via the gui. Rebooted a few more times, no change. Created a new group with a different name and that worked just fine, but old one still there. Rebooted a few more times just for the heck of it. No change. I’d go into the group integration, and could see that there were more than a dozen entities, but it only showed the four that I had created via the template - the ones created via yaml were associated with the group integration but could not be accessed. Could find them under entities, but the checkbox to enable the entity to be deleted was greyed out.

Had a search through the forums, and found a few people complaining about similar things, and needing to edit hidden files and do all sorts of other fairly sketchy things. I didn’t want to go down that rabbit hole, so decided that I was probably going to have to make a stack of new groups with different names, and that thought made me sad. So I decided to take the dog for a walk.

When I got back, I found that had fixed it. Yep, I just needed to be patient. I assume that there was some background process I needed to let run to clean up the old entities.

The bonus I found was that after deleting the old groups, and creating the new groups using the same names, my automations still worked.

You can also continue to use YAML if you prefer:

#configuration.yaml
light:
  - platform: group
    unique_id: foobar42
    name: LED light strips
    entities:
      - light.fireplace
      - light.kitchenbench

After deleting the group YAML restart Home Asstant. Then go to Settings → Devices & Services → Entities, click on your entity, click the cog icon top right, click delete at the bottom. Alternatively you can use the table multi-select if you have more than one to delete and then find the delete action in the table three dots overflow menu icon to the top right.

Yep - my issue was I was far too impatient. I did add in a unique id to one of my existing yaml entries, but it didn’t seem to make a difference. As with nothing happening after deleting them from the yaml, I suspect that I just needed to wait! :laughing: