From 467514c7afe350daeb1b9ce48c8ade97bb68df16 Mon Sep 17 00:00:00 2001 From: Ramon Roche Date: Mon, 23 Nov 2026 19:52:03 -0800 Subject: [PATCH] ci(px4_msgs): drop the release branch dispatch to the interface library The dispatch to px4-ros2-interface-lib needs an account with write access to that repository, and the one time it fired, for release/1.18, it was refused. The library will pick up new PX4 release branches with a daily check of its own instead, which needs no access from our side. What is left of the workflow only creates the px4_msgs branch, so rename it to say that, and describe both paths in the release process. Assisted-by: Claude:claude-fable-5-2 Signed-off-by: Ramon Roche --- .../create_px4_msgs_release_branch.yml | 29 +++++++++++++ .../sync_release_to_ros2_interface_lib.yml | 43 ------------------- docs/en/releases/release_process.md | 10 ++--- 3 files changed, 34 insertions(+), 48 deletions(-) create mode 100644 .github/workflows/create_px4_msgs_release_branch.yml delete mode 100644 .github/workflows/sync_release_to_ros2_interface_lib.yml diff --git a/.github/workflows/create_px4_msgs_release_branch.yml b/.github/workflows/create_px4_msgs_release_branch.yml new file mode 100644 index 00000000000..ce3c3e05f90 --- /dev/null +++ b/.github/workflows/create_px4_msgs_release_branch.yml @@ -0,0 +1,29 @@ +name: Create px4_msgs release branch + +on: + create: + workflow_dispatch: + inputs: + branch: + description: 'Release branch name (e.g. release/1.18)' + required: true + type: string + +permissions: {} + +jobs: + # The px4_msgs sync only runs when messages change, so without this a new + # release branch has no px4_msgs branch until the first change lands on it. + sync-px4-msgs: + if: >- + github.repository == 'PX4/PX4-Autopilot' && + ( + (github.event_name == 'create' && github.ref_type == 'branch' && startsWith(github.ref_name, 'release/')) || + github.event_name == 'workflow_dispatch' + ) + permissions: + contents: read + uses: ./.github/workflows/sync_to_px4_msgs.yml + with: + branch: ${{ inputs.branch || github.ref_name }} + secrets: inherit diff --git a/.github/workflows/sync_release_to_ros2_interface_lib.yml b/.github/workflows/sync_release_to_ros2_interface_lib.yml deleted file mode 100644 index 8c07767fefc..00000000000 --- a/.github/workflows/sync_release_to_ros2_interface_lib.yml +++ /dev/null @@ -1,43 +0,0 @@ -name: Sync release branch to px4_msgs and px4-ros2-interface-lib - -on: - create: - workflow_dispatch: - inputs: - branch: - description: 'Release branch name (e.g. release/1.18)' - required: true - type: string - -permissions: {} - -jobs: - # px4_msgs goes first, so its release branch already exists when the - # interface library is told to create the branch that builds against it. - sync-px4-msgs: - if: >- - github.repository == 'PX4/PX4-Autopilot' && - ( - (github.event_name == 'create' && github.ref_type == 'branch' && startsWith(github.ref_name, 'release/')) || - github.event_name == 'workflow_dispatch' - ) - permissions: - contents: read - uses: ./.github/workflows/sync_to_px4_msgs.yml - with: - branch: ${{ inputs.branch || github.ref_name }} - secrets: inherit - - notify-interface-lib: - needs: sync-px4-msgs - runs-on: ubuntu-latest - env: - GH_TOKEN: ${{ secrets.PX4BUILTBOT_PERSONAL_ACCESS_TOKEN }} - BRANCH: ${{ inputs.branch || github.ref_name }} - steps: - # gh prints the HTTP status and GitHub's message when the dispatch is refused - - name: Dispatch release branch creation - run: >- - gh api repos/Auterion/px4-ros2-interface-lib/dispatches - -f event_type=px4_release_branch - -f "client_payload[branch]=$BRANCH" diff --git a/docs/en/releases/release_process.md b/docs/en/releases/release_process.md index 2e661725f9d..91ad111f087 100644 --- a/docs/en/releases/release_process.md +++ b/docs/en/releases/release_process.md @@ -79,13 +79,13 @@ git checkout -b release/1.18 git push origin release/1.18 ``` -Pushing the branch runs the [sync_release_to_ros2_interface_lib.yml](https://github.com/PX4/PX4-Autopilot/blob/main/.github/workflows/sync_release_to_ros2_interface_lib.yml) workflow, which creates the matching release branch in the companion repositories: +The companion repositories get a matching release branch without further steps: -- [PX4/px4_msgs](https://github.com/PX4/px4_msgs) -- [Auterion/px4-ros2-interface-lib](https://github.com/Auterion/px4-ros2-interface-lib) +- [PX4/px4_msgs](https://github.com/PX4/px4_msgs): created right away by the `create_px4_msgs_release_branch.yml` workflow in PX4-Autopilot. +- [Auterion/px4-ros2-interface-lib](https://github.com/Auterion/px4-ros2-interface-lib): created within a day by that repository's [create_release_branch.yml](https://github.com/Auterion/px4-ros2-interface-lib/blob/main/.github/workflows/create_release_branch.yml) workflow, which checks PX4 for new release branches. -Check that both branches exist once the workflow has finished. -If one is missing, run the workflow again from the Actions tab with the release branch name as input. +Check that both branches exist. +Either workflow can also be run by hand from the Actions tab of its repository, with the release branch name as input. The [ROS integration tests](https://github.com/PX4/PX4-Autopilot/blob/main/.github/workflows/ros_integration_tests.yml) build `px4-ros2-interface-lib` at the commit pinned in [Tools/ros2/ros2.repos](https://github.com/PX4/PX4-Autopilot/blob/main/Tools/ros2/ros2.repos), and the new release branch starts with the pin it inherited from `main`. When the PX4 release branch needs a fix from the library, update the pin on the release branch to a commit from the library's matching release branch.