From ade5d6e215d626d306296bc6cc7f255af25dc5a6 Mon Sep 17 00:00:00 2001 From: Yurii Motov Date: Tue, 21 Oct 2025 08:28:50 +0200 Subject: [PATCH 1/2] Disable test workflow run by cron on forks --- .github/workflows/test.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index fb01245f45..e62a8f19f4 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -20,9 +20,12 @@ on: env: UV_SYSTEM_PYTHON: 1 + # Run scheduled jobs only on the main repository (disable cron on forks) + RUN_CONDITION: ${{ github.repository_owner == 'fastapi' || github.event_name != 'schedule' }} jobs: test: + if: ${{ env.RUN_CONDITION }} strategy: matrix: os: [ ubuntu-latest, windows-latest, macos-latest ] @@ -135,7 +138,7 @@ jobs: # https://github.com/marketplace/actions/alls-green#why alls-green: # This job does nothing and is only used for the branch protection - if: always() + if: always() && env.RUN_CONDITION needs: - coverage-combine runs-on: ubuntu-latest From 4bbb0f8073b2f195ddd066e58d6d036c58a7eacd Mon Sep 17 00:00:00 2001 From: Yurii Motov Date: Wed, 22 Oct 2025 18:03:17 +0200 Subject: [PATCH 2/2] Fix `Unrecognized named-value` error --- .github/workflows/test.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 62c05851e1..6951a8ad38 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -20,12 +20,11 @@ on: env: UV_SYSTEM_PYTHON: 1 - # Run scheduled jobs only on the main repository (disable cron on forks) - RUN_CONDITION: ${{ github.repository_owner == 'fastapi' || github.event_name != 'schedule' }} jobs: test: - if: ${{ env.RUN_CONDITION }} + # Run scheduled jobs only on the main repository (disable cron on forks) + if: ${{ github.repository_owner == 'fastapi' || github.event_name != 'schedule' }} strategy: matrix: os: [ ubuntu-latest, windows-latest, macos-latest ] @@ -138,7 +137,7 @@ jobs: # https://github.com/marketplace/actions/alls-green#why alls-green: # This job does nothing and is only used for the branch protection - if: always() && env.RUN_CONDITION + if: always() && (github.repository_owner == 'fastapi' || github.event_name != 'schedule') needs: - coverage-combine runs-on: ubuntu-latest