From a1c34f138e83a5103b32c0a7b78fd29981c89cef Mon Sep 17 00:00:00 2001 From: Xuwznln <18435084+Xuwznln@users.noreply.github.com> Date: Sun, 28 Dec 2025 23:22:50 +0800 Subject: [PATCH] Close #208. Fix mock devices. (cherry picked from commit 28f93737acea10d45e6a2dd0d6110d8777735ec5) --- unilabos/app/ws_client.py | 2 +- .../experiments/mock_devices/mock_all.json | 20 +++++++++---------- .../mock_devices/mock_chiller.json | 2 +- .../experiments/mock_devices/mock_filter.json | 2 +- .../experiments/mock_devices/mock_heater.json | 2 +- .../experiments/mock_devices/mock_pump.json | 2 +- .../mock_devices/mock_rotavap.json | 2 +- .../mock_devices/mock_separator.json | 2 +- .../mock_devices/mock_solenoid_valve.json | 2 +- .../mock_devices/mock_stirrer.json | 2 +- .../mock_devices/mock_stirrer_new.json | 2 +- .../experiments/mock_devices/mock_vacuum.json | 2 +- .../mock_protocol/centrifugeteststation.json | 2 +- .../mock_protocol/filterteststation.json | 2 +- .../mock_protocol/heatchillteststation.json | 2 +- .../mock_protocol/stirteststation.json | 2 +- 16 files changed, 25 insertions(+), 25 deletions(-) diff --git a/unilabos/app/ws_client.py b/unilabos/app/ws_client.py index 8c44712..6da4f5f 100644 --- a/unilabos/app/ws_client.py +++ b/unilabos/app/ws_client.py @@ -1240,7 +1240,7 @@ class WebSocketClient(BaseCommunicationClient): }, } self.message_processor.send_message(message) - logger.debug(f"[WebSocketClient] Device status published: {device_id}.{property_name}") + logger.trace(f"[WebSocketClient] Device status published: {device_id}.{property_name}") def publish_job_status( self, feedback_data: dict, item: QueueItem, status: str, return_info: Optional[dict] = None diff --git a/unilabos/test/experiments/mock_devices/mock_all.json b/unilabos/test/experiments/mock_devices/mock_all.json index 10d224f..7327b54 100644 --- a/unilabos/test/experiments/mock_devices/mock_all.json +++ b/unilabos/test/experiments/mock_devices/mock_all.json @@ -8,7 +8,7 @@ ], "parent": null, "type": "device", - "class": "mock_chiller", + "class": "virtual_heatchill", "position": { "x": 620.6111111111111, "y": 171, @@ -49,7 +49,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_filter", + "class": "virtual_filter", "position": { "x": 620.6111111111111, "y": 171, @@ -80,7 +80,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_heater", + "class": "virtual_heatchill", "position": { "x": 620.6111111111111, "y": 171, @@ -108,7 +108,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_pump", + "class": "virtual_transfer_pump", "position": { "x": 620.6111111111111, "y": 171, @@ -147,7 +147,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_rotavap", + "class": "virtual_rotavap", "position": { "x": 620.6111111111111, "y": 171, @@ -175,7 +175,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_separator", + "class": "virtual_separator", "position": { "x": 620.6111111111111, "y": 171, @@ -213,7 +213,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_solenoid_valve", + "class": "virtual_solenoid_valve", "position": { "x": 620.6111111111111, "y": 171, @@ -233,7 +233,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_stirrer_new", + "class": "virtual_stirrer", "position": { "x": 620.6111111111111, "y": 171, @@ -261,7 +261,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_stirrer", + "class": "virtual_stirrer", "position": { "x": 620.6111111111111, "y": 171, @@ -289,7 +289,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_vacuum", + "class": "virtual_vacuum_pump", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_chiller.json b/unilabos/test/experiments/mock_devices/mock_chiller.json index fc0e2f4..26e48d5 100644 --- a/unilabos/test/experiments/mock_devices/mock_chiller.json +++ b/unilabos/test/experiments/mock_devices/mock_chiller.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_chiller", + "class": "virtual_heatchill", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_filter.json b/unilabos/test/experiments/mock_devices/mock_filter.json index d8d8029..d58e8c7 100644 --- a/unilabos/test/experiments/mock_devices/mock_filter.json +++ b/unilabos/test/experiments/mock_devices/mock_filter.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_filter", + "class": "virtual_filter", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_heater.json b/unilabos/test/experiments/mock_devices/mock_heater.json index 1aca968..ebb82fd 100644 --- a/unilabos/test/experiments/mock_devices/mock_heater.json +++ b/unilabos/test/experiments/mock_devices/mock_heater.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_heater", + "class": "virtual_heatchill", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_pump.json b/unilabos/test/experiments/mock_devices/mock_pump.json index d1c1394..6b54670 100644 --- a/unilabos/test/experiments/mock_devices/mock_pump.json +++ b/unilabos/test/experiments/mock_devices/mock_pump.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_pump", + "class": "virtual_transfer_pump", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_rotavap.json b/unilabos/test/experiments/mock_devices/mock_rotavap.json index b28cfe2..04f0276 100644 --- a/unilabos/test/experiments/mock_devices/mock_rotavap.json +++ b/unilabos/test/experiments/mock_devices/mock_rotavap.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_rotavap", + "class": "virtual_rotavap", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_separator.json b/unilabos/test/experiments/mock_devices/mock_separator.json index 20f2671..2fc7ce7 100644 --- a/unilabos/test/experiments/mock_devices/mock_separator.json +++ b/unilabos/test/experiments/mock_devices/mock_separator.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_separator", + "class": "virtual_separator", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_solenoid_valve.json b/unilabos/test/experiments/mock_devices/mock_solenoid_valve.json index e4e23cc..50d60c7 100644 --- a/unilabos/test/experiments/mock_devices/mock_solenoid_valve.json +++ b/unilabos/test/experiments/mock_devices/mock_solenoid_valve.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_solenoid_valve", + "class": "virtual_solenoid_valve", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_stirrer.json b/unilabos/test/experiments/mock_devices/mock_stirrer.json index 9dfc59c..be419de 100644 --- a/unilabos/test/experiments/mock_devices/mock_stirrer.json +++ b/unilabos/test/experiments/mock_devices/mock_stirrer.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_stirrer", + "class": "virtual_stirrer", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_stirrer_new.json b/unilabos/test/experiments/mock_devices/mock_stirrer_new.json index 837b2fe..b0f58db 100644 --- a/unilabos/test/experiments/mock_devices/mock_stirrer_new.json +++ b/unilabos/test/experiments/mock_devices/mock_stirrer_new.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_stirrer_new", + "class": "virtual_stirrer", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_devices/mock_vacuum.json b/unilabos/test/experiments/mock_devices/mock_vacuum.json index 31406ae..66d4377 100644 --- a/unilabos/test/experiments/mock_devices/mock_vacuum.json +++ b/unilabos/test/experiments/mock_devices/mock_vacuum.json @@ -6,7 +6,7 @@ "children": [], "parent": null, "type": "device", - "class": "mock_vacuum", + "class": "virtual_vacuum_pump", "position": { "x": 620.6111111111111, "y": 171, diff --git a/unilabos/test/experiments/mock_protocol/centrifugeteststation.json b/unilabos/test/experiments/mock_protocol/centrifugeteststation.json index e691834..eefed3e 100644 --- a/unilabos/test/experiments/mock_protocol/centrifugeteststation.json +++ b/unilabos/test/experiments/mock_protocol/centrifugeteststation.json @@ -32,7 +32,7 @@ "children": [], "parent": "CentrifugeTestStation", "type": "device", - "class": "virtual_pump", + "class": "virtual_transfer_pump", "position": { "x": 520.6111111111111, "y": 300, diff --git a/unilabos/test/experiments/mock_protocol/filterteststation.json b/unilabos/test/experiments/mock_protocol/filterteststation.json index a816def..8069e80 100644 --- a/unilabos/test/experiments/mock_protocol/filterteststation.json +++ b/unilabos/test/experiments/mock_protocol/filterteststation.json @@ -32,7 +32,7 @@ "children": [], "parent": "FilterTestStation", "type": "device", - "class": "virtual_pump", + "class": "virtual_transfer_pump", "position": { "x": 520.6111111111111, "y": 300, diff --git a/unilabos/test/experiments/mock_protocol/heatchillteststation.json b/unilabos/test/experiments/mock_protocol/heatchillteststation.json index 9d243b8..f103e13 100644 --- a/unilabos/test/experiments/mock_protocol/heatchillteststation.json +++ b/unilabos/test/experiments/mock_protocol/heatchillteststation.json @@ -32,7 +32,7 @@ "children": [], "parent": "HeatChillTestStation", "type": "device", - "class": "virtual_pump", + "class": "virtual_transfer_pump", "position": { "x": 520.6111111111111, "y": 300, diff --git a/unilabos/test/experiments/mock_protocol/stirteststation.json b/unilabos/test/experiments/mock_protocol/stirteststation.json index 20694d1..4563c9c 100644 --- a/unilabos/test/experiments/mock_protocol/stirteststation.json +++ b/unilabos/test/experiments/mock_protocol/stirteststation.json @@ -32,7 +32,7 @@ "children": [], "parent": "StirTestStation", "type": "device", - "class": "virtual_pump", + "class": "virtual_transfer_pump", "position": { "x": 520.6111111111111, "y": 300,