From 8399a9568dba42bbd752f53244046e5ced229201 Mon Sep 17 00:00:00 2001 From: DaughterOfMars Date: Fri, 23 Aug 2024 11:27:53 -0400 Subject: [PATCH] chore(CI): Re-add concurrencies to reusable workflows (#1856) * chore(CI): Re-add concurrencies to reusable workflows * try disambiguating with workflow_ref * try for hierarchy * just change them all * revert * add qualifiers to reusable workflows * add a few missed ones --- .github/workflows/_docs_lint.yml | 4 ++++ .github/workflows/_docusaurus.yml | 4 ++++ .github/workflows/_e2e.yml | 2 +- .github/workflows/_execution_cut.yml | 4 ++++ .github/workflows/_external_rust_lints.yml | 4 ++++ .github/workflows/_external_rust_tests.yml | 4 ++++ .github/workflows/_move_tests.yml | 4 ++++ .github/workflows/_mysticeti_tests.yml | 2 +- .github/workflows/_rust.yml | 4 ++++ .github/workflows/_rust_lints.yml | 4 ++++ .github/workflows/_rust_tests.yml | 4 ++++ .github/workflows/_turborepo.yml | 4 ++++ .github/workflows/_typos.yml | 2 +- 13 files changed, 43 insertions(+), 3 deletions(-) diff --git a/.github/workflows/_docs_lint.yml b/.github/workflows/_docs_lint.yml index 8fda79142af..f75ac535396 100644 --- a/.github/workflows/_docs_lint.yml +++ b/.github/workflows/_docs_lint.yml @@ -2,6 +2,10 @@ name: Docs spellcheck and linting on: workflow_call +concurrency: + group: docs-lint-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: spelling: name: Lint documentation diff --git a/.github/workflows/_docusaurus.yml b/.github/workflows/_docusaurus.yml index 482214b0a3a..0aa54ed47b3 100644 --- a/.github/workflows/_docusaurus.yml +++ b/.github/workflows/_docusaurus.yml @@ -2,6 +2,10 @@ name: Docusaurus Build on: workflow_call +concurrency: + group: docusaurus-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: build: name: Lint, Build, and Test diff --git a/.github/workflows/_e2e.yml b/.github/workflows/_e2e.yml index 597d72657aa..56e8b00e4ee 100644 --- a/.github/workflows/_e2e.yml +++ b/.github/workflows/_e2e.yml @@ -20,7 +20,7 @@ on: required: true concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + group: e2e-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} cancel-in-progress: true jobs: diff --git a/.github/workflows/_execution_cut.yml b/.github/workflows/_execution_cut.yml index d22e1cada46..ac3ae47db83 100644 --- a/.github/workflows/_execution_cut.yml +++ b/.github/workflows/_execution_cut.yml @@ -2,6 +2,10 @@ name: Execution cut on: workflow_call +concurrency: + group: execution-cut-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: ${{ github.ref != 'refs/heads/develop' }} + jobs: execution-cut: name: cutting a new execution layer diff --git a/.github/workflows/_external_rust_lints.yml b/.github/workflows/_external_rust_lints.yml index 2e6ff0d9d11..7ea83c3e6b7 100644 --- a/.github/workflows/_external_rust_lints.yml +++ b/.github/workflows/_external_rust_lints.yml @@ -6,6 +6,10 @@ on: isRust: type: boolean +concurrency: + group: ext-rust-lints-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: rustfmt: if: always() && inputs.isRust diff --git a/.github/workflows/_external_rust_tests.yml b/.github/workflows/_external_rust_tests.yml index 14e0847372b..383a5a0b8d2 100644 --- a/.github/workflows/_external_rust_tests.yml +++ b/.github/workflows/_external_rust_tests.yml @@ -6,6 +6,10 @@ on: isRust: type: boolean +concurrency: + group: ext-rust-tests-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: ${{ github.ref != 'refs/heads/develop' }} + jobs: changes: if: inputs.isRust diff --git a/.github/workflows/_move_tests.yml b/.github/workflows/_move_tests.yml index 4c79d869f02..494f40fc82c 100644 --- a/.github/workflows/_move_tests.yml +++ b/.github/workflows/_move_tests.yml @@ -2,6 +2,10 @@ name: Move tests on: workflow_call +concurrency: + group: move-tests-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: ${{ github.ref != 'refs/heads/develop' }} + jobs: # This job ensures that Move unit tests are run if there are changes # to Move code but not Rust code (If there are Rust changes, they diff --git a/.github/workflows/_mysticeti_tests.yml b/.github/workflows/_mysticeti_tests.yml index cd0cee9dc9a..88d70cb3c98 100644 --- a/.github/workflows/_mysticeti_tests.yml +++ b/.github/workflows/_mysticeti_tests.yml @@ -14,7 +14,7 @@ on: - cron: "0 5 * * *" concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + group: mysticeti-tests-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} cancel-in-progress: ${{ github.ref != 'refs/heads/develop' }} env: diff --git a/.github/workflows/_rust.yml b/.github/workflows/_rust.yml index 33f794d5d93..432d86c9f48 100644 --- a/.github/workflows/_rust.yml +++ b/.github/workflows/_rust.yml @@ -6,6 +6,10 @@ on: isRust: type: boolean +concurrency: + group: rust-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: ${{ github.ref != 'refs/heads/develop' }} + env: CARGO_TERM_COLOR: always # Disable incremental compilation. diff --git a/.github/workflows/_rust_lints.yml b/.github/workflows/_rust_lints.yml index 7175ac853b8..0933cb1409f 100644 --- a/.github/workflows/_rust_lints.yml +++ b/.github/workflows/_rust_lints.yml @@ -6,6 +6,10 @@ on: isRust: type: boolean +concurrency: + group: rust-lints-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: rustfmt: if: always() && inputs.isRust diff --git a/.github/workflows/_rust_tests.yml b/.github/workflows/_rust_tests.yml index 46b593056bc..67aacece46c 100644 --- a/.github/workflows/_rust_tests.yml +++ b/.github/workflows/_rust_tests.yml @@ -6,6 +6,10 @@ on: isRust: type: boolean +concurrency: + group: rust-tests-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: ${{ github.ref != 'refs/heads/develop' }} + jobs: changes: if: inputs.isRust diff --git a/.github/workflows/_turborepo.yml b/.github/workflows/_turborepo.yml index 1272ed8b14f..ef22b82b163 100644 --- a/.github/workflows/_turborepo.yml +++ b/.github/workflows/_turborepo.yml @@ -2,6 +2,10 @@ name: Turborepo CI on: workflow_call +concurrency: + group: turborepo-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: ${{ github.ref != 'refs/heads/develop' }} + jobs: audit: name: pnpm audit diff --git a/.github/workflows/_typos.yml b/.github/workflows/_typos.yml index 266b703a24d..dc414e2ce0e 100644 --- a/.github/workflows/_typos.yml +++ b/.github/workflows/_typos.yml @@ -3,7 +3,7 @@ name: Typos on: workflow_call concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + group: typos-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} cancel-in-progress: true jobs: