We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 0f64389 + 430e85b commit b9f19ebCopy full SHA for b9f19eb
custom_components/xiaomi_gateway3/hass/entity_description.py
@@ -7,8 +7,9 @@
7
from homeassistant.const import (
8
CONCENTRATION_MILLIGRAMS_PER_CUBIC_METER,
9
CONCENTRATION_PARTS_PER_BILLION,
10
- CONDUCTIVITY,
11
LIGHT_LUX,
+ MAJOR_VERSION,
12
+ MINOR_VERSION,
13
PERCENTAGE,
14
SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
15
UnitOfElectricPotential,
@@ -22,6 +23,12 @@
22
23
)
24
from homeassistant.helpers.entity import Entity, EntityCategory
25
26
+if (MAJOR_VERSION, MINOR_VERSION) >= (2024, 7):
27
+ from homeassistant.const import UnitOfConductivity
28
+ CONDUCTIVITY = UnitOfConductivity.MICROSIEMENS
29
+else:
30
+ from homeassistant.const import CONDUCTIVITY
31
+
32
from ..core.converters.base import BaseConv
33
34
# just to reduce the code
0 commit comments