-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conflict between rmw_cyclone_cpp
and rmw_implementation
when building projects that rely on rclcpp
#215
Comments
Hi @Mechazo11, I haven't fully digested this whole issue yet but I already noticed something off that probably isn't helping the situation:
Space ROS is a separate ROS distribution and shouldn't be sourced as an overlay on any other ROS install the way it is overlaying humble here. We actually consider it a bug that there are humble components being apt-installed and are working to remove that and ensure we check for it in the future space-ros/docker#187 I suspect, but have not worked through your report enough to confirm, that this issue stems from the build system selecting dependencies from the underlay and overlay in an unsupported way. The fact that you are apt installing the required packages instead of building any missing ones into a workspace on top of the Space ROS base is only going to further the problem as you are falling back on a different ROS disto's pre-pcakged bins rather than bringing the required deps into Space ROS. |
@Bckempa thank you very much for looking into this. Yes, I suspected this much why Space ROS preferred to source build. However at that time (and as of today), without the apt like patch, I cannot get O3DE's ROS 2 Gem to build which subsequently breaks the build. What can be the next step in troubleshooting this issue? Update: I will try to update the Dockerfile for the |
@Mechazo11, great writeup. i have to admit i did not read it entirely. but can i suggest to try something to solve the original issue you face? not sure you have done this, but the following setup may be better:
|
Hi @asimonov I recall trying this route by modifying the space_robots_demo container ( |
Hi @asimonov and @Bckempa , apologies for the long delay but over the last weekend I was able to follow along the suggested steps from the discussion we had a few weeks earlier. Even after ensuring I am not using any ros2-humble packages ( When convenient, can you kindly try out the following docker image to reproduce the error on your end. Please allot about 25GB of disk space.
docker pull osrf/space-ros
cd ~/Downloads
git clone https://github.com/Mechazo11/space_ros_rmw_conflict.git
cd space_ros_rmw_conflict/
docker build -t rmw_conflict -f Dockerfile_rmw_conflict .
source ${SPACEROS_DIR}/install/setup.bash
source ${COLCON_WS_DIR}/install/setup.bash
cmake -B build/linux -G "Ninja Multi-Config" -DLY_DISABLE_TEST_MODULES=ON -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DLY_STRIP_DEBUG_SYMBOLS=ON -DAZ_USE_PHYSX5:BOOL=ON Hopefully with some guidance, I should be able to finish this integration and have Open 3D Engine correctly supported in Space ROS (and in extension to any source built derivative of ROS 2). |
When convenient, would you kindly try out the docker file from the previous comment? I have tried to incorporate all the suggested steps but still saw the same problem. Maybe a fresh perspective would help us resolve this problem. With best, |
I may try over the weekend.Does the build fail? Or runtime?_____________________________Kind Regards,Alexey SimonovOn 18 Oct 2024, at 17:24, AZMYIN MD KAMAL ***@***.***> wrote:
Hi @asimonov and @Bckempa
When convenient, would you kindly try out the docker file from the previous comment? I have tried to incorporate all the suggested steps but still saw the same problem. Maybe a fresh perspective would help us resolve this problem.
With best,
@Mechazo11
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: ***@***.***>
|
@asimonov yes you should see the build fail and reproduce the error shown in the first comment. From there is where I am confused on how to proceed in solving the error |
Version or commit hash
humble-2024.07.0
RMW Implementation
CycloneDDS
Steps to reproduce issue
Dear Space ROS maintainers.
Apologies in advance for the long message but replicating this error and its tentative solution, both requires some convoluted process.
As part of my NASA Space ROS Summer Sprint Challenge 2024 (space-ros/demos PR #64) submission, I demonstrated Open 3D Engine (O3DE) can successfully integrate with Space ROS (any ROS 2 variant to be more exact) via the ROS 2 Gem from O3DE project. ROS 2 Gem depends on the following ROS 2 packages
However, during my build attempt in Docker, I came across a potential fatal bug. Apparently, there is a conflict between
rmw_cyclonedds_cpp
andrmw_implementation
where it appears to find two instances ofrmw_implementation::rmw_implementation
. Please see the attached console output. I tried looking up this error online but did not find anything that resembles this exact problem. The closest I found was this: ros2/rmw_implementation#4Reproducing this error is somewhat challenging as it happens only when compiling an O3DE project with ROS 2 Gem. To help reproduce this error I have created a public repository](https://github.com/Mechazo11/space_ros_rmw_conflict) which will build the
rmw_conflict
image based onosrf/space_ros
base image. Please allot 30GB space and 20-25mins to building thermw_conflict
image. After the image has been built, follow these stepsOpen a container:
docker run -it rmw_conflict /bin/bash
Execute the following commands in the container's terminal
The error message shown in the provided console output clearly shows
rmw_cyclonedds_cpp
andrmw_implementation
are in odds with each other.I was able to solve this problem but it involved deleting the
Install
directory of the base spaceros workspace and rebuilding it. This was done in the following stepsThe above steps while solving this RMW conflict issue also installs
ros-humble-rmw-fastrtps-cpp
that then requires to be manually removed.I am not sure why this patch works but taking a look at the ros2.repos for the base image
could there be a potential bug in
rmw_implementation
version 2.8.4 (I checked it corresponds tohumble
branch for that repo)?Opening a container of the
rmw_conflict
image described above and runningapt show ros-humble-rmw-implementation
gives the following outputAny insight to this problem will be highly appreciated.
Expected behavior
ROS 2 Gem in O3DE finds the correct RMW without raising this error. Space ROS workspace does not need to be rebuilt and not binary version of the aforementioned packages needs to be installed.
Actual behavior
Install
directory of base space ros image needs to be deleted. Multiple packages needs to be manually removed from thesrc
file and then their ROS 2 binary counterpart needs to be installed. After that, when doing a colcon build,test_rmw_implementation
package needs to be ignored.Backtrace or Console output
The text was updated successfully, but these errors were encountered: