Automation not being listed with yaml error in it

I have created an automation with a typo in the action part.
I wanted to delay the action for 2 hours, but failed to indent it properly.
The point is that the automation doesn’t get listed on the view, and no error is thrown.
Configuration check also doesn’t find any errors.
HASS restarts without problems and the error is also not logged to the log file.

I think this should not be the proper behaviour of the app. HASS should fail if YAML is not correct or if it fails to load some part of it.

Has somebody had a similar issue?
Should I report it in Github or somewhere else?

The action part of the automation was like this:

action:
  - service: switch.turn_on
    entity_id: switch.fibaro_system_fgs222_double_relay_switch_2x15kw_switch_3_0
  - delay:
    hours: 2

I think the problem is that the configuration checker checks to see if the code is valid yaml, which the above is. It does not check whether the valid yaml will actually have the desired effect in home assistant, which the above won’t.

Valid yaml just means that the indentations are all uniform and fit a certain pattern, the fact that hours needs to be indented a further two spaces for home assistant to see it is a sub-option of delay, rather than a different option entirely, doesn’t stop the yaml being valid because for all the parser knows hours could be a separate option.

I don’t know if there’s any actual way around this.

(hope my explanation made sense!)

I do understand the part about it not being an actual YAML error.
What I do not get is why the automation was not listed at all in the HASS view.

It is, as if HASS discarded it but didn’t raise any error, nor log it anywhere.

Yeah, I have no idea why that is.

What errorlevel do you have set for logger? Maybe it filtered it.