I assume you are using a text editor to make the suggested changes. What steps do you perform immediately after modifying the automation and saving the changes?
For example, do you run Check Configuration and, if it passes, execute Reload Automations?
I pasted the example, containing the incorrectly indented default, into the Automation Editor and, after clicking the Save button, it immediately flagged the error.
I changed it back to 4 spaces (default). No errors on Check configuration but still get a notification with the following error:
Invalid config for [automation]: [to] is an invalid option for [automation]. Check: automation->action->0->choose->0->conditions->1->to. (See /config/configuration.yaml, line 18).
Invalid config for [automation]: [sequence] is an invalid option for [automation]. Check: automation->action->0->choose->0->conditions->1->sequence. (See /config/configuration.yaml, line 18).
I have checked my entire automation.yaml file and there is no condition that has a “to”, only state triggers. I’m unsure where this comes from. I have rebooted but it still comes up.
tells us that the offending option is located in an automation’s action in the first conditions section of the first choose statement (and it’s the second condition within conditions).
That’s clearly not in the example I posted so it’s somewhere else.
Use Visual Studio Code to find all choose statements in all of your automation files (I assume you have more than one otherwise your manually created automations are combined with those composed using the Automation Editor).
I already done that and found no “to” anywhere after any condition. I only create automation manually so no Automation editor stuff in my yaml file. The first example I posted had a “to” in the condition but I changed that to state later on. on my first reply.
Thank you. I moved the sequence back 2 spaces and now the error is done.
Thank a million for the help. Where can I read more about the indentation rules for yaml? If you have any good resources I would appreciate it very much,
Please consider marking my post above with the Solution tag. It will automatically place a check-mark next to the topic’s title which signals to other users that this topic is resolved. This helps other users find answers to similar questions. For more information, refer to guideline 21 in the FAQ.