From 78c04acc2e5dec67a992b4df23ad0b3cf4be9179 Mon Sep 17 00:00:00 2001 From: Xuwznln <18435084+Xuwznln@users.noreply.github.com> Date: Mon, 1 Sep 2025 16:34:23 +0800 Subject: [PATCH] fix: missing job_id key --- unilabos/app/ws_client.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/unilabos/app/ws_client.py b/unilabos/app/ws_client.py index af802445..54389342 100644 --- a/unilabos/app/ws_client.py +++ b/unilabos/app/ws_client.py @@ -234,6 +234,10 @@ class WebSocketClient(BaseCommunicationClient): if not task_id: logger.error("[WebSocket] query_action_state missing task_id") return + job_id = data.get("job_id", "") + if not task_id: + logger.error("[WebSocket] query_action_state missing job_id") + return device_action_key = f"/devices/{device_id}/{action_name}" action_jobs = len(HostNode.get_instance()._device_action_status[device_action_key].job_ids) message = { @@ -242,6 +246,7 @@ class WebSocketClient(BaseCommunicationClient): "device_id": device_id, "action_name": action_name, "task_id": task_id, + "job_id": job_id, "free": bool(action_jobs) }, }