Automation triggers even if disabled or deleted

I have set up an automation to turn on a smart power outlet when a light is turned off. Both are IKEA Tradfri.

But it wasn’t working very well - it got triggered by any change in state of that light, not just by turning it off as it was supposed to. So I gave up on it and created another automation that works better for my purpose.

But now I cannot get rid of the light-triggered automation! First I disabled it, nothing, still triggering whatever happens with that light. Then I deleted it to no avail, same thing, the damn automation triggers when anything happens to its trigger. But it’s deleted, how is that possible?
I checked developer tools, it does NOT show there.

Is this a bug or am I doing something wrong? Is there some particular procedure to get rid of an automation? How can I get rid of it now?

PS - this is persisting after reboot.

Did you also checked the automation.yaml in the config folder, just make sure there is nothing what you don’t expect…

I just realized what’s going on.
It’s not HA’s fault. These IKEA thingies have this “feature” - you cannot add them to the system without associating them with an IKEA controller. In this particular case, my power plug was associated with the same controller that controls the living room lights… so obviously, controlling the lights WITH THE CONTROLLER does the same thing to the power plug, whereas controlling the lights in any other way, does not.

I want to slap my self now…

…the IKEA tradfri range doesn’t seem such a great deal anymore… you MUST buy a controller for every device, even if you never use it after onboarding. Maybe I should assign one controller just for these… thinking out loud here, sorry, it’s late…