#and this is the stuffi n the secret.yaml

1 messages · Page 1 of 1 (latest)

limpid whale
#

Did you check the log?

hybrid orchidBOT
#

If you're having problems with your updates to your configuration:

smoky ginkgo
#

yes a checkeed and at first saw nothing then expaned them and complained about having sensor defined multiple times

#

so now i'm trying to figure out the correct syntax

limpid whale
#
# Example configuration.yaml entry
command_line:
  - sensor:
      command: SENSOR_COMMAND
  - sensor:
      command: SENSOR_COMMAND_2
#

Even shows you in the docs 😉

hybrid orchidBOT
smoky ginkgo
#

is what i did but is giving me warning about it

#
2024-07-11 16:09:11.220 WARNING (SyncWorker_0) [homeassistant.util.yaml.loader] YAML file /config/configuration.yaml contains duplicate key "sensor". Check lines 30 and 35
2024-07-11 16:09:11.220 WARNING (SyncWorker_0) [homeassistant.util.yaml.loader] YAML file /config/configuration.yaml contains duplicate key "sensor". Check lines 35 and 40```
hybrid orchidBOT
#

Please use a code share site to share code or logs, for example:

Please don't use Pastebin, since it can randomly add spaces to the main view. Please also don't share text as images since it makes it harder for people to help you. Remember that others may have colour blindness, impaired vision, etc.

limpid whale
#

Share the YAML so we don't need to guess

smoky ginkgo
#
  sensor:
    name: macmini_system_hd
    scan_interval: 600
    command: !secret macmini_system_hd
  sensor:
    name: macmini_cpu
    scan_interval: 600
    command: !secret macmini_cpu
  sensor:
    name: macmini_mem
    scan_interval: 600
    command: !secret macmini_mem
  sensor:
    name: macmini_uptime
    scan_interval: 600
    command: !secret macmini_uptime```
#

i posted in the channel

#

could be the -?

hybrid orchidBOT
#

To format your text as code, enter three backticks on the first line, press Enter for a new line, paste your code, press Enter again for another new line, and lastly three more backticks.
```yaml
example: here
```
Don't forget you can edit your post rather than repeatedly posting the same thing.

limpid whale
#

Yes, YAML is picky. If you don't match the docs then you're writing gibberish

smoky ginkgo
#

now is even worse

Invalid config for 'command_line' at configuration.yaml, line 26: 'name' is an invalid option for 'command_line', check: command_line->0->name, please check the docs at https://www.home-assistant.io/integrations/command_line
Invalid config for 'command_line' at configuration.yaml, line 27: 'scan_interval' is an invalid option for 'command_line', check: command_line->0->scan_interval, please check the docs at https://www.home-assistant.io/integrations/command_line
Invalid config for 'command_line' at secrets.yaml, line 9: 'command' is an invalid option for 'command_line', check: command_line->0->command, please check the docs at https://www.home-assistant.io/integrations/command_line
2024-07-11 16:49:39.056 ERROR (MainThread) [homeassistant.setup] Setup failed for 'command_line': Invalid config.```
#

is like ignoring the sensor if i add the -

limpid whale
#

Share what you've done now

smoky ginkgo
#

oh wait i forgot to indent after adding -

limpid whale
#

Yes, YAML is picky. If you don't match the docs then you're writing gibberish

smoky ginkgo
#

great now is working

#

thanks a lot