feat: [DIM-530] AGIbot nav test blueprint using ROSNav bridge#1288
feat: [DIM-530] AGIbot nav test blueprint using ROSNav bridge#1288spomichter wants to merge 3 commits intodevfrom
Conversation
Composes ROSNav with explicit transport assignments: - ros_* In ports use ROSTransport (subscribe from AGIbot ROS topics) - DimOS Out ports use LCMTransport (publish to lcmspy/rerun) - ROSNav bridges internally: ROS → handler code → LCM Registered as 'agibot-nav-test' in all_blueprints.py
Greptile SummaryThis PR adds a new AGIbot navigation test blueprint (
Confidence Score: 2/5
Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
subgraph ROS["AGIbot ROS Navigation Stack"]
R1["/goal_reached"]
R2["/cmd_vel"]
R3["/way_point"]
R4["/registered_scan"]
R5["/terrain_map_ext"]
R6["/path"]
R7["/tf"]
R8["/goal_pose"]
R9["/cancel_goal"]
R10["/stop"]
R11["/joy"]
end
subgraph Blueprint["agibot_nav_test Blueprint"]
subgraph ROSIn["ROS In Ports (ROSTransport)"]
RI1["ros_goal_reached"]
RI2["ros_cmd_vel"]
RI3["ros_way_point"]
RI4["ros_registered_scan"]
RI5["ros_global_pointcloud"]
RI6["ros_path"]
RI7["ros_tf"]
end
NAV["ROSNav Module"]
subgraph ROSOut["ROS Out Ports (ROSTransport)"]
RO1["ros_goal_pose"]
RO2["ros_cancel_goal"]
RO3["ros_soft_stop"]
RO4["ros_joy"]
end
subgraph DimOut["DimOS Out Ports (LCMTransport)"]
D1["pointcloud → /lidar"]
D2["global_pointcloud → /map"]
D3["goal_req → /goal_req"]
D4["goal_active → /goal_active"]
D5["path_active → /path_active"]
D6["cmd_vel → /cmd_vel"]
end
end
subgraph LCM["DimOS Consumers"]
L1["lcmspy / rerun"]
end
R1 -->|ROSTransport| RI1
R2 -->|ROSTransport| RI2
R3 -->|ROSTransport| RI3
R4 -->|ROSTransport| RI4
R5 -->|ROSTransport| RI5
R6 -->|ROSTransport| RI6
R7 -->|ROSTransport| RI7
RI1 --> NAV
RI2 --> NAV
RI3 --> NAV
RI4 --> NAV
RI5 --> NAV
RI6 --> NAV
RI7 --> NAV
NAV --> RO1
NAV --> RO2
NAV --> RO3
NAV --> RO4
NAV --> D1
NAV --> D2
NAV --> D3
NAV --> D4
NAV --> D5
NAV --> D6
RO1 -->|ROSTransport| R8
RO2 -->|ROSTransport| R9
RO3 -->|ROSTransport| R10
RO4 -->|ROSTransport| R11
D1 -->|LCMTransport| L1
D2 -->|LCMTransport| L1
D3 -->|LCMTransport| L1
D4 -->|LCMTransport| L1
D5 -->|LCMTransport| L1
D6 -->|LCMTransport| L1
Last reviewed commit: 6173b70 |
dimos/robot/all_blueprints.py
Outdated
| "replanning_a_star_planner": "dimos.navigation.replanning_a_star.module", | ||
| "rerun_bridge": "dimos.visualization.rerun.bridge", | ||
| "ros_nav": "dimos.navigation.rosnav", | ||
| "agibot-nav-test": "dimos.robot.agibot.blueprints.test.agibot_nav_test:agibot_nav_test", |
There was a problem hiding this comment.
Blueprint registered in wrong dictionary
agibot_nav_test is a blueprint (created via autoconnect(...).transports(...)) but is registered in all_modules instead of all_blueprints. This will cause a runtime failure when running dimos run agibot-nav-test:
-
get_blueprint_by_name()looks up the name inall_blueprints— it won't find"agibot-nav-test"there, so it raisesValueError("Unknown blueprint set name: agibot-nav-test"). -
Even if this were somehow resolved to
get_module_by_name(), that function doesgetattr(python_module, name)()wherenameis the dict key"agibot-nav-test". Since Python identifiers cannot contain hyphens,getattr(module, "agibot-nav-test")would raiseAttributeError. The actual exported variable isagibot_nav_test(underscores). -
all_blueprints.pyis auto-generated (line 15: "Do not edit manually"). The auto-scanner intest_all_blueprints_generation.pywould classifyagibot_nav_testas a blueprint (because the assignment ends with.transports(), a blueprint method), so running the generator should produce the correct entry automatically.
Remove this manual edit and instead run pytest dimos/robot/test_all_blueprints_generation.py to regenerate. The expected auto-generated entry would be in all_blueprints:
| "agibot-nav-test": "dimos.robot.agibot.blueprints.test.agibot_nav_test:agibot_nav_test", |
With the auto-generated entry in all_blueprints being:
"agibot-nav-test": "dimos.robot.agibot.blueprints.test.agibot_nav_test:agibot_nav_test",
Composes ROSNav with explicit transport assignments:
Registered as 'agibot-nav-test' in all_blueprints.py