Skip to content

CI: cancel superseded PR runs and stop rerunning on PR edits - #2352

Open
tuhaihe wants to merge 3 commits into
apache:mainfrom
tuhaihe:ci-cancel-superseded-pr-runs
Open

tuhaihe wants to merge 3 commits into
apache:mainfrom
tuhaihe:ci-cancel-superseded-pr-runs

Conversation

@tuhaihe

@tuhaihe tuhaihe commented Nov 18, 2026

Copy link
Copy Markdown
Member

A new push to a PR now cancels the run still going for the old head, instead of letting it finish while the new run waits. This applies to build, build-dbg, behave and build-deb; build-deb had no concurrency group before and gets one. Pushes to main and REL_2_STABLE and manual runs are not cancelled.

Editing a PR's title or description no longer starts the whole test matrix again: drop the "edited" trigger from build, build-dbg, build-deb and sqlancer. It was added so that a "[skip ci]" put into the PR text later would take effect, but such a skip leaves the required checks unreported and the PR unmergeable.

Changing only a PR's base branch no longer reruns CI; push again or close and reopen the PR.

Fixes #ISSUE_Number

What does this PR do?

Type of Change

  • Bug fix (non-breaking change)
  • New feature (non-breaking change)
  • Breaking change (fix or feature with breaking changes)
  • Documentation update

Breaking Changes

Test Plan

  • Unit tests added/updated
  • Integration tests added/updated
  • Passed make installcheck
  • Passed make -C src/test installcheck-cbdb-parallel

Impact

Performance:

User-facing changes:

Dependencies:

Checklist

Additional Context

CI Skip Instructions


A new push to a PR now cancels the run still going for the old head,
instead of letting it finish while the new run waits.  This applies
to build, build-dbg, behave and build-deb; build-deb had no
concurrency group before and gets one.  Pushes to main and
REL_2_STABLE and manual runs are not cancelled.

Editing a PR's title or description no longer starts the whole test
matrix again: drop the "edited" trigger from build, build-dbg,
build-deb and sqlancer.  It was added so that a "[skip ci]" put into
the PR text later would take effect, but such a skip leaves the
required checks unreported and the PR unmergeable.

Changing only a PR's base branch no longer reruns CI; push again or
close and reopen the PR.
@tuhaihe

tuhaihe commented Nov 18, 2026

Copy link
Copy Markdown
Member Author

This change can also help us save runner quota. Otherwise, we’ll use more of it and have to wait longer to run the tests.

@leborchuk leborchuk left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM, it's really annoying issue, we have an old still running checks after force-push. Last day I killed them manually to free resources but better do it automatically.

Co-authored-by: Alena Rybakina <58230554+Alena0704@users.noreply.github.com>
@tuhaihe
tuhaihe force-pushed the ci-cancel-superseded-pr-runs branch from c6bc408 to 93f559c Compare November 20, 2026 08:28
Apply the group that build-deb now uses to build, build-dbg and
behave too.  PR runs still share one group per PR and cancel
superseded runs.  Pushes to main and REL_2_STABLE and manual runs
each get a group of their own, so a later run no longer drops a
pending one from the queue.
@tuhaihe
tuhaihe force-pushed the ci-cancel-superseded-pr-runs branch from 93f559c to 1455bc2 Compare November 20, 2026 08:28
@tuhaihe
tuhaihe requested a review from Alena0704 November 20, 2026 08:31
@tuhaihe
tuhaihe enabled auto-merge (squash) November 20, 2026 08:35
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.

3 participants