From b51e33e13afda9839520e55fafe0957b25a8b168 Mon Sep 17 00:00:00 2001 From: Philip Chmielowiec <67855069+philipc2@users.noreply.github.com> Date: Wed, 28 Aug 2024 00:46:26 -0500 Subject: [PATCH] ASV CI Fixes (#912) * fix scrip injection vulnerability * use python-build instead of build --- .github/workflows/asv-benchmarking-pr.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/asv-benchmarking-pr.yml b/.github/workflows/asv-benchmarking-pr.yml index 0d52afc4d..0c7bb4bd0 100644 --- a/.github/workflows/asv-benchmarking-pr.yml +++ b/.github/workflows/asv-benchmarking-pr.yml @@ -5,6 +5,9 @@ on: types: [opened, reopened, synchronize, labeled] workflow_dispatch: +env: + PR_HEAD_LABEL: ${{ github.event.pull_request.head.label }} + jobs: benchmark: if: ${{ contains(github.event.pull_request.labels.*.name, 'run-benchmark') && github.event_name == 'pull_request' || github.event_name == 'workflow_dispatch' }} @@ -29,7 +32,7 @@ jobs: cache-environment-key: "${{runner.os}}-${{runner.arch}}-py${{env.PYTHON_VERSION}}-${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}-benchmark" create-args: >- asv - build + python-build mamba - name: Run Benchmarks @@ -40,7 +43,7 @@ jobs: # ID this runner asv machine --yes echo "Baseline: ${{ github.event.pull_request.base.sha }} (${{ github.event.pull_request.base.label }})" - echo "Contender: ${GITHUB_SHA} (${{ github.event.pull_request.head.label }})" + echo "Contender: ${GITHUB_SHA} ($PR_HEAD_LABEL)" # Run benchmarks for current commit against base ASV_OPTIONS="--split --show-stderr" asv continuous $ASV_OPTIONS ${{ github.event.pull_request.base.sha }} ${GITHUB_SHA}