From c6dae1b1d24ff8c3a8631e11fc1aeb62fca2797f Mon Sep 17 00:00:00 2001 From: jonwaland <33437424+jonwaland@users.noreply.github.com> Date: Sun, 19 Apr 2020 21:25:43 +1000 Subject: [PATCH] Update yaml.markdown (#13049) * Update yaml.markdown Added warning about booleans * Update source/_docs/configuration/yaml.markdown Co-Authored-By: Franck Nijhof * :pencil2: Tweak Co-authored-by: Franck Nijhof --- source/_docs/configuration/yaml.markdown | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/source/_docs/configuration/yaml.markdown b/source/_docs/configuration/yaml.markdown index 4fd7bcf2a70..fa79cd97054 100644 --- a/source/_docs/configuration/yaml.markdown +++ b/source/_docs/configuration/yaml.markdown @@ -111,3 +111,13 @@ This means that you've mistakenly entered a tab character, instead of spaces. Home Assistant is case sensitive, a state of `'on'` is not the same as `'On'` or `'ON'`. Similarly an entity of `group.Doors` is not the same as `group.doors`. If you're having trouble, check the case that Home Assistant is reporting in the dev-state menu, under *Developer tools*. + +### Booleans + +YAML treats `Y`, `true`, `Yes`, `ON` all as `true` and `n`, `FALSE`, `No`, `off` as `false`. This means that if you want to set the state of an entity to `on` you *must* quote it as `'on'` otherwise it will be translated as setting the state to true. The same applies to `off`. + +Not quoting the value may generate an error such as: + +```txt +not a valid value for dictionary value @ data +```