From d25f7b6bb2017275c97dfb6415159a516e368d18 Mon Sep 17 00:00:00 2001 From: Seun Akanni Date: Tue, 27 Oct 2026 00:22:06 +0000 Subject: [PATCH 1/2] ci: correct what the templates say about the workflow name They said the name CI is what keeps the check contexts bare. A check context is the job name and does not depend on the workflow name. What the name does control is the concurrency group, which is scoped to the repository, so a template sharing a name with a required workflow would let the two runs cancel each other. The comment now says that instead. --- templates/BHE/ci-alpha.yml | 5 ++++- templates/BHE/ci-beta.yml | 5 ++++- templates/BHE/ci-prototype.yml | 5 ++++- templates/BHoM/ci-alpha.yml | 5 ++++- templates/BHoM/ci-beta.yml | 5 ++++- templates/BHoM/ci-prototype.yml | 5 ++++- templates/ci-format.yml | 5 ++++- templates/ci-unit-tests.yml | 5 ++++- 8 files changed, 32 insertions(+), 8 deletions(-) diff --git a/templates/BHE/ci-alpha.yml b/templates/BHE/ci-alpha.yml index 67d046d..9fec1aa 100644 --- a/templates/BHE/ci-alpha.yml +++ b/templates/BHE/ci-alpha.yml @@ -2,7 +2,10 @@ # omitted (private repos do not enforce OSS copyright); all other jobs mirror # the BHoM variant. Copy to .github/workflows/ci-alpha.yml in each BHE alpha # repo. Runs on pull_request, non-blocking until a ruleset requires its checks. -# Workflow name CI keeps check contexts bare: required contexts are the job names. +# Check contexts are the job names and do not depend on this workflow's name. +# Keep the name distinct from the required workflow's: the concurrency group is +# built from the name and is scoped to the repository, so two workflows sharing +# a name would let their runs cancel each other. name: CI diff --git a/templates/BHE/ci-beta.yml b/templates/BHE/ci-beta.yml index 8e29c3d..5d5b19f 100644 --- a/templates/BHE/ci-beta.yml +++ b/templates/BHE/ci-beta.yml @@ -8,7 +8,10 @@ # repository-local copy is reduced, so the two definitions must stay identical: a # difference between them surfaces as two check runs of the same name disagreeing, # which is unreadable on a pull request. -# Workflow name CI keeps check contexts bare: required contexts are the job names. +# Check contexts are the job names and do not depend on this workflow's name. +# Keep the name distinct from the required workflow's: the concurrency group is +# built from the name and is scoped to the repository, so two workflows sharing +# a name would let their runs cancel each other. name: CI diff --git a/templates/BHE/ci-prototype.yml b/templates/BHE/ci-prototype.yml index cb8d112..f10cdd4 100644 --- a/templates/BHE/ci-prototype.yml +++ b/templates/BHE/ci-prototype.yml @@ -3,7 +3,10 @@ # the BHoM variant. Copy to .github/workflows/ci-prototype.yml in each BHE # prototype repo. Runs on pull_request, non-blocking until a ruleset requires # its checks. -# Workflow name CI keeps check contexts bare: required contexts are the job names. +# Check contexts are the job names and do not depend on this workflow's name. +# Keep the name distinct from the required workflow's: the concurrency group is +# built from the name and is scoped to the repository, so two workflows sharing +# a name would let their runs cancel each other. name: CI diff --git a/templates/BHoM/ci-alpha.yml b/templates/BHoM/ci-alpha.yml index 6c33c48..402bc27 100644 --- a/templates/BHoM/ci-alpha.yml +++ b/templates/BHoM/ci-alpha.yml @@ -2,7 +2,10 @@ # copyright-compliance (BHoM enforces OSS copyright; the BHE variant omits it). # Copy to .github/workflows/ci-alpha.yml in each BHoM alpha repo. # Runs on pull_request, non-blocking until a ruleset requires its checks. -# Workflow name CI keeps check contexts bare: required contexts are the job names. +# Check contexts are the job names and do not depend on this workflow's name. +# Keep the name distinct from the required workflow's: the concurrency group is +# built from the name and is scoped to the repository, so two workflows sharing +# a name would let their runs cancel each other. name: CI diff --git a/templates/BHoM/ci-beta.yml b/templates/BHoM/ci-beta.yml index f811539..30b0a3b 100644 --- a/templates/BHoM/ci-beta.yml +++ b/templates/BHoM/ci-beta.yml @@ -2,7 +2,10 @@ # copyright-compliance (BHoM enforces OSS copyright; the BHE variant omits it). # Copy to .github/workflows/ci-beta.yml in each BHoM beta repo. # Runs on pull_request, non-blocking until a ruleset requires its checks. -# Workflow name CI keeps check contexts bare: required contexts are the job names. +# Check contexts are the job names and do not depend on this workflow's name. +# Keep the name distinct from the required workflow's: the concurrency group is +# built from the name and is scoped to the repository, so two workflows sharing +# a name would let their runs cancel each other. name: CI diff --git a/templates/BHoM/ci-prototype.yml b/templates/BHoM/ci-prototype.yml index 34498fa..d170e7a 100644 --- a/templates/BHoM/ci-prototype.yml +++ b/templates/BHoM/ci-prototype.yml @@ -2,7 +2,10 @@ # copyright-compliance (BHoM enforces OSS copyright; the BHE variant omits it). # Copy to .github/workflows/ci-prototype.yml in each BHoM prototype repo. # Runs on pull_request, non-blocking until a ruleset requires its checks. -# Workflow name CI keeps check contexts bare: required contexts are the job names. +# Check contexts are the job names and do not depend on this workflow's name. +# Keep the name distinct from the required workflow's: the concurrency group is +# built from the name and is scoped to the repository, so two workflows sharing +# a name would let their runs cancel each other. name: CI diff --git a/templates/ci-format.yml b/templates/ci-format.yml index 6fed4ad..a2e507b 100644 --- a/templates/ci-format.yml +++ b/templates/ci-format.yml @@ -4,7 +4,10 @@ # # Rulesets ignore event filters on required workflows, so this file has # no paths filter. The composite self-skips when no relevant files have changed. -# Workflow name CI keeps check contexts bare: required contexts are the job names. +# Check contexts are the job names and do not depend on this workflow's name. +# Keep the name distinct from the required workflow's: the concurrency group is +# built from the name and is scoped to the repository, so two workflows sharing +# a name would let their runs cancel each other. name: CI diff --git a/templates/ci-unit-tests.yml b/templates/ci-unit-tests.yml index 526e9f8..b58d69e 100644 --- a/templates/ci-unit-tests.yml +++ b/templates/ci-unit-tests.yml @@ -8,7 +8,10 @@ # Extending orgs: override test_toolkit_repo via with: to point at a fork. # Dep forks must carry the relevant changes on the PR's base branch, # not the fork's default branch, since resolve-dependencies clones from the base. -# Workflow name CI keeps check contexts bare: required contexts are the job names. +# Check contexts are the job names and do not depend on this workflow's name. +# Keep the name distinct from the required workflow's: the concurrency group is +# built from the name and is scoped to the repository, so two workflows sharing +# a name would let their runs cancel each other. name: CI From e26188c63215575acc595c6b83f67b725f0047f1 Mon Sep 17 00:00:00 2001 From: Seun Akanni Date: Tue, 27 Oct 2026 00:22:07 +0000 Subject: [PATCH 2/2] ci: separate each template's concurrency group with a literal prefix The group was built from the workflow name alone, and every template is called CI. A group is scoped to the repository, so any other workflow sharing that name shared the group, and with cancel-in-progress set either run could cancel the other. The prefix names the file, so a template cannot collide with another workflow that happens to be called CI, and two templates in one repository cannot collide with each other. The two required-workflow sources at templates/ root take the same prefix as the required workflows they are copied into; the tier bundles, which stay repository-local, take their own. Nothing else changes: workflow names, triggers, jobs and job names are untouched, so no check context moves. --- templates/BHE/ci-alpha.yml | 6 +++++- templates/BHE/ci-beta.yml | 6 +++++- templates/BHE/ci-prototype.yml | 6 +++++- templates/BHoM/ci-alpha.yml | 6 +++++- templates/BHoM/ci-beta.yml | 6 +++++- templates/BHoM/ci-prototype.yml | 6 +++++- templates/ci-format.yml | 6 +++++- templates/ci-unit-tests.yml | 6 +++++- 8 files changed, 40 insertions(+), 8 deletions(-) diff --git a/templates/BHE/ci-alpha.yml b/templates/BHE/ci-alpha.yml index 9fec1aa..5fa0060 100644 --- a/templates/BHE/ci-alpha.yml +++ b/templates/BHE/ci-alpha.yml @@ -15,7 +15,11 @@ on: - develop concurrency: - group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} + # The literal prefix is the separation. A concurrency group is scoped to the + # repository, not to one workflow, so without it this group would collide with + # any other workflow that happened to share this one's name. The tier is in the + # prefix so two tier files in one repository cannot collide either. + group: local-ci-alpha-${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} cancel-in-progress: true jobs: diff --git a/templates/BHE/ci-beta.yml b/templates/BHE/ci-beta.yml index 5d5b19f..5a03820 100644 --- a/templates/BHE/ci-beta.yml +++ b/templates/BHE/ci-beta.yml @@ -21,7 +21,11 @@ on: - develop concurrency: - group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} + # The literal prefix is the separation. A concurrency group is scoped to the + # repository, not to one workflow, so without it this group would collide with + # any other workflow that happened to share this one's name. The tier is in the + # prefix so two tier files in one repository cannot collide either. + group: local-ci-beta-${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} cancel-in-progress: true jobs: diff --git a/templates/BHE/ci-prototype.yml b/templates/BHE/ci-prototype.yml index f10cdd4..3b5adfc 100644 --- a/templates/BHE/ci-prototype.yml +++ b/templates/BHE/ci-prototype.yml @@ -16,7 +16,11 @@ on: - develop concurrency: - group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} + # The literal prefix is the separation. A concurrency group is scoped to the + # repository, not to one workflow, so without it this group would collide with + # any other workflow that happened to share this one's name. The tier is in the + # prefix so two tier files in one repository cannot collide either. + group: local-ci-prototype-${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} cancel-in-progress: true jobs: diff --git a/templates/BHoM/ci-alpha.yml b/templates/BHoM/ci-alpha.yml index 402bc27..46d585d 100644 --- a/templates/BHoM/ci-alpha.yml +++ b/templates/BHoM/ci-alpha.yml @@ -15,7 +15,11 @@ on: - develop concurrency: - group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} + # The literal prefix is the separation. A concurrency group is scoped to the + # repository, not to one workflow, so without it this group would collide with + # any other workflow that happened to share this one's name. The tier is in the + # prefix so two tier files in one repository cannot collide either. + group: local-ci-alpha-${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} cancel-in-progress: true jobs: diff --git a/templates/BHoM/ci-beta.yml b/templates/BHoM/ci-beta.yml index 30b0a3b..5683156 100644 --- a/templates/BHoM/ci-beta.yml +++ b/templates/BHoM/ci-beta.yml @@ -15,7 +15,11 @@ on: - develop concurrency: - group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} + # The literal prefix is the separation. A concurrency group is scoped to the + # repository, not to one workflow, so without it this group would collide with + # any other workflow that happened to share this one's name. The tier is in the + # prefix so two tier files in one repository cannot collide either. + group: local-ci-beta-${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} cancel-in-progress: true jobs: diff --git a/templates/BHoM/ci-prototype.yml b/templates/BHoM/ci-prototype.yml index d170e7a..99e5df4 100644 --- a/templates/BHoM/ci-prototype.yml +++ b/templates/BHoM/ci-prototype.yml @@ -15,7 +15,11 @@ on: - develop concurrency: - group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} + # The literal prefix is the separation. A concurrency group is scoped to the + # repository, not to one workflow, so without it this group would collide with + # any other workflow that happened to share this one's name. The tier is in the + # prefix so two tier files in one repository cannot collide either. + group: local-ci-prototype-${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} cancel-in-progress: true jobs: diff --git a/templates/ci-format.yml b/templates/ci-format.yml index a2e507b..7fb0fdb 100644 --- a/templates/ci-format.yml +++ b/templates/ci-format.yml @@ -15,7 +15,11 @@ on: pull_request: concurrency: - group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} + # The literal prefix is the separation. A concurrency group is scoped to the + # repository, not to one workflow, so without it this group would collide with + # any other workflow that happened to share this one's name. This file is a + # required-workflow source, so its prefix matches the other required workflows'. + group: required-ci-format-${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} cancel-in-progress: true jobs: diff --git a/templates/ci-unit-tests.yml b/templates/ci-unit-tests.yml index b58d69e..16b90cb 100644 --- a/templates/ci-unit-tests.yml +++ b/templates/ci-unit-tests.yml @@ -19,7 +19,11 @@ on: pull_request: concurrency: - group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} + # The literal prefix is the separation. A concurrency group is scoped to the + # repository, not to one workflow, so without it this group would collide with + # any other workflow that happened to share this one's name. This file is a + # required-workflow source, so its prefix matches the other required workflows'. + group: required-ci-unit-tests-${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} cancel-in-progress: true jobs: