Problem with groups

Dears
just getting started with Home Assistant. I have issues while creating a group in my configuration file. This is what I have:

group:
  - Main_Bathroom_Lights:
    name: Bath
    entities: 
        - switch.LUCE_BAGNO
        - switch.LUCE_TOILETTE
        - switch.LUCE_CENTRALE

2020-12-26 21:24:47 ERROR (MainThread) [homeassistant.components.hassio] Invalid config for [group]: expected a dictionary for dictionary value @ data[‘group’]. Got [OrderedDict([(‘Main_Bathroom_Lights’, None), (‘name’, ‘Bath Room Lights’), (‘entities’, [‘switch.BATH’, ‘switch.TOILETTE’, ‘switch.CEILING’])])]. (See /config/configuration.yaml, line 58).
searching in the old post, seems to me I’m doing wrong things with the indent but I wasn’t able to understand what. Anybody helfpul?

thanks in advance

If you do not format your code properly in this forum (readhow to ask a question). It is hard to help…

group:
  - Main_Bathroom_Lights:
    name: Bath
    entities: 
        - switch.BATH
        - switch.TOILETTE
        - switch.CEILING

I hope this helps

Think too much spaces before the entities…

Make sure there are no “tabs” but only spaces.

And not sure but take out the CAPITALS as well

Yes, get rid of the capitals. If you want a nicer looking name you could always add friendly_name: “Name with capitals and spaces”

guys, it helped.

there was an additional fail:

group:
  main_bathroom_lights:
    name: bath
    entities: 
       - ...
       - ...

thanks a lot for your support. I try now to automatize it

That name can be capitalised to ‘Bath’ if you want.

thanks for the info. In the end does not matter. I usually avoid using capital letters, not sure why this time I used them…