From 0f847d31987b5f23c5808e1c8a7bf40bb6e07cb9 Mon Sep 17 00:00:00 2001 From: thecode Date: Wed, 27 Oct 2021 14:12:42 +0000 Subject: [PATCH] Fix RPC device - skip status until device is initialized --- aioshelly/rpc_device.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/aioshelly/rpc_device.py b/aioshelly/rpc_device.py index dbe561fa..d8a1554b 100644 --- a/aioshelly/rpc_device.py +++ b/aioshelly/rpc_device.py @@ -64,7 +64,8 @@ def _on_notification( ) -> None: if params is not None: if method == "NotifyStatus": - assert self._status + if self._status is None: + return self._status = dict(mergedicts(self._status, params)) elif method == "NotifyEvent": self._event = params