feat(protocol): define core ROS interfaces - #2
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Implements roadmap PR 02 — Core ROS Interfaces from
docs/architecture-and-development-plan.md.Environment, Agent, and Experiment components need one implementation-independent
ROS 2 wire contract before their runtime behavior can be developed independently.
Scope
ament_cmakerh_interfacespackage.ComponentStatus,EpisodeState,PointNavTask, andEpisodeResult.ResetEnv,ResetAgent,StartEpisode, andAbortEpisode.opaque text fields, and compatibility rules.
tests/contracts.make dev-checkpath.Out of scope
guards; these belong to PR 04.
belong to PR 03 and later orchestration PRs.
Episode Action.
Architecture changes
This follows the existing architecture baseline:
rh_interfacesis a leaf ROSinterface package shared by all three runtime containers. It depends only on
ROS interface-generation/runtime packages plus
builtin_interfacesandgeometry_msgs; it has no dependency on a RoboHarness implementation package.The default generated states are deliberately non-operational:
ComponentStatus.STARTING=0andEpisodeState.PREPARING=0. READY and RUNNINGtherefore require explicit assignment.
EpisodeState.NONE=0represents theabsence of a committed termination reason.
Existing numeric values are stable wire values. Future values may be appended,
but existing values must not be reordered or reused.
Implementation
rosidl_generate_interfacesand exportrosidl_default_runtime.request_idvalues as opaque idempotency keys without embeddingruntime deduplication policy in the message package.
EpisodeResultcompact and refer to the durable JSON result through anopaque
result_uri.detail, abortreason, andresult_urias opaque strings that mustnever be parsed for control decisions.
0.0.0and license valueNOASSERTIONuntil release andlicensing metadata are finalized by roadmap PR 18.
Testing
Validated in the pinned Ubuntu 22.04 / ROS 2 Humble development container:
Coverage includes:
and message type;
The contract suite contains 3 C++ cases and 26 Python cases.
Acceptance criteria
Known limitations
radii, or timeouts; PR 03 owns domain validation.
implementation needs justify a shared catalog.
this interface-only PR.
Follow-up
Roadmap PR 03 will add ROS-independent Experiment/Episode/PointNav models,
configuration loading, validation, and state-transition guards, with conversion
tests against these interfaces.