Skip to content

Commit

Permalink
change publisher_handle in rclcpp_publish to optional output content
Browse files Browse the repository at this point in the history
Signed-off-by: yamasaki <[email protected]>
  • Loading branch information
ymski committed Jul 31, 2023
1 parent 7ba5865 commit 8581cbc
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/caret_analyze/infra/lttng/ros2_tracing/processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -547,8 +547,10 @@ def _handle_rclcpp_publish(
) -> None:
if not self._is_valid_data(event):
return

publisher_handle = get_field(event, 'publisher_handle')
if 'publisher_handle' in event.keys():
publisher_handle = get_field(event, 'publisher_handle')
else:
publisher_handle = 0
timestamp = get_field(event, '_timestamp')
message = get_field(event, 'message')
tid = get_field(event, '_vtid')
Expand Down

0 comments on commit 8581cbc

Please sign in to comment.