gysmo38 / mitsubishi2MQTT

Mitsubishi to MQTT with ESP8266 module
GNU Lesser General Public License v2.1
371 stars 132 forks source link

Config allows illegal characters to be used in “Friendly name” #256

Open Frankster-NL opened 5 months ago

Frankster-NL commented 5 months ago

Took me a while to figure out what was going wrong, but the config screen allows the use of spaces in “Friendly name” which produces the following error in Homeassistant MQTT:

Logger: homeassistant.components.mqtt.discovery
Source: components/mqtt/discovery.py:155
Integration: MQTT (documentation, issues)
First occurred: 12:25:10 (3 occurrences)
Last logged: 12:32:41

Received message on illegal discovery topic 'homeassistant/climate/airco woonkamer/config'. The topic contains not allowed characters. For more information see https://www.home-assistant.io/integrations/mqtt/#discovery-topic

It would be a great enhancement if spaces in topics would produce a warning when entering them.