Hello,
We would like to clarify whether the “Auto-cancel redundant workflows” feature can be extended to branches other than the default branch.
Based on the current behavior and documentation:
“With the exception of your default branch, we will automatically cancel any outstanding workflows on a branch when a newer pipeline is triggered on that branch.”
Our understanding is that only the default branch is excluded from auto-canceling previous workflows, while all other branches have their running workflows canceled when a new pipeline is triggered.
Use case:
We maintain multiple long-lived branches (e.g., 4.0, 5.0, 6.0) and would like these branches to behave like the default branch—meaning workflows should not be auto-canceled on these branches, while the feature remains active for all others.
We are aware that the default branch is defined via the vcs_info field, for example:
https://circleci.com/api/v2/project/github/<mycompany>/<myproject>
{
...
"vcs_info": {
"default_branch": "4.0"
}
...
}
Additionally, we came across a workaround in the CircleCI community forum that suggests disabling the feature entirely and implementing a custom/scripted mechanism to cancel previous workflows manually:
https://discuss.circleci.com/t/workaround-auto-cancel-redundant-builds-on-the-default-branch/39468
However, given the number of workflows we maintain, this approach would be quite cumbersome and difficult to scale.
We also attempted to use pr_only_branch_overrides to define specific branches:
GET https://circleci.com/api/v2/project/github/<mycompany>/<myproject>/settings
{
"advanced": {
"autocancel_builds": true,
"build_prs_only": true,
"pr_only_branch_overrides": [
"4.0",
"5.0",
"6.0"
]
}
}
However, this configuration does not appear to have any effect on the auto-cancel behavior.
Questions:
Is it possible to configure multiple branches to behave like the default branch for this feature?
If not, is there any workaround or alternative approach to selectively disable auto-cancel for specific branches?
Thank you for your support.
Best regards,
João
2 posts - 2 participants
Read full topic
| # | Наименование новости | Тональность | Информативность | Дата публикации |
|---|---|---|---|---|
| 1 | Automatic rerun for failed tests | 0 | 8.73 | 17-04-2026 |
| 2 | Breaking Changes: Config Compilation Updates — September 21, 2026 | 0 | 14.42 | 11-06-2026 |
| 3 | Registry multiple orbs from different branches on the same GitHub project | 0 | 6.83 | 13-05-2026 |
| 4 | Workflow cancellation display status reliability improvements | 0 | 6.31 | 02-07-2026 |
| 5 | Intermittent pipeline inconsistencies when running parallel jobs with shared dependencies | 0 | 7.54 | 19-06-2026 |
| 6 | Email Notification Defaults Changing February 25, 2026 | 0 | 7 | 19-02-2026 |
| 7 | Git Worktree Explained: Work on Multiple Branches at Once | 0 | 8.26 | 06-05-2026 |
| 8 | API Change: Pipeline Error Response Format Update | 0 | 9.16 | 21-09-2026 |
| 9 | GitHub Webhook Secret Exposure — Action Required for GitHub OAuth Projects | 0 | 11.65 | 14-04-2026 |
| 10 | Native GitHub Actions YAML Workflow Support — Preview | 0 | 6.81 | 22-09-2026 |