gordlea / fireboard2mqtt

8 stars 5 forks source link

incorrect device_class for sensor drive_lidpaused #33

Closed gordlea closed 7 months ago

gordlea commented 7 months ago

Error:

Logger: homeassistant.components.mqtt.mixins
Source: components/mqtt/mixins.py:270
integration: MQTT (documentation, issues)
First occurred: 7:46:35 PM (5 occurrences)
Last logged: 7:48:46 PM

Error 'expected SensorDeviceClass or one of 'date', 'enum', 'timestamp', 'apparent_power', 'aqi', 'atmospheric_pressure', 'battery', 'carbon_monoxide', 'carbon_dioxide', 'current', 'data_rate', 'data_size', 'distance', 'duration', 'energy', 'energy_storage', 'frequency', 'gas', 'humidity', 'illuminance', 'irradiance', 'moisture', 'monetary', 'nitrogen_dioxide', 'nitrogen_monoxide', 'nitrous_oxide', 'ozone', 'ph', 'pm1', 'pm10', 'pm25', 'power_factor', 'power', 'precipitation', 'precipitation_intensity', 'pressure', 'reactive_power', 'signal_strength', 'sound_pressure', 'speed', 'sulphur_dioxide', 'temperature', 'volatile_organic_compounds', 'volatile_organic_compounds_parts', 'voltage', 'volume', 'volume_storage', 'volume_flow_rate', 'water', 'weight', 'wind_speed' for dictionary value @ data['device_class']' when processing MQTT discovery message topic: 'homeassistant/sensor/GJKK6737J/drive_lidpaused/config', message: '{'unique_id': 'GJKK6737J_drive_lidpaused', 'object_id': 'GJKK6737J_drive_lidpaused', 'name': 'Drive Lid Paused', 'availability': [{'payload_available': 'online', 'payload_not_available': 'offline', 'topic': 'null/bridge/availability'}, {'payload_available': 'online', 'payload_not_available': 'offline', 'topic': 'null/GJKK6737J/availability'}, {'payload_available': 'online', 'payload_not_available': 'offline', 'topic': 'null/GJKK6737J/drive/availability'}], 'device_class': 'opening', 'enabled_by_default': True, 'encoding': 'utf-8', 'qos': 0, 'state_topic': 'null/GJKK6737J/drive/lidpaused', 'device': {'configuration_url': 'https://fireboard.io/devices/180758/edit/', 'connections': [['mac', 'e8:31:cd:d3:41:4c']], 'identifiers': ['180758', 'GJKK6737J', '590b8e87-a282-441d-b357-5dceb2a62a14'], 'manufacturer': 'Fireboard Labs', 'model': 'FBX2D', 'name': 'Meat Master 3000', 'serial_number': 'GJKK6737J', 'sw_version': '3.5.13'}, 'platform': 'mqtt'}'

_Originally posted by @mattdevo1 in https://github.com/gordlea/fireboard2mqtt/pull/31#issuecomment-1998848701_