Automation not saved

I am new to HA. Wanted to add my first automation. Selected the Homematic switch and the Shelly receiver and pressed Add Automation. But automation not to be seen then under Automations.

Tried to look into automation.yaml with Editor, but there is no automation.yaml shown.

Tried several times. Interestingly when entering the automation I can go to … menu and select Edit in YAML and see the code. But as I said, the automation is not to be seen in UI and there seems to be no automation.yaml (in editor).

Thanks for advice!

Automations can’t be saved if there is errors in it or if it’s incomplete.
But post what you have done in yaml and we can have a look.