From 4960c472571ac737a3e4287745ecfdae0ac5cb7b Mon Sep 17 00:00:00 2001 From: shishu314 Date: Fri, 24 Oct 2025 14:23:50 -0400 Subject: [PATCH] fix(infra) - Simplify cancel in progress and add permission to set status step (#11835) Co-authored-by: gemini-cli-robot --- .github/workflows/test_chained_e2e.yml | 6 ++++-- .github/workflows/trigger_e2e.yml | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test_chained_e2e.yml b/.github/workflows/test_chained_e2e.yml index adb77ffa03..8ded1a7591 100644 --- a/.github/workflows/test_chained_e2e.yml +++ b/.github/workflows/test_chained_e2e.yml @@ -18,9 +18,9 @@ on: required: true concurrency: - group: '${{ github.workflow }}-${{ github.head_ref || github.ref }}' + group: '${{ github.workflow }}-${{ github.head_ref || github.event.workflow_run.head_branch || github.ref }}' cancel-in-progress: |- - ${{ github.ref != 'refs/heads/main' && !startsWith(github.ref, 'refs/heads/release/') }} + ${{ github.event_name != 'push' && github.event_name != 'merge_group' }} permissions: contents: 'read' @@ -99,6 +99,7 @@ jobs: set_pending_status: runs-on: 'gemini-cli-ubuntu-16-core' + permissions: 'write-all' if: "github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_run'" needs: - 'parse_run_context' @@ -286,6 +287,7 @@ jobs: set_workflow_status: runs-on: 'gemini-cli-ubuntu-16-core' + permissions: 'write-all' if: "github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_run'" needs: - 'parse_run_context' diff --git a/.github/workflows/trigger_e2e.yml b/.github/workflows/trigger_e2e.yml index dd6079cee2..c8cfe5d744 100644 --- a/.github/workflows/trigger_e2e.yml +++ b/.github/workflows/trigger_e2e.yml @@ -15,7 +15,7 @@ jobs: steps: - name: 'Save Repo name' env: - # Replace with github.event.pull_request.base.repo.full_name when switched to listen on pull request events. This repo name does not contain the org which is needed for checkout. + # Replace with github.event.pull_request.head.repo.full_name when switched to listen on pull request events. This repo name does not contain the org which is needed for checkout. REPO_NAME: '${{ github.event.repository.name }}' run: | mkdir -p ./pr