From 0c5d05d9e153923a659be0d2d10452bd024762a5 Mon Sep 17 00:00:00 2001 From: konsti Date: Mon, 14 Oct 2024 22:46:41 +0200 Subject: [PATCH] Don't run publish tests from fork (#8168) Only the astral-sh/uv repository has the secrets. --------- Co-authored-by: Charlie Marsh --- .github/workflows/ci.yml | 3 ++- scripts/publish/test_publish.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 46ea8d7eb..753ddd270 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1012,13 +1012,14 @@ jobs: code: - "crates/uv-publish/**/*" - "scripts/publish/**/*" + - ".github/workflows/ci.yml" integration-test-publish: timeout-minutes: 10 needs: integration-test-publish-changed name: "integration test | uv publish" runs-on: ubuntu-latest - if: ${{ github.repository == 'astral-sh/uv' && (needs.integration-test-publish-changed.outputs.code == 'true' || github.ref == 'refs/heads/main') }} + if: ${{ github.repository == 'astral-sh/uv' && github.event.pull_request.head.repo.fork != true && (needs.integration-test-publish-changed.outputs.code == 'true' || github.ref == 'refs/heads/main') }} environment: uv-test-publish env: # No dbus in GitHub Actions diff --git a/scripts/publish/test_publish.py b/scripts/publish/test_publish.py index b089a7991..6e774a72b 100644 --- a/scripts/publish/test_publish.py +++ b/scripts/publish/test_publish.py @@ -1,7 +1,7 @@ # /// script # requires-python = ">=3.12" # dependencies = [ -# "httpx>=0.27,<0.28", +# "httpx>=0.27.2,<0.28", # "packaging>=24.1,<25", # ] # ///