cancel tests on new commit (#3028)

Auto-generated PR for: cancel tests on new commit
    
<!-- This is an auto-generated description by cubic. -->
---

## Summary by cubic
Cancel in-progress GitHub Actions runs when a new commit is pushed to
the same branch or PR. This cuts wasted CI minutes and speeds up
feedback.

- **Refactors**
- Added concurrency with cancel-in-progress: true to workflows: test,
lint, package, publish, docker, cloud_evals.
- Used group: ${{ github.workflow }}-${{
github.event.pull_request.number || github.ref }} to scope per workflow
and branch/PR.

<!-- End of auto-generated description by cubic. -->
This commit is contained in:
Magnus Müller
2025-09-08 09:05:29 -07:00
committed by GitHub
6 changed files with 32 additions and 0 deletions

View File

@@ -1,5 +1,10 @@
name: cloud_evals
# Cancel in-progress runs when a new commit is pushed to the same branch/PR
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
on:
push:
branches:

View File

@@ -1,5 +1,10 @@
name: docker
# Cancel in-progress runs when a new commit is pushed to the same branch/PR
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
on:
push:
release:

View File

@@ -1,4 +1,10 @@
name: lint
# Cancel in-progress runs when a new commit is pushed to the same branch/PR
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
on:
push:
branches:

View File

@@ -1,4 +1,10 @@
name: package
# Cancel in-progress runs when a new commit is pushed to the same branch/PR
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
on:
push:
branches:

View File

@@ -8,6 +8,11 @@
name: publish
# Cancel in-progress runs when a new commit is pushed to the same branch/PR
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
on:
release:
types: [published] # publish full release to PyPI when a release is created on Github

View File

@@ -7,6 +7,11 @@ permissions:
statuses: write # Allow writing statuses on PRs
discussions: write
# Cancel in-progress runs when a new commit is pushed to the same branch/PR
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
on:
push:
branches: