Skip to content

Conversation

@kjchee
Copy link

@kjchee kjchee commented Nov 5, 2025

Bug fix

Fixed bug

Fix double docking issue reported at open-rmf/rmf_ros2#479.

In rmf_traffic::agv::planning::reconstruct_waypoints, previous node's event is copied over to next in-place rotation candidate (here). This behavior is fine for most events, but not for Dock, since it causes the Dock command to trigger twice and adds an unnecessary in-place rotation after docking action.

Fix applied

Skipping the in-place rotation after Dock event while generating the std::vector<WaypointCandidate> candidates.

To test it

a. Before Fix:

  1. using rmf_demo office map, add a Dock to waypoint tinyRobot1_charger.
Screenshot from 2025-11-05 16-59-15
  1. add a line of debug message at ExecutePlan.cpp to verify double Dock added to _phases.
    eg. std::cout << "````````````````````````Add a Dock phase, dock_name[" << dock.dock_name() << "]\n";

  2. launch office sim

  3. send tinyRobot1 from waypoint tinyRobot1_charger to waypoint patrol_A1.

  4. then, send tinyRobot1 to waypoint tinyRobot1_charger.

  5. We will see the terminal log with 2 Dock phase added to _phases.

b. After Fix:

  1. apply the fix
  2. repeat the above steps, we will see only 1 Dock phase added to _phases.

GenAI Use

We follow OSRA's policy on GenAI tools

  • I used a GenAI tool in this PR.
  • I did not use GenAI

@mxgrey mxgrey added this to PMC Board Nov 5, 2025
@github-project-automation github-project-automation bot moved this to Inbox in PMC Board Nov 5, 2025
@aaronchongth aaronchongth moved this from Inbox to In Review in PMC Board Nov 18, 2025
@aaronchongth aaronchongth self-requested a review November 18, 2025 01:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In Review

Development

Successfully merging this pull request may close these issues.

1 participant