ThermIQ / thermiq_mqtt-ha

Home Assistant integration of ThermIQ-MQTT, providing control and logging of Thermia heatpumps
https://thermiq.net
MIT License
22 stars 19 forks source link

create_input_select overwrites all the input_select's #33

Closed andressade closed 1 year ago

andressade commented 2 years ago

Describe the bug

After upgrade of thermiq_mqtt all my input_select's defined in configurations.yaml where lost

In example:

input_select:
    komfovent_mode:
        name: Ventilaatori tööreziim
        icon: mdi:air-conditioner
        options:
            - A
            - B
            - C
            - D

Will show a error on log:

2022-04-12 23:39:26 ERROR (MainThread) [custom_components.pyscript.file.vent.komfovent_sensor_tooreziim] Exception in <file.vent.komfovent_sensor_tooreziim> line 30:
        curr_mode = input_select.komfovent_mode
                    ^
NameError: name 'input_select.komfovent_mode' is not defined

And shows yellow warning in UI about missing entity

After commenting :

# await create_input_select(
#                DOMAIN+"_" + key,
#               friendly_name,
#              input_options,
#               input_initial,
#               icon="mdi:power",
#           )

and defining thermiq_mqtt_main_mode manualy in configuration.yaml everything is working again

ThermIQ commented 1 year ago

This is most likely due to some other input_select not being properly/fully configured. See this post in HA forum