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

fix(start/goal_planner): fix freespace planning error handling #8246

Merged

Conversation

kosuke55
Copy link
Contributor

@kosuke55 kosuke55 commented Jul 29, 2024

Description

add error handling when freespace planning can not find path.

Related links

#8068

[openscenario_interpreter_node-3] [component_container_mt-33] terminate called after throwing an instance of 'std::logic_error'
[openscenario_interpreter_node-3] [component_container_mt-33]   what():  HA* failed to find path to goal
[openscenario_interpreter_node-3] [component_container_mt-33] *** Aborted at 1722248354 (unix time) try "date -d @1722248354" if you are using GNU date ***

Parent Issue:

  • Link

How was this PR tested?

wip: 2024/07/29 https://evaluation.tier4.jp/evaluation/reports/5e0d0571-2e37-5845-956e-62dc4f7dd810/?project_id=prd_jt

Notes for reviewers

None.

Interface changes

None.

Effects on system behavior

None.

Signed-off-by: kosuke55 <kosuke.tnp@gmail.com>
@github-actions github-actions bot added the component:planning Route planning, decision-making, and navigation. (auto-assigned) label Jul 29, 2024
Copy link

Thank you for contributing to the Autoware project!

🚧 If your pull request is in progress, switch it to draft mode.

Please ensure:

@kosuke55 kosuke55 added the run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci) label Jul 29, 2024
Copy link

codecov bot commented Jul 29, 2024

Codecov Report

Attention: Patch coverage is 0% with 5 lines in your changes missing coverage. Please review.

Project coverage is 29.12%. Comparing base (5093495) to head (b6f444e).
Report is 10 commits behind head on main.

Files Patch % Lines
...th_start_planner_module/src/freespace_pull_out.cpp 0.00% 3 Missing ⚠️
...th_goal_planner_module/src/freespace_pull_over.cpp 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8246      +/-   ##
==========================================
- Coverage   29.24%   29.12%   -0.12%     
==========================================
  Files        1600     1605       +5     
  Lines      117738   117824      +86     
  Branches    50720    50697      -23     
==========================================
- Hits        34427    34315     -112     
- Misses      74120    74326     +206     
+ Partials     9191     9183       -8     
Flag Coverage Δ *Carryforward flag
differential 0.00% <0.00%> (?)
total 29.18% <ø> (-0.06%) ⬇️ Carriedforward from 5093495

*This pull request uses carry forward flags. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Comment on lines +62 to +66
try {
if (!planner_->makePlan(current_pose, end_pose)) {
return {};
}
} catch (const std::exception & e) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
try {
if (!planner_->makePlan(current_pose, end_pose)) {
return {};
}
} catch (const std::exception & e) {
try {
if (!planner_->makePlan(current_pose, end_pose)) {
RCLCPP_WARN(this->get_logger(), "Failed to make plan: planner returned false");
return {};
}
} catch (const std::exception & e) {
RCLCPP_WARN(this->get_logger(), "Exception caught while making plan: %s", e.what());

I thought it would be better to output the error content, but please ignore this if it's unnecessary.

Copy link
Contributor

@kyoichi-sugahara kyoichi-sugahara left a comment

Choose a reason for hiding this comment

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

LGTM Thanks!

@kosuke55 kosuke55 merged commit 676ed58 into autowarefoundation:main Jul 30, 2024
39 of 41 checks passed
@kosuke55 kosuke55 deleted the fix/error_handling_start_goal branch July 30, 2024 02:07
esteve pushed a commit to esteve/autoware.universe that referenced this pull request Aug 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:planning Route planning, decision-making, and navigation. (auto-assigned) run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants