ITADN

Allow new homeassistant device classes

#4626OpenTurgon37 创建于 2026-05-01
T
Turgon37commented
### Version Build/Run method: [x ] Docker Z-Wave JS UI version: **11.16.2** ### Describe the bug Hello, I'm using a stack with zwavejs, mqtt, homeassistant in Kubernetes. All working fine except some values of a zwave device not begin integrated into homeassistant. It's an energy sensor https://devices.zwave-js.io/?jumpTo=0x0086:0x0002:0x005f:0.0 When homeassistant discovery is produced into mqtt topic, the device_class of new energy entity is not valid 2026-04-30 23:52:04.721 ERROR (MainThread) [homeassistant.components.mqtt.entity] Error 'The unit of measurement `kVar` is not valid together with device class `power`' when processing MQTT discovery message topic: 'homeassistant/sensor/nodeID_14/electric_kvar_value_0/config', message: '{'value_template': '{{ value_json.value }}', 'unit_of_measurement': 'kVar', 'device_class': 'power', 'state_topic': 'zwavejs/nodeID_14/meter/endpoint_0/value/67330', 'availability': [{'payload_available': 'true', 'payload_not_available': 'false', 'topic': 'zwavejs/nodeID_14/status', 'value_template': "{{'true' if value_json.value else 'false'}}"}, {'topic': 'zwavejs/_CLIENTS/ZWAVE_GATEWAY-zwave-js-ui/status', 'value_template': "{{'online' if value_json.value else 'offline'}}"}, {'payload_available': 'true', 'payload_not_available': 'false', 'topic': 'zwavejs/driver/status'}], 'availability_mode': 'all', 'json_attributes_topic': 'zwavejs/nodeID_14/meter/endpoint_0/value/67330', 'device': {'identifiers': ['zwavejs2mqtt_0xe74752f9_node14'], 'manufacturer': 'AEON Labs', 'model': 'Home Energy Meter - Gen5 (ZW095)', 'sw_version': '1.35', 'name': 'nodeID_14'}, 'unique_id': 'zwavejs2mqtt_0xe74752f9_14-50-0-value-67330', 'name': 'nodeID_14_electric_kvar_value_0'}' According to home assistant documentation https://www.home-assistant.io/integrations/sensor/#device-class new devices classes exists for reactive powers. I've tried to set a device value configuration in my zwavejsui but the UI does not allow me to set the new devices class, they are not available in the "select" field <img width="585" height="787" alt="Image" src="https://github.com/user-attachments/assets/bc845d2f-50e7-4fe8-b1ff-480dd56f7833" /> How can we handle this fix by the best way ? I suppose more people will have this issue, is there a way to declare a global "mapping" of the kVar units ?
7 条评论