diff --git a/unilabos/ros/nodes/presets/workstation.py b/unilabos/ros/nodes/presets/workstation.py index 5a1eaa75..f8fbe97d 100644 --- a/unilabos/ros/nodes/presets/workstation.py +++ b/unilabos/ros/nodes/presets/workstation.py @@ -241,7 +241,7 @@ class ROS2WorkstationNode(BaseROS2DeviceNode): raw_data = json.loads(response.response) tree_set = ResourceTreeSet.from_raw_list(raw_data) target = tree_set.dump() - protocol_kwargs[k] = target[0] + protocol_kwargs[k] = target[0][0] if v == "unilabos_msgs/Resource" else target except Exception as ex: self.lab_logger().error(f"查询资源失败: {k}, 错误: {ex}\n{traceback.format_exc()}") raise