From 030038a2eb33ab4ad31dee4b48c2c23ab9841161 Mon Sep 17 00:00:00 2001 From: Steve Gerbino Date: Wed, 7 Oct 2026 23:12:02 +0200 Subject: [PATCH] ci: opt in to fork checkout for labeled benchmark runs Naming the head repository was not enough: the checkout guard demands its literal allow-unsafe-pr-checkout flag before fetching fork code under pull_request_target. The approval story is unchanged -- the gate pins the head SHA at label time, the benchmark label is the maintainer's consent to run that code on the dedicated machines, no credentials persist, and tooling comes from the trusted base commit. --- .github/workflows/benchmarks.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/benchmarks.yml b/.github/workflows/benchmarks.yml index 03543edcd..40826a162 100644 --- a/.github/workflows/benchmarks.yml +++ b/.github/workflows/benchmarks.yml @@ -208,6 +208,14 @@ jobs: ref: ${{ needs.gate.outputs.head_sha }} path: ws/head persist-credentials: false + # The checkout guard requires this literal opt-in for fork + # code under pull_request_target; naming the fork repository + # above is not accepted on its own. The risk it warns about + # is governed here: the gate pins the head SHA at label time, + # the benchmark label is a maintainer's explicit approval to + # run that code on these machines, no credentials persist, + # and all tooling comes from the trusted base commit. + allow-unsafe-pr-checkout: true - name: Checkout base uses: actions/checkout@v4