Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Xiaomi Miio integration missing sensor entities #59045

@xrypta

Description

@xrypta

The problem

After updating from 2021.10.7 to 2021.11.0 the Xiaomi Miio integration is not giving any sensor entities. In my specific use-case for the Air Humidifier MJJSQ both the Humidity sensor and the Temperature sensor.

Binary and switch entities still work.

What version of Home Assistant Core has the issue?

2021.11.0

What was the last working version of Home Assistant Core?

2021.10.7

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Xiaomi Miio

Link to integration documentation on our website

https://www.home-assistant.io/integrations/xiaomi_miio/

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No specific entries besides;

Logger: homeassistant.components.sensor
Source: components/xiaomi_miio/device.py:160
Integration: Sensor (documentation, issues)
First occurred: November 3, 2021, 11:19:42 PM (8 occurrences)
Last logged: 2:43:00 AM

Error while setting up xiaomi_miio platform for sensor
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 249, in _async_setup_platform
    await asyncio.shield(task)
  File "/usr/src/homeassistant/homeassistant/components/xiaomi_miio/sensor.py", line 635, in async_setup_entry
    XiaomiGenericSensor(
  File "/usr/src/homeassistant/homeassistant/components/xiaomi_miio/sensor.py", line 658, in __init__
    self._attr_native_value = self._determine_native_value()
  File "/usr/src/homeassistant/homeassistant/components/xiaomi_miio/sensor.py", line 692, in _determine_native_value
    return self._extract_value_from_attribute(
  File "/usr/src/homeassistant/homeassistant/components/xiaomi_miio/device.py", line 160, in _extract_value_from_attribute
    value = getattr(state, attribute)
AttributeError: 'AirHumidifierStatus' object has no attribute 'use_time'

Additional information

No response

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions