Skip to content

Register brain_box_msgs/Hist so the package generates and ships it - #80

Open
eastagiletracker wants to merge 1 commit into
AutoModality:ros2from
eastagiletracker:agile-board/register-hist-msg
Open

Register brain_box_msgs/Hist so the package generates and ships it#80
eastagiletracker wants to merge 1 commit into
AutoModality:ros2from
eastagiletracker:agile-board/register-hist-msg

Conversation

@eastagiletracker

Copy link
Copy Markdown

This PR proposes registering brain_box_msgs/Hist in the package's message manifest so it is generated and shipped, and qualifying its header field to std_msgs/Header. We include this PR work along with a full history of your repo at https://eastagiletracker.com/projects/254. You can sign in with your GitHub ID to claim ownership of the project.

What this fixes

brain_box_msgs/msg/Hist.msg exists in the tree and belongs to the same histogram family as CeilingHist, EdgeHist, CorrFrontHist, CorrSidesHist and PanelHist, but it was never added to rosidl_generate_interfaces() in brain_box_msgs/CMakeLists.txt. Because that macro generates exactly the interfaces it is given, Hist is never generated and no downstream package can use brain_box_msgs/msg/Hist.

There is a second, coupled problem: Hist.msg declares a bare Header header field. Unlike ROS 1, ROS 2 does not special-case Header; rosidl resolves an unqualified type against the current package, so Header becomes brain_box_msgs/Header — a message that does not exist. Every other headered message in the package (its *Hist siblings and 94 others) already uses std_msgs/Header, so simply listing Hist.msg as-is would break message generation. This PR does both halves: it registers msg/Hist.msg and qualifies the field to std_msgs/Header.

Reproducing on the current ros2 HEAD

Interface file present on disk but missing from the manifest:

$ cd brain_box_msgs
$ for f in msg/*.msg srv/*.srv action/*.action; do grep -qF "$f" CMakeLists.txt || echo "NOT REGISTERED: $f"; done
NOT REGISTERED: msg/Hist.msg

The lone bare header (all other definitions already qualify it):

$ grep -rn '^Header header' msg/
msg/Hist.msg:1:Header header

I also ran the ROS 2 message parser (rosidl_adapter) over Hist.msg on HEAD: its header field resolves to brain_box_msgs/Header, which is undefined.

Verification

After the change, the first loop prints nothing (every .msg/.srv/.action on disk is now registered — 207/207), and the parser resolves Hist.header to std_msgs/Header, matching CeilingHist and the rest of the package. I parsed every message in the package to confirm none references a non-existent brain_box_msgs/<type> after the edit. The change is purely additive — nothing referenced Hist or brain_box_msgs/Header before — so it is backward-compatible for existing consumers; it only makes an already-authored interface available. find_package(std_msgs REQUIRED) and the std_msgs dependency are already declared, so no package.xml change is needed. Note that PR #74 also edits CMakeLists.txt (adding unrelated new messages); this one-line addition sits next to msg/Heartbeat.msg and should merge cleanly alongside it.

How this was managed

We imported your repo's issues and pull requests into a live board and used it to manage this work. The specific story for this change is at https://eastagiletracker.com/projects/254/stories/147490, and the full board is at https://eastagiletracker.com/projects/254.

board

If you'd rather not receive contributions like this, reply no-more-prs on this pull request and we won't open any further ones on your repositories.


Lawrence W. Sinclair
CEO / East Agile
linkedin.com/in/lwsinclair/
eastagile.com

Hist.msg exists under msg/ but was never listed in
rosidl_generate_interfaces(), so the Hist interface is never
generated and downstream packages cannot use brain_box_msgs/msg/Hist.

Register msg/Hist.msg and qualify its header field to
std_msgs/Header (it was a bare "Header", which rosidl resolves to
the nonexistent brain_box_msgs/Header). This matches its sibling
*Hist messages (CeilingHist, EdgeHist, ...) and the other 94
headered messages in the package.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant