Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Let Navigators have different error codes #3642

Merged
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,15 @@ BtActionServer<ActionT>::BtActionServer(
"reported to your application");
rclcpp::Parameter error_code_names_param("error_code_names", error_code_names);
node->set_parameter(error_code_names_param);
} else {
error_code_names = value.get<std::vector<std::string>>();
std::string error_codes_str;
for (const auto & error_code : error_code_names) {
error_codes_str += "\n" + error_code;
}
RCLCPP_INFO_STREAM(
logger_, "Error_code parameters were set to: "
<< error_codes_str);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this not fit on the next line up?

}
}
}
Expand Down Expand Up @@ -285,7 +294,7 @@ void BtActionServer<ActionT>::populateErrorCode(
highest_priority_error_code = current_error_code;
}
} catch (...) {
RCLCPP_ERROR(
RCLCPP_DEBUG(
logger_,
"Failed to get error code: %s from blackboard",
error_code.c_str());
Expand Down