binsentsu / am43-ctrl

Node Util for controlling an AM43 Blinds Drive Cover, either over MQTT or via a HTTP API
44 stars 25 forks source link

Deprecation warning from home assistant #27

Open provinzio opened 3 years ago

provinzio commented 3 years ago

This might be a quick fix in MQTTConnector.js, but I am not sure if we can just change value_template with position_topic.

Warning from Home Assistant:

Logger: homeassistant.components.mqtt.cover
Source: components/mqtt/cover.py:130
Integration: MQTT (documentation, issues)
First occurred: 07:45:23 (2 occurrences)
Last logged: 07:45:23
using 'value_template' for 'position_topic' is deprecated and will be removed from Home Assistant in version 2021.6, please replace it with 'position_template'
binsentsu commented 3 years ago

Looks like position_template must be added in the discovery configuration of MqttConnector. Value must be the same as current value in value_template. I assume value_template can be left for backwards compatibility purposes. If you're up to, you can try adding position_template in the coverConfig and give me feedback. My HA environment is a bit behind with updates at the moment... (https://www.home-assistant.io/integrations/cover.mqtt/)

provinzio commented 3 years ago

I am afraid that I won't be of any help here. I was barely able to do the setup. I have no idea how I can setup a dev environment or upgrade the module used by pm2.

binsentsu commented 3 years ago

No problem. I will check it this weekend.