From 9757e3a3a2012482acb31744a194c4c727156315 Mon Sep 17 00:00:00 2001 From: Megamannen Date: Thu, 28 Jan 2021 13:25:10 +0100 Subject: [PATCH] Wrong type on birth_message and will_message (#16335) Felt wrong since the variable is named birth_message not birth_message*s* Tried it and it doesn't work, throws error This config ``` mqtt: birth_message: - topic: 'hass/status' payload: 'online' - topic: 'homeassistant/status' payload: 'online' will_message: - topic: 'hass/status' payload: 'offline' - topic: 'homeassistant/status' payload: 'offline' ``` Gave this error: ``` Logger: homeassistant.components.hassio Source: components/hassio/__init__.py:420 Integration: Hass.io (documentation, issues) First occurred: 9:44:55 AM (2 occurrences) Last logged: 9:48:29 AM Invalid config for [mqtt]: expected a dictionary for dictionary value @ data['mqtt']['birth_message']. Got [OrderedDict([('topic', 'hass/status'), ('payload', 'maaan')]), OrderedDict([('topic', 'homeassistant/status'), ('payload', 'maaan-boy')])] expected a dictionary for dictionary value @ data['mqtt']['will_message']. Got [OrderedDict([('topic', 'hass/status'), ('payload', 'womaaan')]), OrderedDict([('topic', 'homeassistant/status'), ('payload', 'womaaan-girl')])]. (See /config/configuration.yaml, line 6). Invalid config for [mqtt]: expected a dictionary for dictionary value @ data['mqtt']['birth_message']. Got [OrderedDict([('topic', 'hass/status'), ('payload', 'online')]), OrderedDict([('topic', 'homeassistant/status'), ('payload', 'online')])] expected a dictionary for dictionary value @ data['mqtt']['will_message']. Got [OrderedDict([('topic', 'hass/status'), ('payload', 'offline')]), OrderedDict([('topic', 'homeassistant/status'), ('payload', 'offline')])]. (See /config/configuration.yaml, line 6). ``` --- source/_docs/mqtt/birth_will.markdown | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/_docs/mqtt/birth_will.markdown b/source/_docs/mqtt/birth_will.markdown index eec087abdca..5a8ed349743 100644 --- a/source/_docs/mqtt/birth_will.markdown +++ b/source/_docs/mqtt/birth_will.markdown @@ -25,7 +25,7 @@ mqtt: birth_message: description: Birth Message. Set to the empty dict, `{}`, to disable publishing a birth message. required: false - type: list + type: map keys: topic: description: The MQTT topic to publish the message. @@ -50,7 +50,7 @@ birth_message: will_message: description: Will Message. Set to the empty dict, `{}`, to disable publishing a will message. required: false - type: list + type: map keys: topic: description: The MQTT topic to publish the message.