From e81ef794c37066ca6f6bf889f3b0406aa1cf1c94 Mon Sep 17 00:00:00 2001 From: Marco Lampacrescia <65171491+MarcoLm993@users.noreply.github.com> Date: Wed, 25 Sep 2024 18:19:36 +0200 Subject: [PATCH] Hotfix support bt ports in handle goal (#34) Signed-off-by: Marco Lampacrescia --- .../scxml_entries/scxml_ros_action_client.py | 9 +++++++++ .../scxml_converter/scxml_entries/scxml_transition.py | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/scxml_converter/src/scxml_converter/scxml_entries/scxml_ros_action_client.py b/scxml_converter/src/scxml_converter/scxml_entries/scxml_ros_action_client.py index 1fd034b2..860c498b 100644 --- a/scxml_converter/src/scxml_converter/scxml_entries/scxml_ros_action_client.py +++ b/scxml_converter/src/scxml_converter/scxml_entries/scxml_ros_action_client.py @@ -124,6 +124,15 @@ def check_validity(self) -> bool: self._reject_target) return valid_name and valid_accept and valid_reject + def instantiate_bt_events(self, _: str): + # We do not expect a body with BT ports to be substituted + pass + + def update_bt_ports_values(self, _) -> None: + """Update the values of potential entries making use of BT ports.""" + # We do not expect a body with BT ports to be substituted + pass + def check_valid_ros_instantiations(self, ros_declarations: ScxmlRosDeclarationsContainer) -> bool: assert isinstance(ros_declarations, ScxmlRosDeclarationsContainer), \ diff --git a/scxml_converter/src/scxml_converter/scxml_entries/scxml_transition.py b/scxml_converter/src/scxml_converter/scxml_entries/scxml_transition.py index 4fd97341..0b085f71 100644 --- a/scxml_converter/src/scxml_converter/scxml_entries/scxml_transition.py +++ b/scxml_converter/src/scxml_converter/scxml_entries/scxml_transition.py @@ -103,7 +103,7 @@ def instantiate_bt_events(self, instance_id: str): # Those are expected to be only ticks if is_bt_event(event_str): self._events[event_id] = replace_bt_event(event_str, instance_id) - # The body of a transition is needs to be replaced on derived classes, too + # The body of a transition needs to be replaced on derived classes, too instantiate_exec_body_bt_events(self._body, instance_id) def update_bt_ports_values(self, bt_ports_handler: BtPortsHandler) -> None: