From 6685f2ca9d2fc13d478614debd68152e08255524 Mon Sep 17 00:00:00 2001 From: Henry Park Date: Mon, 9 Mar 2026 15:44:49 -0700 Subject: [PATCH] fix(ci): gate long-running tests by target branch, not label [skip-regression-check] Replace label-based gating with branch-based: run full suite unless PR targets staging. Fixes timing bug where gh pr create --label adds the label after the opened event, causing gated jobs to never run. - Developer PRs (-> staging): fast tests only - Promotion PRs (-> main): full suite - Chained PRs (-> staging-promote/*): full suite - Push to main: full suite - workflow_call: fast tests only Co-Authored-By: Claude Sonnet 4.6 --- .github/workflows/test.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e8894c1b..efa28648 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -41,7 +41,7 @@ jobs: name: Telegram Channel Tests if: > github.event_name == 'push' || - contains(github.event.pull_request.labels.*.name, 'staging-promotion') + (github.event_name == 'pull_request' && github.base_ref != 'staging') runs-on: ubuntu-latest steps: - name: Checkout repository @@ -56,7 +56,7 @@ jobs: name: Windows Build (${{ matrix.name }}) if: > github.event_name == 'push' || - contains(github.event.pull_request.labels.*.name, 'staging-promotion') + (github.event_name == 'pull_request' && github.base_ref != 'staging') runs-on: windows-latest strategy: fail-fast: false @@ -83,7 +83,7 @@ jobs: name: WASM WIT Compatibility if: > github.event_name == 'push' || - contains(github.event.pull_request.labels.*.name, 'staging-promotion') + (github.event_name == 'pull_request' && github.base_ref != 'staging') runs-on: ubuntu-latest steps: - name: Checkout repository @@ -106,7 +106,7 @@ jobs: name: Docker Build if: > github.event_name == 'push' || - contains(github.event.pull_request.labels.*.name, 'staging-promotion') + (github.event_name == 'pull_request' && github.base_ref != 'staging') runs-on: ubuntu-latest steps: - name: Checkout repository