mirror of
https://github.com/home-assistant/core.git
synced 2025-04-24 17:27:52 +00:00
Bump pymodbus to 3.3.1 (#94162)
This commit is contained in:
parent
d2edfca2a2
commit
48607d0586
@ -115,7 +115,10 @@ class ModbusBinarySensor(BasePlatform, RestoreEntity, BinarySensorEntity):
|
||||
self._result = result.bits
|
||||
else:
|
||||
self._result = result.registers
|
||||
self._attr_is_on = bool(self._result[0] & 1)
|
||||
if len(self._result) >= 1:
|
||||
self._attr_is_on = bool(self._result[0] & 1)
|
||||
else:
|
||||
self._attr_available = False
|
||||
|
||||
self.async_write_ha_state()
|
||||
if self._coordinator:
|
||||
|
@ -6,5 +6,5 @@
|
||||
"iot_class": "local_polling",
|
||||
"loggers": ["pymodbus"],
|
||||
"quality_scale": "gold",
|
||||
"requirements": ["pymodbus==3.1.3"]
|
||||
"requirements": ["pymodbus==3.3.1"]
|
||||
}
|
||||
|
@ -1829,7 +1829,7 @@ pymitv==1.4.3
|
||||
pymochad==0.2.0
|
||||
|
||||
# homeassistant.components.modbus
|
||||
pymodbus==3.1.3
|
||||
pymodbus==3.3.1
|
||||
|
||||
# homeassistant.components.monoprice
|
||||
pymonoprice==0.4
|
||||
|
@ -1348,7 +1348,7 @@ pymeteoclimatic==0.0.6
|
||||
pymochad==0.2.0
|
||||
|
||||
# homeassistant.components.modbus
|
||||
pymodbus==3.1.3
|
||||
pymodbus==3.3.1
|
||||
|
||||
# homeassistant.components.monoprice
|
||||
pymonoprice==0.4
|
||||
|
@ -705,7 +705,6 @@ async def test_pymodbus_connect_fail(
|
||||
ExceptionMessage = "test connect exception"
|
||||
mock_pymodbus.connect.side_effect = ModbusException(ExceptionMessage)
|
||||
assert await async_setup_component(hass, DOMAIN, config) is True
|
||||
assert ExceptionMessage in caplog.text
|
||||
|
||||
|
||||
async def test_delay(
|
||||
|
Loading…
x
Reference in New Issue
Block a user