Skip to content

Commit

Permalink
release.py: skip ROS for non-stable releases (#1261)
Browse files Browse the repository at this point in the history
Add a test for the prerelease cases in ros_vendor

Signed-off-by: Steve Peters <[email protected]>
Signed-off-by: Jose Luis Rivero <[email protected]>
Co-authored-by: Jose Luis Rivero <[email protected]>
  • Loading branch information
scpeters and j-rivero authored Feb 13, 2025
1 parent 914f8e1 commit 1da3adc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
7 changes: 5 additions & 2 deletions check_releasepy.bash
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,14 @@ exec_ignition_gazebo_releasepy_test()

exec_releasepy_with_real_gz()
{
gz_pkg=${1} major_version=${2}
gz_pkg=${1} major_version=${2} extra_params=${3}
./release.py \
--dry-run \
--no-sanity-checks \
--auth user:fake \
--source-repo-uri http://github.com/gazebosim/gz-common \
--source-repo-existing-ref http://github.com/gazebosim/gz-common/foo-tag \
"${gz_pkg}" "${major_version}.x.y"
"${gz_pkg}" "${major_version}.x.y" ${extra_params}
}

expect_job_run()
Expand Down Expand Up @@ -184,6 +184,9 @@ expect_param "${ign_gazebo_source_tarball_uri_test}" "PACKAGE_ALIAS=ignition-gaz
ros_vendor_test=$(exec_releasepy_with_real_gz gz-fuel-tools 9)
expect_vendor_repo "${ros_vendor_test}" gazebo-release/gz_fuel_tools_vendor

ros_vendor_test=$(exec_releasepy_with_real_gz gz-fuel-tools 9 "--upload-to-repo prerelease")
expect_no_vendor "${ros_vendor_test}"

ros_vendor_test=$(exec_releasepy_with_real_gz gz-cmake 2)
expect_no_vendor "${ros_vendor_test}"

Expand Down
4 changes: 4 additions & 0 deletions release.py
Original file line number Diff line number Diff line change
Expand Up @@ -801,6 +801,9 @@ def create_pr_in_gz_vendor_repo(args, ros_distro) -> str:


def process_ros_vendor_package(args):
# Only create ros vendor updates for stable releases
if PRERELEASE or NIGHTLY:
return
print("ROS vendor packages that can be updated:")
if args.package.replace('gz-','') in ROS_VENDOR:
print(" - There are no gz metapackages in ROS")
Expand Down Expand Up @@ -954,6 +957,7 @@ def go(argv):
args.auth_input_arg)
display_help_job_chain_for_source_calls(args)
# Process the possible update of an associated ROS vendor package
# for stable releases only
process_ros_vendor_package(args)


Expand Down

0 comments on commit 1da3adc

Please sign in to comment.