From b3917f93dc333f824f61a3229a3c88941557f9e0 Mon Sep 17 00:00:00 2001 From: puddly <32534428+puddly@users.noreply.github.com> Date: Thu, 12 Nov 2026 16:59:03 +0000 Subject: [PATCH] Restore children with `rx_on_when_idle=0` --- tests/test_application.py | 1 + zigpy_ziggurat/zigbee/application.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test_application.py b/tests/test_application.py index 00fdb12..92cb431 100644 --- a/tests/test_application.py +++ b/tests/test_application.py @@ -471,6 +471,7 @@ async def test_write_network_info_restores_children( assert [entry.nwk for entry in entries] == list(nwk_addresses.values()) # The backup carries no capability, so the device type is unknown assert {entry.device_type for entry in entries} == {p.ChildDeviceType.UNKNOWN} + assert {entry.rx_on_when_idle for entry in entries} == {0} async def test_permit_ncp( diff --git a/zigpy_ziggurat/zigbee/application.py b/zigpy_ziggurat/zigbee/application.py index 7a5ce36..48c990c 100644 --- a/zigpy_ziggurat/zigbee/application.py +++ b/zigpy_ziggurat/zigbee/application.py @@ -547,7 +547,7 @@ async def _restore_children(self, network_info: zigpy.state.NetworkInfo) -> None p.ChildEntry( ieee=ieee, nwk=network_info.nwk_addresses[ieee], - rx_on_when_idle=t.uint1_t(1), + rx_on_when_idle=t.uint1_t(0), device_type=p.ChildDeviceType.UNKNOWN, reserved=t.uint5_t(0), )