ros2 / ros1_bridge

ROS 2 package that provides bidirectional communication between ROS 1 and ROS 2
Apache License 2.0
425 stars 275 forks source link

Only messages build if custom ros2 package ends in _interfaces and ros1 package ends in _msgs #383

Open trevorablett opened 1 year ago

trevorablett commented 1 year ago

Bug report

Required Info:

Steps to reproduce issue

Unfortunately I don't have the time to generate a reproducible example myself, but the issue is pretty straightforward. I had a custom ros2 package that ends in _interfaces, and a corresponding ros1 package that ends in _msgs. After sourcing and building, only the messages from the package were linked, but not the services. I first solved this by changing the ros2 package name to end in _msgs, and then all messages and services were linked as expected. However, renaming the ros2 package was not an option, and I merely took this measure as part of the debugging process.

Luckily (and conveniently), I was able to circumvent this relatively easily using a yaml mapping file (in my case, simply matching the package names was enough), but it wasn't clear to me if this is by design. My guess is that it is indeed a bug, given the fact that changing the ros2 package name also fixed the problem.

Mostly bringing this up to hopefully save time for others if they have the same issue.