Hi, I copied the following code from the examples page and pasted it in my automations.yaml file, but get constant errors when checking config. Im not sure what I need to do, some guidance would be greatly appreciated. (hope i pasted the code correctly)
Configuration invalid
Error loading /config/configuration.yaml: while parsing a flow sequence in “/config/automations.yaml”, line 1, column 1 expected ‘,’ or ‘]’, but got ‘’ in “/config/automations.yaml”, line 2, column 5
Make sure this is under the automation: section of your configuration.yaml file or if you are using automation: !include automations.yaml then put it in your automations.yaml file.
Hi Tom, thanks for the help, now i get an error for the configuration.yaml file.
Configuration invalid
Invalid config for [automation]: not a valid value for dictionary value @ data[‘action’][0][‘entity_id’]. Got None. (See /config/configuration.yaml, line 21). Please check the docs at https://home-assistant.io/components/automation/ Invalid config for [automation]: not a valid value for dictionary value @ data[‘action’][0][‘entity_id’]. Got None. (See /config/configuration.yaml, line 21). Please check the docs at https://home-assistant.io/components/automation/
# Configure a default setup of Home Assistant (frontend, api, etc)
default_config:
homeassistant:
latitude: -33.800837
longitude: 18.477636
elevation: 5
unit_system: metric
time_zone: Africa/johannesburg
name: Home
# Uncomment this if you are using SSL/TLS, running in Docker container, etc.
# http:
# base_url: example.duckdns.org:8123
# Text to speech
tts:
- platform: google_translate
group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
switch:
- platform: mqtt
name: "sonoff"
state_topic: "stat/sonoff1/POWER"
command_topic: "cmnd/sonoff1/power"
qos: 1
payload_on: "ON"
payload_off: "OFF"
retain: true