From 148e3069abf00a39e2951bfd6fe74a6e8e3bdb49 Mon Sep 17 00:00:00 2001 From: Gui Date: Tue, 28 May 2024 09:09:39 -0700 Subject: [PATCH] Clarify what the expected args are --- py/farm_ng/core/event_service.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/py/farm_ng/core/event_service.py b/py/farm_ng/core/event_service.py index 08dfca8e..0f05f61c 100644 --- a/py/farm_ng/core/event_service.py +++ b/py/farm_ng/core/event_service.py @@ -322,9 +322,9 @@ async def request_handler_wrapper( if self._request_reply_handler is None: self.logger.error("No request/reply handler set, returning Empty()") return Empty(), None - expected_args: int = 2 + expected_args: list = ["reply_message", "reply_event"] result = await self._request_reply_handler(*args, **kwargs) - if isinstance(result, tuple) and len(result) == expected_args: + if isinstance(result, tuple) and len(result) == len(expected_args): return result return result, None