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 ci_matching_branch/ for bottle install jobs #1005

Merged
merged 3 commits into from
Nov 2, 2023

Conversation

scpeters
Copy link
Contributor

@scpeters scpeters commented Sep 5, 2023

We have started documenting how to use the ci_matching_branch/ naming pattern to use custom branches from tooling repositories in pull request CI in gazebosim/docs#377. This PR will add the ci_matching_branch/ functionality to the install_bottle jobs in the following way:

  • If the release-tools branch (RTOOLS_BRANCH) for an install_bottle job starts with ci_matching_branch/, then it will try to check out a matching branch from the osrf/homebrew-simulation tap.

As an example for when this could be used, I'd like to re-enable a test for the gz-sim7 formula that has been disabled for macOS Monterey since a fix in gazebosim/gz-physics#529 has been merged and released. The test is enabled in osrf/homebrew-simulation@2bf74ac in the ci_matching_branch/install_bottle branch (which matches the branch name of this release-tools pull request) and tested in the following job, which happened to run on mac-five.monterey and passed the enabled test:

# BEGIN SECTION: run tests
+ brew linkage --test gz-sim7
+ brew ruby -e 'exit '\''gz-sim7'\''.f.test_defined?'
+ brew test gz-sim7
==> Testing osrf/simulation/gz-sim7
�[34m==>�[0m �[1m/usr/local/opt/ruby/bin/ruby /usr/local/opt/gz-tools2/bin/gz sim -s --iterat�[0m
�[34m==>�[0m �[1mcmake ..�[0m
�[34m==>�[0m �[1mmake�[0m
�[34m==>�[0m �[1m./test_cmake�[0m
�[34m==>�[0m �[1m! grep -rnI 'Applications[/]Xcode' /usr/local/Cellar/gz-sim7/7.5.0_8�[0m
+ brew audit --strict gz-sim7
+ echo '# END SECTION'
# END SECTION

If the release-tools branch (RTOOLS_BRANCH) starts with
ci_matching_branch/ then try to check out a matching
branch from the osrf/homebrew-simulation tap for
bottle install jobs.

Signed-off-by: Steve Peters <scpeters@openrobotics.org>
Copy link
Contributor

@j-rivero j-rivero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor linting hints. Looks good.

@@ -46,6 +46,17 @@ echo '# BEGIN SECTION: setup the osrf/simulation tap'
brew tap osrf/simulation
echo '# END SECTION'

if [[ -n "${RTOOLS_BRANCH}" ]] && \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm quite sure that if RTOOLS_BRANCH is empty, the CI build are going to fail sooner than reaching this point. Leave it if you prefer to keep it anyway.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

jenkins-scripts/lib/project-install-homebrew.bash Outdated Show resolved Hide resolved
jenkins-scripts/lib/project-install-homebrew.bash Outdated Show resolved Hide resolved
jenkins-scripts/lib/project-install-homebrew.bash Outdated Show resolved Hide resolved
jenkins-scripts/lib/project-install-homebrew.bash Outdated Show resolved Hide resolved
scpeters and others added 2 commits November 2, 2023 13:18
Signed-off-by: Steve Peters <scpeters@openrobotics.org>

Co-authored-by: Jose Luis Rivero <jrivero@osrfoundation.org>
Signed-off-by: Steve Peters <scpeters@openrobotics.org>
@scpeters
Copy link
Contributor Author

scpeters commented Nov 2, 2023

I've applied your linting suggestions

@scpeters scpeters merged commit 3f3e34d into master Nov 2, 2023
1 check passed
@scpeters scpeters deleted the ci_matching_branch/install_bottle branch November 2, 2023 22:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants