shaonianzhentan / node-red-contrib-ha-mqtt

在HomeAssistant中生成MQTT实体
https://github.com/shaonianzhentan/node-red-contrib-ha-mqtt
MIT License
39 stars 20 forks source link

Home Assistant Core Error #41

Closed grant-cpt closed 6 months ago

grant-cpt commented 6 months ago

Not entirely sure why, but I'm getting the below error:

Logger: homeassistant.components.mqtt.mixins
Source: components/mqtt/mixins.py:270
integration: MQTT ([documentation](https://www.home-assistant.io/integrations/mqtt), [issues](https://github.com/home-assistant/core/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+mqtt%22))
First occurred: 12:20:27 PM (2 occurrences)
Last logged: 12:23:11 PM

Error 'extra keys not allowed @ data['device']['device']' when processing MQTT discovery message topic: 'homeassistant/sensor/Solar_Watts/config', message: '{'name': 'Solar Watts', 'unique_id': 'ha-mqtt_sensor_Solar_Watts_', 'state_topic': 'ha-mqtt/sensor/Solar_Watts/state', 'json_attributes_topic': 'ha-mqtt/sensor/Solar_Watts/attr', 'device': {'configuration_url': 'https://github.com/shaonianzhentan/node-red-contrib-ha-mqtt', 'identifiers': 'ha-mqtt-Inverter Staging', 'manufacturer': 'shaonianzhentan', 'model': 'HA-MQTT', 'sw_version': '1.2.13', 'device': {'name': 'Axpert', 'manufacturer': 'Axpert', 'identifiers': ['Axpert 1'], 'serial_number': '92932005101505', 'model': 'ERS 5KW'}, 'name': 'Inverter Staging'}, 'unit_of_measurement': 'W', 'device_class': 'power', 'state_class': 'measurement', 'platform': 'mqtt'}'

Discovery "seems" to work fine, as the device is shown under MQTT and the test item: Solar Watts is present in Home Assistant

grant-cpt commented 6 months ago

I found the issue