Skip to content

Commit

Permalink
DOC: clean up more action_node logging, broken in merge conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
tangkong committed Nov 19, 2024
1 parent 8ef5de3 commit 75435ab
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions beams/behavior_tree/action_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,16 +58,13 @@ def initialise(self) -> None:
"""
Initialise configures and resets the behaviour ready for (repeated) execution
"""
logger.debug(f"Initliazing {self.name}...")
logger.debug(f"{self.name}.initialise [{self.status.name}->RUNNING]")
self.volatile_status.set_value(py_trees.common.Status.RUNNING)
self.work_gate.set()

def update(self) -> py_trees.common.Status:
"""Increment the counter, monitor and decide on a new status."""
logger.debug(
f"Getting tick on {self.name}. "
f"Status: {self.volatile_status.get_value()}"
)
logger.debug(f"{self.name}.update [{self.status.name}]")

# This does the interprocess communcication between this thread which is
# getting ticked and the work_proc thread which is doing work
Expand All @@ -76,13 +73,8 @@ def update(self) -> py_trees.common.Status:
if new_status == py_trees.common.Status.SUCCESS:
self.feedback_message = "Processing finished"
logger.debug(
"%s.update()[%s->%s][%s]"
% (
self.__class__.__name__,
self.status,
new_status,
self.feedback_message,
)
f"{self.name}.update [{self.status.name}->{new_status.name}] "
f"{self.feedback_message}"
)
# TODO: should clear even here so work thread can go back to wait state
# self.work_gate.clear()
Expand Down

0 comments on commit 75435ab

Please sign in to comment.