Skip to content

认证后提示没有设备或实体 #286

Closed
@LittleKa3235

Description

Describe the Bug / 描述问题

认证后提示没有设备或实体

How to Reproduce / 复现步骤

认证过程中没有问题,也能看到实体数量,但认证后提示没有设备或实体

QQ20241220-164713

Expected Behavior / 预期结果

正常导入实体

Home Assistant Logs / 系统日志

日志记录器: homeassistant.config_entries
来源: config_entries.py:594
首次出现: 16:34:19 (8 次总计出现)
上次记录: 16:45:25

Error setting up entry Ka: 2274011 [中国大陆] for xiaomi_home
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 594, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/xiaomi_home/init.py", line 265, in async_setup_entry
raise err
File "/config/custom_components/xiaomi_home/init.py", line 140, in async_setup_entry
device.spec_transform()
File "/config/custom_components/xiaomi_home/miot/miot_device.py", line 540, in spec_transform
prop.external_unit = self.unit_convert(prop.unit)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/xiaomi_home/miot/miot_device.py", line 619, in unit_convert
'μS/cm': UnitOfConductivity.MICROSIEMENS_PER_CM,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: type object 'UnitOfConductivity' has no attribute 'MICROSIEMENS_PER_CM'

Home Assistant Core Version / Home Assistant Core 版本

2024.11.0

Home Assistant Operation System Version / Home Assistant Operation System 版本

13.0

Xiaomi Home Integration Version / 米家集成版本

v0.1.0

Additional Context / 其他说明

No response

Metadata

Assignees

Labels

duplicateThis issue or pull request already exists

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions