Skip to content

ci: push backports with AUTO_MERGE_TOKEN to retrigger release-branch CI#4676

Merged
Yicong-Huang merged 3 commits into
apache:mainfrom
Yicong-Huang:chore/ci/backport-trigger
May 2, 2026
Merged

ci: push backports with AUTO_MERGE_TOKEN to retrigger release-branch CI#4676
Yicong-Huang merged 3 commits into
apache:mainfrom
Yicong-Huang:chore/ci/backport-trigger

Conversation

@Yicong-Huang
Copy link
Copy Markdown
Contributor

What changes were proposed in this PR?

In `.github/workflows/direct-backport-push.yml`, the `push-backports` job's `actions/checkout@v5` step now passes `token: ${{ secrets.AUTO_MERGE_TOKEN || secrets.GITHUB_TOKEN }}`. The cherry-pick is then pushed to the release branch under the PAT, which retriggers workflows configured to run on push to release branches. Without this, the default `GITHUB_TOKEN`-authored push is silently excluded from triggering downstream workflows, so post-merge CI on backport commits never runs.

Falls back to `GITHUB_TOKEN` when the secret is unset, preserving current behavior on forks without the secret.

Any related issues, documentation, discussions?

Closes #4673. Follow-up to #4580 (post-merge backport automation) and #4594 (CI for release branches). Uses the same `AUTO_MERGE_TOKEN` PAT introduced for the AutoQueue stand-in (#4553 / #4672).

How was this PR tested?

Not yet — exercises only when a PR with a backport label is merged into `main`. After landing and configuring the `AUTO_MERGE_TOKEN` repo secret, plan to:

  • Merge any PR carrying a backport label.
  • Confirm a successful `Direct Backport Push` run.
  • Confirm the resulting push on the release branch triggers the expected post-merge CI run.

If `AUTO_MERGE_TOKEN` is not configured, the workflow falls back to `GITHUB_TOKEN` and behavior is unchanged.

Was this PR authored or co-authored using generative AI tooling?

Generated-by: Claude Opus 4.7 (Claude Code)

Cherry-pick pushes to release branches currently use the default
GITHUB_TOKEN, which is excluded from triggering downstream workflows.
Use AUTO_MERGE_TOKEN (fine-grained PAT) when present so post-merge CI
runs against the backport commit on the release branch. Falls back to
GITHUB_TOKEN when the secret is unset (preserves current behavior on
forks without the secret).

Closes apache#4673
@github-actions github-actions Bot added the ci changes related to CI label May 2, 2026
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented May 2, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 46.75%. Comparing base (cfe472e) to head (84a81c9).

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #4676      +/-   ##
============================================
+ Coverage     46.16%   46.75%   +0.59%     
- Complexity     1995     2068      +73     
============================================
  Files          1013     1013              
  Lines         38165    39571    +1406     
  Branches       3712     3852     +140     
============================================
+ Hits          17618    18503     +885     
- Misses        19774    20280     +506     
- Partials        773      788      +15     
Flag Coverage Δ
agent-service 28.73% <ø> (ø)
frontend 34.97% <ø> (-0.31%) ⬇️
python 85.18% <ø> (+0.12%) ⬆️
scala 38.51% <ø> (+0.34%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Yicong-Huang Yicong-Huang added the release/v1.1.0-incubating back porting to release/v1.1.0-incubating label May 2, 2026
@Yicong-Huang Yicong-Huang enabled auto-merge (squash) May 2, 2026 09:27
@Yicong-Huang Yicong-Huang merged commit 7811115 into apache:main May 2, 2026
26 checks passed
Yicong-Huang added a commit that referenced this pull request May 2, 2026
…CI (#4676)

## What changes were proposed in this PR?

In \`.github/workflows/direct-backport-push.yml\`, the
\`push-backports\` job's \`actions/checkout@v5\` step now passes
\`token: \${{ secrets.AUTO_MERGE_TOKEN || secrets.GITHUB_TOKEN }}\`. The
cherry-pick is then pushed to the release branch under the PAT, which
retriggers workflows configured to run on push to release branches.
Without this, the default \`GITHUB_TOKEN\`-authored push is silently
excluded from triggering downstream workflows, so post-merge CI on
backport commits never runs.

Falls back to \`GITHUB_TOKEN\` when the secret is unset, preserving
current behavior on forks without the secret.

## Any related issues, documentation, discussions?

Closes #4673. Follow-up to #4580 (post-merge backport automation) and
#4594 (CI for release branches). Uses the same \`AUTO_MERGE_TOKEN\` PAT
introduced for the AutoQueue stand-in (#4553 / #4672).

## How was this PR tested?

Not yet — exercises only when a PR with a backport label is merged into
\`main\`. After landing and configuring the \`AUTO_MERGE_TOKEN\` repo
secret, plan to:

- [ ] Merge any PR carrying a backport label.
- [ ] Confirm a successful \`Direct Backport Push\` run.
- [ ] Confirm the resulting push on the release branch triggers the
expected post-merge CI run.

If \`AUTO_MERGE_TOKEN\` is not configured, the workflow falls back to
\`GITHUB_TOKEN\` and behavior is unchanged.

## Was this PR authored or co-authored using generative AI tooling?

Generated-by: Claude Opus 4.7 (Claude Code)

Co-authored-by: Yicong Huang <yiconghuang@cs.umass.edu>

(backported from commit 7811115)
@Yicong-Huang
Copy link
Copy Markdown
Contributor Author

CleanShot 2026-05-02 at 10 36 21

Release branch now confirmed to have post CI runs. ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci changes related to CI release/v1.1.0-incubating back porting to release/v1.1.0-incubating

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Direct Backport Push: cherry-pick push to release branch does not trigger release-branch CI

3 participants