From b4758a732a0dc9f1085ba4415d57218deb8bafad Mon Sep 17 00:00:00 2001 From: "Adam J. Stewart" Date: Fri, 16 Jun 2023 20:50:42 -0500 Subject: [PATCH] Improve CI concurrency robustness (#1423) --- .github/workflows/release.yaml | 2 +- .github/workflows/style.yaml | 2 +- .github/workflows/tests.yaml | 2 +- .github/workflows/tutorials.yaml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index dc6466ed3..e4d78c2f4 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -77,5 +77,5 @@ jobs: - name: Run notebook checks run: pytest --nbmake --durations=10 --reruns=10 docs/tutorials concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.event.pull_request.head.label || github.head_ref || github.ref }} cancel-in-progress: true diff --git a/.github/workflows/style.yaml b/.github/workflows/style.yaml index 7d4ac12a9..318b3a692 100644 --- a/.github/workflows/style.yaml +++ b/.github/workflows/style.yaml @@ -125,5 +125,5 @@ jobs: - name: Run pyupgrade checks run: pyupgrade --py39-plus $(find . -path ./docs/src -prune -o -name "*.py" -print) concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.event.pull_request.head.label || github.head_ref || github.ref }} cancel-in-progress: true diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 4fae214cf..297d07b48 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -115,5 +115,5 @@ jobs: with: token: ${{ secrets.CODECOV_TOKEN }} concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.event.pull_request.head.label || github.head_ref || github.ref }} cancel-in-progress: true diff --git a/.github/workflows/tutorials.yaml b/.github/workflows/tutorials.yaml index 5a4ea113b..298fefafd 100644 --- a/.github/workflows/tutorials.yaml +++ b/.github/workflows/tutorials.yaml @@ -35,5 +35,5 @@ jobs: - name: Run notebook checks run: pytest --nbmake --durations=10 --reruns=10 docs/tutorials concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + group: ${{ github.workflow }}-${{ github.event.pull_request.head.label || github.head_ref || github.ref }} cancel-in-progress: true