Skip to content
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

Add industrial CI #492

Merged
merged 3 commits into from
Dec 2, 2024
Merged

Add industrial CI #492

merged 3 commits into from
Dec 2, 2024

Conversation

Ryanf55
Copy link
Collaborator

@Ryanf55 Ryanf55 commented Nov 28, 2024

Purpose

Add the ROS industrial CI which supposedly can help find missing dependencies earlier in a more minimal test environment.

Details

We currently use rostooling/setup-ros-docker:ubuntu-noble-ros-rolling-desktop-latest as an image, which contains all dependencies.

If we forget dependencies in the package.xml, our CI passes, but the jenkins CI fails.

From what I have read, ros-industrial can solve that.

Let's see if this can reproduce any test failures we have on the jenkins build farm.

@Ryanf55
Copy link
Collaborator Author

Ryanf55 commented Nov 28, 2024

Ok, the first attempt failed (as I expected) because nav2 is not available as binaries.
https://github.com/ANYbotics/grid_map/actions/runs/12073751899/job/33670483685?pr=492#step:3:242

  ERROR: the following packages/stacks could not have their rosdep keys resolved
  to system dependencies:
  grid_map_ros: Cannot locate rosdep definition for [nav2_msgs]
  grid_map_costmap_2d: Cannot locate rosdep definition for [nav2_costmap_2d]

Seems like there is a way to bring in other source packages.

https://github.com/ros-industrial/industrial_ci/blob/master/doc/index.rst#workflow

The best looking option is to depend on the vcs files here and the ones in nav2

@Ryanf55 Ryanf55 added ros2 Affects ROS 2 ci Continuous Integration labels Nov 28, 2024
@Ryanf55
Copy link
Collaborator Author

Ryanf55 commented Nov 28, 2024

Ok, the next commit was able to clone nav2 successfully, however it has errors that slam_toolbox isn't available.

https://github.com/ANYbotics/grid_map/actions/runs/12074002040/job/33671191803?pr=492#step:4:261

  ERROR: the following packages/stacks could not have their rosdep keys resolved
  to system dependencies:
  nav2_bringup: Cannot locate rosdep definition for [slam_toolbox]

The next thing to figure out is how to exclude rosdep keys. I suspect ROSDEP_SKIP_KEYS is what we need.

Nav2 has a skip list tracked here: https://github.com/ros-navigation/navigation2/blob/main/tools/skip_keys.txt

I don't think we should get that list and parse it because NAV2 might move the file.

@Ryanf55
Copy link
Collaborator Author

Ryanf55 commented Nov 28, 2024

If it builds ALL of nav2 (which is unnecessary), we would ideally only build the packages we need in the underlay.

While colcon build --packages-up-to would be great, that's not supported. There's good alternatives here:
ros-industrial/industrial_ci#859

For example, in the docs:

UPSTREAM_WORKSPACE='https://raw.githubusercontent.com/ros-controls/ros_control/melodic-devel/ros_control.rosinstall -ros_control/rqt_controller_manager'

Edit: Yes, we should do this. The nav2 build takes 34 minutes:
Summary: 43 packages finished [34min 25s]

nav2_behavior_tree takes the longest.

@Ryanf55
Copy link
Collaborator Author

Ryanf55 commented Nov 28, 2024

Excellent! The addition of the ROS industrial CI was able to isolate the failure we have on the build farm that we didn't see in our CI!
https://github.com/ANYbotics/grid_map/actions/runs/12074104056/job/33671488356?pr=492#step:5:5021

The workflow is SLOW though. I'd like to merge this as-is, and then do speed optimizations as a follow up.

For speed optimizations, here's some options:

  • Only build the packages we need in nav2
  • Use mergify to only trigger the workflow when requested as a comment on a PR
  • Integrate this as part of a merge pipeline after we click to merge that it runs checks and bounces the PR back if it fails

I don't want this to run every commit, or every time you push to PR because it's so slow.

Next, I'm going to rebase this on top of #491 to see if the build is now stable.

@Ryanf55
Copy link
Collaborator Author

Ryanf55 commented Nov 29, 2024

@Mergifyio rebase

Signed-off-by: Ryan Friedman <[email protected]>
Copy link

mergify bot commented Nov 29, 2024

rebase

✅ Branch has been successfully rebased

@Ryanf55 Ryanf55 requested a review from wep21 November 29, 2024 15:55
@Ryanf55 Ryanf55 merged commit c313843 into ANYbotics:rolling Dec 2, 2024
4 checks passed
@Ryanf55 Ryanf55 deleted the add-industrial-ci branch December 2, 2024 01:13
@Ryanf55
Copy link
Collaborator Author

Ryanf55 commented Dec 2, 2024

@Mergifyio backport jazzy

Copy link

mergify bot commented Dec 2, 2024

backport jazzy

✅ Backports have been created

@Ryanf55
Copy link
Collaborator Author

Ryanf55 commented Dec 2, 2024

@Mergifyio backport iron

Copy link

mergify bot commented Dec 2, 2024

backport iron

✅ Backports have been created

@Ryanf55
Copy link
Collaborator Author

Ryanf55 commented Dec 2, 2024

@Mergifyio backport humble

Copy link

mergify bot commented Dec 2, 2024

backport humble

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Dec 2, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)
mergify bot pushed a commit that referenced this pull request Dec 2, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)
mergify bot pushed a commit that referenced this pull request Dec 2, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)
Ryanf55 added a commit that referenced this pull request Dec 7, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)
Ryanf55 added a commit that referenced this pull request Dec 7, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)
Ryanf55 added a commit that referenced this pull request Dec 7, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)
Ryanf55 added a commit that referenced this pull request Dec 7, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)
Ryanf55 added a commit that referenced this pull request Dec 7, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)

Co-authored-by: Ryan <[email protected]>
Ryanf55 added a commit that referenced this pull request Dec 7, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)

Co-authored-by: Ryan <[email protected]>
Ryanf55 added a commit that referenced this pull request Dec 7, 2024
Add industrial CI

* Bring nav2 in from source on rolling
* Skip rosdep keys in nav2 that don't resolve

Signed-off-by: Ryan Friedman <[email protected]>
(cherry picked from commit c313843)

Co-authored-by: Ryan <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant