Moon sensor line makes configuration.yaml editor have error (!)

Hi all. I think I am going mad. All I want to do is add the following to my configuration.yaml file using the editor.

Example configuration.yaml entry

sensor:

  • platform: moon

However when I do this using the file editor it gives me the warning red (!) in the rh corner.

what am I doing wrong?

Using HassOS 4.12 and latest updates.

Take out the second sensor: line

not sure i understand your suggestion.

In your file you have 2 lines that say sensor:, Take the second one out. You are only allowed one.

oh i see. thanks. that worked. i was being daft. cheers…j

See this part of the docs for why you needed to do that.