From 560db1fa0f5466c163176b9f000e72d99a0e4256 Mon Sep 17 00:00:00 2001 From: Andrew Murray Date: Wed, 1 Jul 2026 19:31:51 +1000 Subject: [PATCH 1/2] Use python3 --- .github/workflows/benchmark.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml index 91d6c920787..6e61b2688f1 100644 --- a/.github/workflows/benchmark.yml +++ b/.github/workflows/benchmark.yml @@ -93,4 +93,4 @@ jobs: mode: simulation run: | python3 -m pip install -e . pytest-codspeed - pytest -vv --codspeed Tests/benchmarks.py + python3 -m pytest -vv --codspeed Tests/benchmarks.py From 4b3a31a8fa01923575dc01e8068fac1a8881e7be Mon Sep 17 00:00:00 2001 From: Andrew Murray Date: Fri, 3 Jul 2026 22:30:10 +1000 Subject: [PATCH 2/2] Do not use CodSpeedHQ/action on pull requests to a fork --- .github/workflows/benchmark.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml index 6e61b2688f1..f6bad95ac03 100644 --- a/.github/workflows/benchmark.yml +++ b/.github/workflows/benchmark.yml @@ -88,9 +88,16 @@ jobs: GHA_LIBWEBP_CACHE_HIT: ${{ steps.cache-libwebp.outputs.cache-hit }} - name: Run CodSpeed benchmarks + if: github.event_name != 'pull_request' || github.event.repository.fork == false uses: CodSpeedHQ/action@a4a36bb07c0638b0b4ca52bf1f3dad1b4289e52f # v4.18.1 with: mode: simulation run: | python3 -m pip install -e . pytest-codspeed python3 -m pytest -vv --codspeed Tests/benchmarks.py + + - name: Run CodSpeed benchmarks on pull requests to a fork + if: github.event_name == 'pull_request' && github.event.repository.fork == true + run: | + python3 -m pip install -e . pytest-codspeed + python3 -m pytest -vv --codspeed Tests/benchmarks.py