Skip to content

Commit

Permalink
Show error when the requested plugin doesn't exist
Browse files Browse the repository at this point in the history
  • Loading branch information
corot committed Jul 27, 2023
1 parent cc5351a commit 9c65437
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions mbf_abstract_nav/src/abstract_navigation_server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ void AbstractNavigationServer::callActionGetPath(ActionServerGetPath::GoalHandle
mbf_msgs::GetPathResult result;
result.outcome = mbf_msgs::GetPathResult::INVALID_PLUGIN;
result.message = "No plugin loaded with the given name \"" + goal.planner + "\"!";
ROS_WARN_STREAM_NAMED("get_path", result.message);
ROS_ERROR_STREAM_NAMED("get_path", result.message);
goal_handle.setRejected(result, result.message);
return;
}
Expand Down Expand Up @@ -205,7 +205,7 @@ void AbstractNavigationServer::callActionExePath(ActionServerExePath::GoalHandle
mbf_msgs::ExePathResult result;
result.outcome = mbf_msgs::ExePathResult::INVALID_PLUGIN;
result.message = "No plugin loaded with the given name \"" + goal.controller + "\"!";
ROS_WARN_STREAM_NAMED("exe_path", result.message);
ROS_ERROR_STREAM_NAMED("exe_path", result.message);
goal_handle.setRejected(result, result.message);
return;
}
Expand Down Expand Up @@ -264,7 +264,7 @@ void AbstractNavigationServer::callActionRecovery(ActionServerRecovery::GoalHand
mbf_msgs::RecoveryResult result;
result.outcome = mbf_msgs::RecoveryResult::INVALID_PLUGIN;
result.message = "No plugin loaded with the given name \"" + goal.behavior + "\"!";
ROS_WARN_STREAM_NAMED("recovery", result.message);
ROS_ERROR_STREAM_NAMED("recovery", result.message);
goal_handle.setRejected(result, result.message);
return;
}
Expand Down

0 comments on commit 9c65437

Please sign in to comment.