From 50851c4ee3a48545ebd9353bbd83133a41855e79 Mon Sep 17 00:00:00 2001 From: Olivier Mattelaer Date: Sat, 24 Oct 2026 16:12:31 +0200 Subject: [PATCH 1/5] CI: run IOTests and the madevent acceptance tests on the self-hosted alma10 runners On a self-hosted runner restore_heptools no longer uses the GitHub caches (built on ubuntu, with /home/runner baked into the install): each machine builds the missing HEPTools components once into its own ~/.cache/HEPtools (selfhosted_heptools). The restore_heptools_* actions use $HOME instead of /home/runner and find the lhapdf/rivet/contur python modules on other images. Fork PRs and the two matrix jobs stay on ubuntu-24.04. --- .github/actions/restore_heptools/action.yml | 19 +++-- .../restore_heptools_contur/action.yml | 27 +++++-- .../actions/restore_heptools_emela/action.yml | 2 +- .../restore_heptools_lhapdf/action.yml | 27 ++++--- .../restore_heptools_looptools/action.yml | 4 +- .../restore_heptools_pythia8/action.yml | 4 +- .../actions/selfhosted_heptools/action.yml | 13 ++++ .../selfhosted_heptools/build_heptools.sh | 72 +++++++++++++++++++ .github/workflows/IOtest.yml | 20 ++++-- .github/workflows/acceptancetest_madevent.yml | 48 +++++++++---- 10 files changed, 191 insertions(+), 45 deletions(-) create mode 100644 .github/actions/selfhosted_heptools/action.yml create mode 100755 .github/actions/selfhosted_heptools/build_heptools.sh diff --git a/.github/actions/restore_heptools/action.yml b/.github/actions/restore_heptools/action.yml index eab077c740..c562b0b020 100644 --- a/.github/actions/restore_heptools/action.yml +++ b/.github/actions/restore_heptools/action.yml @@ -24,6 +24,7 @@ runs: # every restore_heptools_* action. - name: restore full cache id: heptools-cache + if: runner.environment != 'self-hosted' uses: actions/cache/restore@v5 with: path: ~/.cache/HEPtools @@ -49,23 +50,29 @@ runs: tools: lhapdf boost pythia8 emela contur looptools mode: report + # A self-hosted runner does not use the GitHub caches at all: it keeps its + # own ~/.cache/HEPtools and builds what is missing there (once per machine). + - name: build HEPTools on this machine + if: runner.environment == 'self-hosted' + uses: ./.github/actions/selfhosted_heptools + # setup other environment of previous level of cache # try to use their cache if previous cache failed or content is incomplete - uses: ./.github/actions/restore_heptools_lhapdf with: - setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} + setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} - uses: ./.github/actions/restore_heptools_boost with: - setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} + setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} - uses: ./.github/actions/restore_heptools_pythia8 with: - setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} + setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} - uses: ./.github/actions/restore_heptools_emela with: - setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} + setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} - uses: ./.github/actions/restore_heptools_contur with: - setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} + setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} - uses: ./.github/actions/restore_heptools_looptools with: - setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} + setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} diff --git a/.github/actions/restore_heptools_contur/action.yml b/.github/actions/restore_heptools_contur/action.yml index de42f53f9c..88520df3ad 100644 --- a/.github/actions/restore_heptools_contur/action.yml +++ b/.github/actions/restore_heptools_contur/action.yml @@ -33,10 +33,10 @@ runs: - run: | cd $GITHUB_WORKSPACE - echo "hepmc3_path = /home/runner/.cache/HEPtools/hepmc3" >> input/mg7_configuration.txt - echo "rivet_path = /home/runner/.cache/HEPtools/rivet" >> input/mg7_configuration.txt - echo "yoda_path = /home/runner/.cache/HEPtools/yoda" >> input/mg7_configuration.txt - echo "contur_path = /home/runner/.cache/HEPtools/contur" >> input/mg7_configuration.txt + echo "hepmc3_path = $HOME/.cache/HEPtools/hepmc3" >> input/mg7_configuration.txt + echo "rivet_path = $HOME/.cache/HEPtools/rivet" >> input/mg7_configuration.txt + echo "yoda_path = $HOME/.cache/HEPtools/yoda" >> input/mg7_configuration.txt + echo "contur_path = $HOME/.cache/HEPtools/contur" >> input/mg7_configuration.txt # Only point MG5 at fastjet if it is really there. The cache restore # above is best-effort (fail-on-cache-miss is false, and warm_cache # deletes the contur/heptools caches ~30 min before it re-saves them, @@ -46,7 +46,7 @@ runs: # fastjet/ClusterSequence.hh. Without the line MG5 uses fjcore, which # is a working fallback: the contur/rivet jobs still fail, loudly and on # their own, but the numbered acceptance jobs no longer fail with them. - FJ=/home/runner/.cache/HEPtools/fastjet/bin/fastjet-config + FJ=$HOME/.cache/HEPtools/fastjet/bin/fastjet-config if [ -x "$FJ" ]; then echo "fastjet = $FJ" >> input/mg7_configuration.txt else @@ -57,11 +57,24 @@ runs: - name: set pythonpath for ubuntu22 if: ${{ env.HEPTOOLS_IMAGE == 'ubuntu22' }} run: | - echo "PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/contur/python3.10/:/home/runner/.cache/HEPtools/rivet/python3.10/:/home/runner/.cache/HEPtools/rivet/local/python3.10/" >> $GITHUB_ENV + echo "PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/contur/python3.10/:$HOME/.cache/HEPtools/rivet/python3.10/:$HOME/.cache/HEPtools/rivet/local/python3.10/" >> $GITHUB_ENV shell: bash - name: set pythonpath for ubuntu24 if: ${{ env.HEPTOOLS_IMAGE == 'ubuntu24' }} run: | - echo "PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/contur/python3.12/:/home/runner/.cache/HEPtools/rivet/python3.12/:/home/runner/.cache/HEPtools/rivet/local/python3.10/" >> $GITHUB_ENV + echo "PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/contur/python3.12/:$HOME/.cache/HEPtools/rivet/python3.12/:$HOME/.cache/HEPtools/rivet/local/python3.10/" >> $GITHUB_ENV + shell: bash + # any other image (a self-hosted runner, where ImageOS is unset): take the + # python modules wherever this machine's build put them + - name: set pythonpath for other images + if: ${{ env.HEPTOOLS_IMAGE != 'ubuntu22' && env.HEPTOOLS_IMAGE != 'ubuntu24' }} + run: | + P=$PYTHONPATH + for d in $HOME/.cache/HEPtools/contur/python3* $HOME/.cache/HEPtools/rivet/python3* \ + $HOME/.cache/HEPtools/rivet/local/python3* \ + $HOME/.cache/HEPtools/{rivet,yoda}/{,local/}lib*/python3*/*-packages; do + [ -d "$d" ] && P=$P:$d + done + echo "PYTHONPATH=$P" >> $GITHUB_ENV shell: bash diff --git a/.github/actions/restore_heptools_emela/action.yml b/.github/actions/restore_heptools_emela/action.yml index 5df5ee0645..3e0a19043c 100644 --- a/.github/actions/restore_heptools_emela/action.yml +++ b/.github/actions/restore_heptools_emela/action.yml @@ -34,5 +34,5 @@ runs: - run: | cd $GITHUB_WORKSPACE - echo "eMELA = /home/runner/.cache/HEPtools/bin/eMELA-config" >> input/mg7_configuration.txt + echo "eMELA = $HOME/.cache/HEPtools/bin/eMELA-config" >> input/mg7_configuration.txt shell: bash diff --git a/.github/actions/restore_heptools_lhapdf/action.yml b/.github/actions/restore_heptools_lhapdf/action.yml index 83b0379839..e000605641 100644 --- a/.github/actions/restore_heptools_lhapdf/action.yml +++ b/.github/actions/restore_heptools_lhapdf/action.yml @@ -36,23 +36,23 @@ runs: - run: | cd $GITHUB_WORKSPACE - echo "heptools_install_dir=/home/runner/.cache/HEPtools" >> input/mg7_configuration.txt - echo "lhapdf = /home/runner/.cache/HEPtools/bin/lhapdf-config" >> input/mg7_configuration.txt - echo "lhapdf_py3 = /home/runner/.cache/HEPtools/bin/lhapdf-config" >> input/mg7_configuration.txt - echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPtools/lhapdf6_py3//lib" >> $GITHUB_ENV - echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPtools/lib" >> $GITHUB_ENV + echo "heptools_install_dir=$HOME/.cache/HEPtools" >> input/mg7_configuration.txt + echo "lhapdf = $HOME/.cache/HEPtools/bin/lhapdf-config" >> input/mg7_configuration.txt + echo "lhapdf_py3 = $HOME/.cache/HEPtools/bin/lhapdf-config" >> input/mg7_configuration.txt + echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPtools/lhapdf6_py3//lib" >> $GITHUB_ENV + echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPtools/lib" >> $GITHUB_ENV shell: bash - name: set pythonpath for ubuntu22 if: ${{ env.HEPTOOLS_IMAGE == 'ubuntu22' }} run: | - echo "PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/lhapdf6_py3/lib/python3.10/dist-packages" >> $GITHUB_ENV + echo "PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/lhapdf6_py3/lib/python3.10/dist-packages" >> $GITHUB_ENV shell: bash - name: set pythonpath for ubuntu24 if: ${{ env.HEPTOOLS_IMAGE == 'ubuntu24' }} run: | - echo "PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/lhapdf6_py3/lib/python3.12/dist-packages" >> $GITHUB_ENV + echo "PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/lhapdf6_py3/lib/python3.12/dist-packages" >> $GITHUB_ENV shell: bash # The run_card default PDF sets: NNPDF40_lo_as_01180 (mg7 [beam] pdf and the @@ -63,9 +63,20 @@ runs: # on the set being present and would all self-skip (test_manager.py counts a # skip as a failure). Fetching them here is a no-op once the cache carries # them. Non-fatal on failure: the tests skip as they did before. + # any other image (a self-hosted runner, where ImageOS is unset): take the + # python bindings wherever this machine's build put them + - name: set pythonpath for other images + if: ${{ env.HEPTOOLS_IMAGE != 'ubuntu22' && env.HEPTOOLS_IMAGE != 'ubuntu24' }} + run: | + P=$PYTHONPATH + for d in $HOME/.cache/HEPtools/lhapdf6_py3/lib*/python3*/*-packages; do + [ -d "$d" ] && P=$P:$d + done + echo "PYTHONPATH=$P" >> $GITHUB_ENV + shell: bash - name: ensure the default PDF sets are present run: | - DATADIR=/home/runner/.cache/HEPtools/lhapdf6_py3/share/LHAPDF + DATADIR=$HOME/.cache/HEPtools/lhapdf6_py3/share/LHAPDF for SET in NNPDF40_lo_as_01180 NNPDF40_nlo_as_01180 NNPDF40_nlo_as_01180_nf_4; do if [ -d "$DATADIR" ] && [ ! -d "$DATADIR/$SET" ]; then ( cd "$DATADIR" \ diff --git a/.github/actions/restore_heptools_looptools/action.yml b/.github/actions/restore_heptools_looptools/action.yml index 157d381b32..7d7dddde44 100644 --- a/.github/actions/restore_heptools_looptools/action.yml +++ b/.github/actions/restore_heptools_looptools/action.yml @@ -28,6 +28,6 @@ runs: # this ignore cuttools/iregi cache ... ok but we should try to fix that - run: | cd $GITHUB_WORKSPACE - echo "ninja = /home/runner/.cache/HEPtools/ninja/lib" >> input/mg7_configuration.txt - echo "collier = /home/runner/.cache/HEPtools/collier" >> input/mg7_configuration.txt + echo "ninja = $HOME/.cache/HEPtools/ninja/lib" >> input/mg7_configuration.txt + echo "collier = $HOME/.cache/HEPtools/collier" >> input/mg7_configuration.txt shell: bash diff --git a/.github/actions/restore_heptools_pythia8/action.yml b/.github/actions/restore_heptools_pythia8/action.yml index 1b01937b07..921c7570c8 100644 --- a/.github/actions/restore_heptools_pythia8/action.yml +++ b/.github/actions/restore_heptools_pythia8/action.yml @@ -34,6 +34,6 @@ runs: - run: | cd $GITHUB_WORKSPACE - echo "pythia8_path = /home/runner/.cache/HEPtools/pythia8" >> input/mg7_configuration.txt - echo "hepmc_path = /home/runner/.cache/HEPtools/hepmc" >> input/mg7_configuration.txt + echo "pythia8_path = $HOME/.cache/HEPtools/pythia8" >> input/mg7_configuration.txt + echo "hepmc_path = $HOME/.cache/HEPtools/hepmc" >> input/mg7_configuration.txt shell: bash diff --git a/.github/actions/selfhosted_heptools/action.yml b/.github/actions/selfhosted_heptools/action.yml new file mode 100644 index 0000000000..c8af95470d --- /dev/null +++ b/.github/actions/selfhosted_heptools/action.yml @@ -0,0 +1,13 @@ +name: Build HEPTools on a self-hosted runner +description: > + A self-hosted runner keeps ~/.cache/HEPtools on its own disk from one job to + the next, so instead of the GitHub caches (built by warm_cache.yml on, and + with paths baked in for, the ubuntu image) each machine builds the missing + components itself, once, the first time a job needs them. A component that + fails to build only warns: the tests that need it then fail, the others run. +runs: + using: composite + steps: + - name: Build the missing HEPTools components + shell: bash + run: bash "${{ github.action_path }}/build_heptools.sh" diff --git a/.github/actions/selfhosted_heptools/build_heptools.sh b/.github/actions/selfhosted_heptools/build_heptools.sh new file mode 100755 index 0000000000..0fbceab5ec --- /dev/null +++ b/.github/actions/selfhosted_heptools/build_heptools.sh @@ -0,0 +1,72 @@ +#!/usr/bin/env bash +# Build into ~/.cache/HEPtools every HEPTools component that check_heptools +# does not find complete there, with the same install commands as the +# warm_cache.yml jobs. Runs from a pristine copy of the checked-out tree, so +# the job's own tree is left as checked out. +set -u +HEP="$HOME/.cache/HEPtools" +CHECK="$GITHUB_WORKSPACE/.github/actions/check_heptools/check_heptools.sh" +export MAKEFLAGS="-j$(nproc)" +mkdir -p "$HEP" + +# one build at a time per machine, should several runners share this home +exec 9> "$HEP.lock" +flock 9 + +complete() { + HEPTOOLS_PREFIX="$HEP" CHECK_MODE=fatal GITHUB_OUTPUT= bash "$CHECK" "$1" > /dev/null 2>&1 +} + +SRC="" +prepare_src() { + [ -n "$SRC" ] && return + SRC=$(mktemp -d "${RUNNER_TEMP:-/tmp}/heptools-src.XXXXXX") + git -C "$GITHUB_WORKSPACE" archive HEAD | tar -x -C "$SRC" + cp "$SRC/input/.mg7_configuration_default.txt" "$SRC/input/mg7_configuration.txt" + echo "heptools_install_dir=$HEP" >> "$SRC/input/mg7_configuration.txt" + cp "$SRC/Template/LO/Source/.make_opts" "$SRC/Template/LO/Source/make_opts" +} + +mg_install() { + printf '%s\n' "$@" > "$SRC/cmd" + (cd "$SRC" && ./bin/madgraph cmd) +} + +build_lhapdf() { + mg_install "install lhapdf6" + cd "$HEP/lhapdf6_py3/share/LHAPDF" || return 1 + for SET in NNPDF23_nlo_as_0118_qed cteq6l1 NNPDF40_lo_as_01180 NNPDF40_nlo_as_01180 \ + NNPDF40_nlo_as_01180_nf_4 NNPDF40MC_lo_as_01180 NNPDF23_lo_as_0130_qed; do + [ -d "$SET" ] && continue + wget -q "https://lhapdfsets.web.cern.ch/current/$SET.tar.gz" \ + && tar -xzpf "$SET.tar.gz" && rm -f "$SET.tar.gz" + done +} +build_boost() { mg_install "install boost"; } +build_pythia8() { mg_install "install pythia8"; } +build_emela() { mg_install "install eMELA"; } +build_contur() { mg_install "install rivet" "install contur"; } +build_looptools() { + (cd "$SRC/vendor/IREGI/src" && make) || return 1 + (cd "$SRC/vendor/CutTools" && make) || return 1 + mkdir -p "$HEP/IREGI/src" "$HEP/CutTools/lib" + cp "$SRC/vendor/IREGI/src/libiregi.a" "$HEP/IREGI/src/" + cp "$SRC/vendor/CutTools/includects/libcts.a" "$SRC/vendor/CutTools/includects/mpmodule.mod" "$HEP/CutTools/lib" + mg_install "install collier" "install ninja" +} + +# dependency order: emela needs boost, contur needs pythia8 (hepmc) +for tool in lhapdf boost pythia8 emela contur looptools; do + if complete "$tool"; then + echo "$tool: already built on $RUNNER_NAME" + continue + fi + echo "::group::building $tool on $RUNNER_NAME (first use on this machine)" + prepare_src + ( "build_$tool" ) + echo "::endgroup::" + complete "$tool" || echo "::warning::HEPTools $tool could not be built on $RUNNER_NAME" +done + +[ -n "$SRC" ] && rm -rf "$SRC" +exit 0 diff --git a/.github/workflows/IOtest.yml b/.github/workflows/IOtest.yml index 2bd41a6a93..b22e12dcf0 100644 --- a/.github/workflows/IOtest.yml +++ b/.github/workflows/IOtest.yml @@ -45,7 +45,9 @@ jobs: # IOtest_fks IOtest_fd_gauge IOtest_export # IOtest_unit_proc IOtest_ewsudakov # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} steps: - uses: actions/checkout@v5 @@ -101,7 +103,9 @@ jobs: # Loop squared-order IOTest – needs UFO model cache (from unittest_29) IOtest_loop_sqso: - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} steps: - uses: actions/checkout@v5 - uses: ./.github/actions/restore_ufomodel @@ -116,7 +120,9 @@ jobs: # former jobs, run one after the other: IOtest_acceptance_proc # IOtest_matchbox # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} steps: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 @@ -147,7 +153,9 @@ jobs: IOtest_bundle_3: # former jobs, run one after the other: IOtest_TIR IOtest_loop_induced # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} steps: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 @@ -176,7 +184,9 @@ jobs: # Gnuplot histogram output IOTest (from acceptancetest_100) IOtest_gnuplot: - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} steps: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 diff --git a/.github/workflows/acceptancetest_madevent.yml b/.github/workflows/acceptancetest_madevent.yml index 68164e7016..64f39f2f37 100644 --- a/.github/workflows/acceptancetest_madevent.yml +++ b/.github/workflows/acceptancetest_madevent.yml @@ -38,7 +38,9 @@ concurrency: jobs: acceptancetest_0: # The type of runner that the job will run on - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true # Steps represent a sequence of tasks that will be executed as part of the job @@ -67,7 +69,9 @@ jobs: # acceptancetest_contur acceptancetest_60 # acceptancetest_uncovered_madevent # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -94,7 +98,7 @@ jobs: if: ${{ !cancelled() }} run: | #./tests/test_manager.py test_contur_from_file test_rivet_from_file -pA -t0 -l INFO - PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/contur/python3.10:/home/runner/.cache/HEPTools/rivet/local/lib/python3.10/dist-packages/:/home/runner/.cache/HEPTools/yoda/local/lib/python3.10/dist-packages/ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPTools/lib ./tests/test_manager.py test_rivet_from_file -pA -t0 -l INFO + PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/contur/python3.10:$HOME/.cache/HEPTools/rivet/local/lib/python3.10/dist-packages/:$HOME/.cache/HEPTools/yoda/local/lib/python3.10/dist-packages/ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPTools/lib ./tests/test_manager.py test_rivet_from_file -pA -t0 -l INFO # ---- acceptancetest_60 ---- - name: "acceptancetest_60" @@ -118,7 +122,9 @@ jobs: # acceptancetest_25 acceptancetest_35 acceptancetest_44 acceptancetest_55 # acceptancetest_59 acceptancetest_mssm_gogo # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -192,7 +198,9 @@ jobs: # acceptancetest_density_wpwm acceptancetest_density_decay1 # acceptancetest_density_decay2 # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -257,7 +265,9 @@ jobs: # acceptancetest_24 acceptancetest_38 acceptancetest_45 acceptancetest_47 # acceptancetest_56 acceptancetest_density_ttbar # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -326,7 +336,9 @@ jobs: # former jobs, run one after the other: acceptancetest_37 acceptancetest_52 # acceptancetest_density_interface # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -395,7 +407,9 @@ jobs: # acceptancetest_46 acceptancetest_49 acceptancetest_contur2 # acceptancetest_density_tttbartbar # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -442,7 +456,7 @@ jobs: - name: "acceptancetest_contur2: run the test" if: ${{ !cancelled() }} run: | - PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/contur/python3.10 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPTools/lib ./tests/test_manager.py test_rivet_from_file -pA -t0 -l INFO + PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/contur/python3.10 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPTools/lib ./tests/test_manager.py test_rivet_from_file -pA -t0 -l INFO # ---- acceptancetest_density_tttbartbar ---- - name: "acceptancetest_density_tttbartbar" @@ -460,7 +474,9 @@ jobs: # former jobs, run one after the other: acceptancetest_48 # acceptancetest_heft acceptancetest_madevent_flavor_zud # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -494,7 +510,9 @@ jobs: acceptancetest_53: # The type of runner that the job will run on - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true # Steps represent a sequence of tasks that will be executed as part of the job @@ -537,7 +555,7 @@ jobs: - name: test one of the test test_loop_improved_reweighting run: | cd $GITHUB_WORKSPACE - export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPtools/lhapdf6_py3/lib + export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPtools/lhapdf6_py3/lib export PYTHONPATH=$PYTHONPATH:~/.cache/HEPtools/lhapdf6_py3/lib/python3.12/dist-packages export PYTHONPATH=$PYTHONPATH:~/.cache/HEPtools/lhapdf6_py3/lib/python3.10/dist-packages ./tests/test_manager.py test_nlo_reweighting -pA -t0 -l INFO @@ -547,7 +565,7 @@ jobs: if: ${{ !cancelled() }} run: | cd $GITHUB_WORKSPACE - export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPtools/lhapdf6_py3/lib + export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPtools/lhapdf6_py3/lib export PYTHONPATH=$PYTHONPATH:~/.cache/HEPtools/lhapdf6_py3/lib/python3.12/dist-packages export PYTHONPATH=$PYTHONPATH:~/.cache/HEPtools/lhapdf6_py3/lib/python3.10/dist-packages ./tests/test_manager.py test_nlo_reweighting_new_parameter -pA -t0 -l INFO @@ -563,7 +581,9 @@ jobs: # former jobs, run one after the other: acceptancetest_103_polarization # acceptancetest_flavor acceptancetest_madevent_vbf_merged_flavor # Each keeps its own steps, run even when an earlier one failed. - runs-on: ubuntu-24.04 + # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; + # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. + runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 From c10400a041e795dae92c14d9510ca11e777e9406 Mon Sep 17 00:00:00 2001 From: Olivier Mattelaer Date: Sat, 24 Oct 2026 17:16:22 +0200 Subject: [PATCH 2/5] selfhosted_heptools: build IREGI/CutTools with a serial make Their makefiles do not declare the Fortran module dependencies, so the -j$(nproc) inherited from MAKEFLAGS failed on avh_olo_foriregi_dp_box.mod. --- .github/actions/selfhosted_heptools/build_heptools.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/actions/selfhosted_heptools/build_heptools.sh b/.github/actions/selfhosted_heptools/build_heptools.sh index 0fbceab5ec..254753b7c6 100755 --- a/.github/actions/selfhosted_heptools/build_heptools.sh +++ b/.github/actions/selfhosted_heptools/build_heptools.sh @@ -47,8 +47,10 @@ build_pythia8() { mg_install "install pythia8"; } build_emela() { mg_install "install eMELA"; } build_contur() { mg_install "install rivet" "install contur"; } build_looptools() { - (cd "$SRC/vendor/IREGI/src" && make) || return 1 - (cd "$SRC/vendor/CutTools" && make) || return 1 + # serial: the IREGI/CutTools makefiles do not declare their Fortran module + # dependencies, so a parallel make fails on a missing .mod + (cd "$SRC/vendor/IREGI/src" && MAKEFLAGS= make) || return 1 + (cd "$SRC/vendor/CutTools" && MAKEFLAGS= make) || return 1 mkdir -p "$HEP/IREGI/src" "$HEP/CutTools/lib" cp "$SRC/vendor/IREGI/src/libiregi.a" "$HEP/IREGI/src/" cp "$SRC/vendor/CutTools/includects/libcts.a" "$SRC/vendor/CutTools/includects/mpmodule.mod" "$HEP/CutTools/lib" From 9cad9852b2402b2f4cd1e89d8775176621fced50 Mon Sep 17 00:00:00 2001 From: Olivier Mattelaer Date: Sat, 24 Oct 2026 17:29:58 +0200 Subject: [PATCH 3/5] selfhosted_heptools: size the parallel build on the available memory -j$(nproc) got the runner service OOM-killed on the alma10 machines while building rivet; use one compile per 2 GB of MemAvailable, at most one per core. --- .github/actions/selfhosted_heptools/build_heptools.sh | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/actions/selfhosted_heptools/build_heptools.sh b/.github/actions/selfhosted_heptools/build_heptools.sh index 254753b7c6..da22de741c 100755 --- a/.github/actions/selfhosted_heptools/build_heptools.sh +++ b/.github/actions/selfhosted_heptools/build_heptools.sh @@ -6,7 +6,15 @@ set -u HEP="$HOME/.cache/HEPtools" CHECK="$GITHUB_WORKSPACE/.github/actions/check_heptools/check_heptools.sh" -export MAKEFLAGS="-j$(nproc)" +# The self-hosted machines are short on memory (a -j$(nproc) rivet build got +# the runner service OOM-killed): one compile per 2 GB available, at most one +# per core. +avail_gb=$(awk '/^MemAvailable:/ {print int($2 / 1048576)}' /proc/meminfo) +jobs=$(( avail_gb / 2 )) +[ "$jobs" -gt "$(nproc)" ] && jobs=$(nproc) +[ "$jobs" -lt 1 ] && jobs=1 +export MAKEFLAGS="-j$jobs" +echo "building with $MAKEFLAGS (${avail_gb} GB available, $(nproc) cores)" mkdir -p "$HEP" # one build at a time per machine, should several runners share this home From 896f62171419fc2b266151d29cd3072fc196a818 Mon Sep 17 00:00:00 2001 From: Olivier Mattelaer Date: Sat, 24 Oct 2026 17:42:25 +0200 Subject: [PATCH 4/5] CI: move only the light IOTests/madevent jobs to the alma10 runners The alma10 machines are small (2 cores, 3.3 GB). Keep on ubuntu-24.04 the jobs that need rivet/contur or the NLO/loop libraries (IOtest_bundle_2/3, acceptancetest_0, madevent bundles 1/2/3/6); the moved madevent jobs ask restore_heptools (new selfhosted_tools input) to build only lhapdf, boost, pythia8 and eMELA on the machine. --- .github/actions/restore_heptools/action.yml | 9 +++++ .../actions/selfhosted_heptools/action.yml | 9 ++++- .../selfhosted_heptools/build_heptools.sh | 5 ++- .github/workflows/IOtest.yml | 8 +--- .github/workflows/acceptancetest_madevent.yml | 40 ++++++++++++------- 5 files changed, 48 insertions(+), 23 deletions(-) diff --git a/.github/actions/restore_heptools/action.yml b/.github/actions/restore_heptools/action.yml index c562b0b020..a5267be238 100644 --- a/.github/actions/restore_heptools/action.yml +++ b/.github/actions/restore_heptools/action.yml @@ -1,5 +1,12 @@ name: Restore full heptools cache description: Restores heptools from cache and sets MG5 accordingly +inputs: + selfhosted_tools: + description: > + On a self-hosted runner only: the components to build on the machine when + missing (see selfhosted_heptools). Ignored on GitHub-hosted runners. + required: false + default: 'lhapdf boost pythia8 emela contur looptools' runs: using: composite @@ -55,6 +62,8 @@ runs: - name: build HEPTools on this machine if: runner.environment == 'self-hosted' uses: ./.github/actions/selfhosted_heptools + with: + tools: ${{ inputs.selfhosted_tools }} # setup other environment of previous level of cache # try to use their cache if previous cache failed or content is incomplete diff --git a/.github/actions/selfhosted_heptools/action.yml b/.github/actions/selfhosted_heptools/action.yml index c8af95470d..16d3e674d5 100644 --- a/.github/actions/selfhosted_heptools/action.yml +++ b/.github/actions/selfhosted_heptools/action.yml @@ -5,9 +5,16 @@ description: > with paths baked in for, the ubuntu image) each machine builds the missing components itself, once, the first time a job needs them. A component that fails to build only warns: the tests that need it then fail, the others run. +inputs: + tools: + description: 'Components to build when missing, among lhapdf boost pythia8 emela contur looptools' + required: false + default: 'lhapdf boost pythia8 emela contur looptools' runs: using: composite steps: - name: Build the missing HEPTools components shell: bash - run: bash "${{ github.action_path }}/build_heptools.sh" + env: + HEPTOOLS_BUILD: ${{ inputs.tools }} + run: bash "${{ github.action_path }}/build_heptools.sh" $HEPTOOLS_BUILD diff --git a/.github/actions/selfhosted_heptools/build_heptools.sh b/.github/actions/selfhosted_heptools/build_heptools.sh index da22de741c..3f6da3855a 100755 --- a/.github/actions/selfhosted_heptools/build_heptools.sh +++ b/.github/actions/selfhosted_heptools/build_heptools.sh @@ -1,5 +1,6 @@ #!/usr/bin/env bash -# Build into ~/.cache/HEPtools every HEPTools component that check_heptools +# usage: build_heptools.sh [component ...] (default: all of them) +# Build into ~/.cache/HEPtools every requested HEPTools component that check_heptools # does not find complete there, with the same install commands as the # warm_cache.yml jobs. Runs from a pristine copy of the checked-out tree, so # the job's own tree is left as checked out. @@ -66,7 +67,9 @@ build_looptools() { } # dependency order: emela needs boost, contur needs pythia8 (hepmc) +requested=" ${*:-lhapdf boost pythia8 emela contur looptools} " for tool in lhapdf boost pythia8 emela contur looptools; do + [[ "$requested" == *" $tool "* ]] || continue if complete "$tool"; then echo "$tool: already built on $RUNNER_NAME" continue diff --git a/.github/workflows/IOtest.yml b/.github/workflows/IOtest.yml index b22e12dcf0..5deeaebc14 100644 --- a/.github/workflows/IOtest.yml +++ b/.github/workflows/IOtest.yml @@ -120,9 +120,7 @@ jobs: # former jobs, run one after the other: IOtest_acceptance_proc # IOtest_matchbox # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 @@ -153,9 +151,7 @@ jobs: IOtest_bundle_3: # former jobs, run one after the other: IOtest_TIR IOtest_loop_induced # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 diff --git a/.github/workflows/acceptancetest_madevent.yml b/.github/workflows/acceptancetest_madevent.yml index 64f39f2f37..64edc413d1 100644 --- a/.github/workflows/acceptancetest_madevent.yml +++ b/.github/workflows/acceptancetest_madevent.yml @@ -38,9 +38,7 @@ concurrency: jobs: acceptancetest_0: # The type of runner that the job will run on - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true # Steps represent a sequence of tasks that will be executed as part of the job @@ -69,9 +67,7 @@ jobs: # acceptancetest_contur acceptancetest_60 # acceptancetest_uncovered_madevent # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -122,9 +118,7 @@ jobs: # acceptancetest_25 acceptancetest_35 acceptancetest_44 acceptancetest_55 # acceptancetest_59 acceptancetest_mssm_gogo # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -198,9 +192,7 @@ jobs: # acceptancetest_density_wpwm acceptancetest_density_decay1 # acceptancetest_density_decay2 # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -273,6 +265,10 @@ jobs: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore_heptools + # only what these tests need: rivet/contur and the loop libraries are + # not built on the (small) self-hosted machines + with: + selfhosted_tools: lhapdf boost pythia8 emela - uses: ./.github/actions/restore-pip-cache # ---- acceptancetest_20 ---- @@ -345,6 +341,10 @@ jobs: - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore-pip-cache - uses: ./.github/actions/restore_heptools + # only what these tests need: rivet/contur and the loop libraries are + # not built on the (small) self-hosted machines + with: + selfhosted_tools: lhapdf boost pythia8 emela # ---- acceptancetest_37 ---- - name: "acceptancetest_37" @@ -407,9 +407,7 @@ jobs: # acceptancetest_46 acceptancetest_49 acceptancetest_contur2 # acceptancetest_density_tttbartbar # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 @@ -482,6 +480,10 @@ jobs: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore_heptools + # only what these tests need: rivet/contur and the loop libraries are + # not built on the (small) self-hosted machines + with: + selfhosted_tools: lhapdf boost pythia8 emela # ---- acceptancetest_48 ---- - name: "acceptancetest_48" @@ -521,6 +523,10 @@ jobs: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore_heptools + # only what these tests need: rivet/contur and the loop libraries are + # not built on the (small) self-hosted machines + with: + selfhosted_tools: lhapdf boost pythia8 emela - uses: ./.github/actions/restore-pip-cache - uses: ./.github/actions/restore_ufomodel @@ -589,6 +595,10 @@ jobs: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore_heptools + # only what these tests need: rivet/contur and the loop libraries are + # not built on the (small) self-hosted machines + with: + selfhosted_tools: lhapdf boost pythia8 emela # ---- acceptancetest_103_polarization ---- - name: "acceptancetest_103_polarization" From 904543d5bed1a5a537b37f19a989cd305d283829 Mon Sep 17 00:00:00 2001 From: Olivier Mattelaer Date: Sat, 24 Oct 2026 17:48:51 +0200 Subject: [PATCH 5/5] CI: keep the madevent acceptance tests on ubuntu; only IOTests use alma10 Only IOtest_bundle_1, IOtest_loop_sqso and IOtest_gnuplot run on the alma10 runners, and none of them needs HEPTools, so the per-machine HEPTools build (selfhosted_heptools) and the restore_heptools changes are dropped again. --- .github/actions/restore_heptools/action.yml | 28 ++---- .../restore_heptools_contur/action.yml | 27 ++---- .../actions/restore_heptools_emela/action.yml | 2 +- .../restore_heptools_lhapdf/action.yml | 27 ++---- .../restore_heptools_looptools/action.yml | 4 +- .../restore_heptools_pythia8/action.yml | 4 +- .../actions/selfhosted_heptools/action.yml | 20 ----- .../selfhosted_heptools/build_heptools.sh | 85 ------------------- .github/workflows/acceptancetest_madevent.yml | 48 ++--------- 9 files changed, 35 insertions(+), 210 deletions(-) delete mode 100644 .github/actions/selfhosted_heptools/action.yml delete mode 100755 .github/actions/selfhosted_heptools/build_heptools.sh diff --git a/.github/actions/restore_heptools/action.yml b/.github/actions/restore_heptools/action.yml index a5267be238..eab077c740 100644 --- a/.github/actions/restore_heptools/action.yml +++ b/.github/actions/restore_heptools/action.yml @@ -1,12 +1,5 @@ name: Restore full heptools cache description: Restores heptools from cache and sets MG5 accordingly -inputs: - selfhosted_tools: - description: > - On a self-hosted runner only: the components to build on the machine when - missing (see selfhosted_heptools). Ignored on GitHub-hosted runners. - required: false - default: 'lhapdf boost pythia8 emela contur looptools' runs: using: composite @@ -31,7 +24,6 @@ runs: # every restore_heptools_* action. - name: restore full cache id: heptools-cache - if: runner.environment != 'self-hosted' uses: actions/cache/restore@v5 with: path: ~/.cache/HEPtools @@ -57,31 +49,23 @@ runs: tools: lhapdf boost pythia8 emela contur looptools mode: report - # A self-hosted runner does not use the GitHub caches at all: it keeps its - # own ~/.cache/HEPtools and builds what is missing there (once per machine). - - name: build HEPTools on this machine - if: runner.environment == 'self-hosted' - uses: ./.github/actions/selfhosted_heptools - with: - tools: ${{ inputs.selfhosted_tools }} - # setup other environment of previous level of cache # try to use their cache if previous cache failed or content is incomplete - uses: ./.github/actions/restore_heptools_lhapdf with: - setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} + setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} - uses: ./.github/actions/restore_heptools_boost with: - setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} + setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} - uses: ./.github/actions/restore_heptools_pythia8 with: - setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} + setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} - uses: ./.github/actions/restore_heptools_emela with: - setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} + setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} - uses: ./.github/actions/restore_heptools_contur with: - setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} + setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} - uses: ./.github/actions/restore_heptools_looptools with: - setup_only: ${{ runner.environment == 'self-hosted' || (steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true') }} + setup_only: ${{ steps.heptools-cache.outputs.cache-matched-key != '' && steps.validate-cache.outputs.valid == 'true' }} diff --git a/.github/actions/restore_heptools_contur/action.yml b/.github/actions/restore_heptools_contur/action.yml index 88520df3ad..de42f53f9c 100644 --- a/.github/actions/restore_heptools_contur/action.yml +++ b/.github/actions/restore_heptools_contur/action.yml @@ -33,10 +33,10 @@ runs: - run: | cd $GITHUB_WORKSPACE - echo "hepmc3_path = $HOME/.cache/HEPtools/hepmc3" >> input/mg7_configuration.txt - echo "rivet_path = $HOME/.cache/HEPtools/rivet" >> input/mg7_configuration.txt - echo "yoda_path = $HOME/.cache/HEPtools/yoda" >> input/mg7_configuration.txt - echo "contur_path = $HOME/.cache/HEPtools/contur" >> input/mg7_configuration.txt + echo "hepmc3_path = /home/runner/.cache/HEPtools/hepmc3" >> input/mg7_configuration.txt + echo "rivet_path = /home/runner/.cache/HEPtools/rivet" >> input/mg7_configuration.txt + echo "yoda_path = /home/runner/.cache/HEPtools/yoda" >> input/mg7_configuration.txt + echo "contur_path = /home/runner/.cache/HEPtools/contur" >> input/mg7_configuration.txt # Only point MG5 at fastjet if it is really there. The cache restore # above is best-effort (fail-on-cache-miss is false, and warm_cache # deletes the contur/heptools caches ~30 min before it re-saves them, @@ -46,7 +46,7 @@ runs: # fastjet/ClusterSequence.hh. Without the line MG5 uses fjcore, which # is a working fallback: the contur/rivet jobs still fail, loudly and on # their own, but the numbered acceptance jobs no longer fail with them. - FJ=$HOME/.cache/HEPtools/fastjet/bin/fastjet-config + FJ=/home/runner/.cache/HEPtools/fastjet/bin/fastjet-config if [ -x "$FJ" ]; then echo "fastjet = $FJ" >> input/mg7_configuration.txt else @@ -57,24 +57,11 @@ runs: - name: set pythonpath for ubuntu22 if: ${{ env.HEPTOOLS_IMAGE == 'ubuntu22' }} run: | - echo "PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/contur/python3.10/:$HOME/.cache/HEPtools/rivet/python3.10/:$HOME/.cache/HEPtools/rivet/local/python3.10/" >> $GITHUB_ENV + echo "PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/contur/python3.10/:/home/runner/.cache/HEPtools/rivet/python3.10/:/home/runner/.cache/HEPtools/rivet/local/python3.10/" >> $GITHUB_ENV shell: bash - name: set pythonpath for ubuntu24 if: ${{ env.HEPTOOLS_IMAGE == 'ubuntu24' }} run: | - echo "PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/contur/python3.12/:$HOME/.cache/HEPtools/rivet/python3.12/:$HOME/.cache/HEPtools/rivet/local/python3.10/" >> $GITHUB_ENV - shell: bash - # any other image (a self-hosted runner, where ImageOS is unset): take the - # python modules wherever this machine's build put them - - name: set pythonpath for other images - if: ${{ env.HEPTOOLS_IMAGE != 'ubuntu22' && env.HEPTOOLS_IMAGE != 'ubuntu24' }} - run: | - P=$PYTHONPATH - for d in $HOME/.cache/HEPtools/contur/python3* $HOME/.cache/HEPtools/rivet/python3* \ - $HOME/.cache/HEPtools/rivet/local/python3* \ - $HOME/.cache/HEPtools/{rivet,yoda}/{,local/}lib*/python3*/*-packages; do - [ -d "$d" ] && P=$P:$d - done - echo "PYTHONPATH=$P" >> $GITHUB_ENV + echo "PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/contur/python3.12/:/home/runner/.cache/HEPtools/rivet/python3.12/:/home/runner/.cache/HEPtools/rivet/local/python3.10/" >> $GITHUB_ENV shell: bash diff --git a/.github/actions/restore_heptools_emela/action.yml b/.github/actions/restore_heptools_emela/action.yml index 3e0a19043c..5df5ee0645 100644 --- a/.github/actions/restore_heptools_emela/action.yml +++ b/.github/actions/restore_heptools_emela/action.yml @@ -34,5 +34,5 @@ runs: - run: | cd $GITHUB_WORKSPACE - echo "eMELA = $HOME/.cache/HEPtools/bin/eMELA-config" >> input/mg7_configuration.txt + echo "eMELA = /home/runner/.cache/HEPtools/bin/eMELA-config" >> input/mg7_configuration.txt shell: bash diff --git a/.github/actions/restore_heptools_lhapdf/action.yml b/.github/actions/restore_heptools_lhapdf/action.yml index e000605641..83b0379839 100644 --- a/.github/actions/restore_heptools_lhapdf/action.yml +++ b/.github/actions/restore_heptools_lhapdf/action.yml @@ -36,23 +36,23 @@ runs: - run: | cd $GITHUB_WORKSPACE - echo "heptools_install_dir=$HOME/.cache/HEPtools" >> input/mg7_configuration.txt - echo "lhapdf = $HOME/.cache/HEPtools/bin/lhapdf-config" >> input/mg7_configuration.txt - echo "lhapdf_py3 = $HOME/.cache/HEPtools/bin/lhapdf-config" >> input/mg7_configuration.txt - echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPtools/lhapdf6_py3//lib" >> $GITHUB_ENV - echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPtools/lib" >> $GITHUB_ENV + echo "heptools_install_dir=/home/runner/.cache/HEPtools" >> input/mg7_configuration.txt + echo "lhapdf = /home/runner/.cache/HEPtools/bin/lhapdf-config" >> input/mg7_configuration.txt + echo "lhapdf_py3 = /home/runner/.cache/HEPtools/bin/lhapdf-config" >> input/mg7_configuration.txt + echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPtools/lhapdf6_py3//lib" >> $GITHUB_ENV + echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPtools/lib" >> $GITHUB_ENV shell: bash - name: set pythonpath for ubuntu22 if: ${{ env.HEPTOOLS_IMAGE == 'ubuntu22' }} run: | - echo "PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/lhapdf6_py3/lib/python3.10/dist-packages" >> $GITHUB_ENV + echo "PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/lhapdf6_py3/lib/python3.10/dist-packages" >> $GITHUB_ENV shell: bash - name: set pythonpath for ubuntu24 if: ${{ env.HEPTOOLS_IMAGE == 'ubuntu24' }} run: | - echo "PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/lhapdf6_py3/lib/python3.12/dist-packages" >> $GITHUB_ENV + echo "PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/lhapdf6_py3/lib/python3.12/dist-packages" >> $GITHUB_ENV shell: bash # The run_card default PDF sets: NNPDF40_lo_as_01180 (mg7 [beam] pdf and the @@ -63,20 +63,9 @@ runs: # on the set being present and would all self-skip (test_manager.py counts a # skip as a failure). Fetching them here is a no-op once the cache carries # them. Non-fatal on failure: the tests skip as they did before. - # any other image (a self-hosted runner, where ImageOS is unset): take the - # python bindings wherever this machine's build put them - - name: set pythonpath for other images - if: ${{ env.HEPTOOLS_IMAGE != 'ubuntu22' && env.HEPTOOLS_IMAGE != 'ubuntu24' }} - run: | - P=$PYTHONPATH - for d in $HOME/.cache/HEPtools/lhapdf6_py3/lib*/python3*/*-packages; do - [ -d "$d" ] && P=$P:$d - done - echo "PYTHONPATH=$P" >> $GITHUB_ENV - shell: bash - name: ensure the default PDF sets are present run: | - DATADIR=$HOME/.cache/HEPtools/lhapdf6_py3/share/LHAPDF + DATADIR=/home/runner/.cache/HEPtools/lhapdf6_py3/share/LHAPDF for SET in NNPDF40_lo_as_01180 NNPDF40_nlo_as_01180 NNPDF40_nlo_as_01180_nf_4; do if [ -d "$DATADIR" ] && [ ! -d "$DATADIR/$SET" ]; then ( cd "$DATADIR" \ diff --git a/.github/actions/restore_heptools_looptools/action.yml b/.github/actions/restore_heptools_looptools/action.yml index 7d7dddde44..157d381b32 100644 --- a/.github/actions/restore_heptools_looptools/action.yml +++ b/.github/actions/restore_heptools_looptools/action.yml @@ -28,6 +28,6 @@ runs: # this ignore cuttools/iregi cache ... ok but we should try to fix that - run: | cd $GITHUB_WORKSPACE - echo "ninja = $HOME/.cache/HEPtools/ninja/lib" >> input/mg7_configuration.txt - echo "collier = $HOME/.cache/HEPtools/collier" >> input/mg7_configuration.txt + echo "ninja = /home/runner/.cache/HEPtools/ninja/lib" >> input/mg7_configuration.txt + echo "collier = /home/runner/.cache/HEPtools/collier" >> input/mg7_configuration.txt shell: bash diff --git a/.github/actions/restore_heptools_pythia8/action.yml b/.github/actions/restore_heptools_pythia8/action.yml index 921c7570c8..1b01937b07 100644 --- a/.github/actions/restore_heptools_pythia8/action.yml +++ b/.github/actions/restore_heptools_pythia8/action.yml @@ -34,6 +34,6 @@ runs: - run: | cd $GITHUB_WORKSPACE - echo "pythia8_path = $HOME/.cache/HEPtools/pythia8" >> input/mg7_configuration.txt - echo "hepmc_path = $HOME/.cache/HEPtools/hepmc" >> input/mg7_configuration.txt + echo "pythia8_path = /home/runner/.cache/HEPtools/pythia8" >> input/mg7_configuration.txt + echo "hepmc_path = /home/runner/.cache/HEPtools/hepmc" >> input/mg7_configuration.txt shell: bash diff --git a/.github/actions/selfhosted_heptools/action.yml b/.github/actions/selfhosted_heptools/action.yml deleted file mode 100644 index 16d3e674d5..0000000000 --- a/.github/actions/selfhosted_heptools/action.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: Build HEPTools on a self-hosted runner -description: > - A self-hosted runner keeps ~/.cache/HEPtools on its own disk from one job to - the next, so instead of the GitHub caches (built by warm_cache.yml on, and - with paths baked in for, the ubuntu image) each machine builds the missing - components itself, once, the first time a job needs them. A component that - fails to build only warns: the tests that need it then fail, the others run. -inputs: - tools: - description: 'Components to build when missing, among lhapdf boost pythia8 emela contur looptools' - required: false - default: 'lhapdf boost pythia8 emela contur looptools' -runs: - using: composite - steps: - - name: Build the missing HEPTools components - shell: bash - env: - HEPTOOLS_BUILD: ${{ inputs.tools }} - run: bash "${{ github.action_path }}/build_heptools.sh" $HEPTOOLS_BUILD diff --git a/.github/actions/selfhosted_heptools/build_heptools.sh b/.github/actions/selfhosted_heptools/build_heptools.sh deleted file mode 100755 index 3f6da3855a..0000000000 --- a/.github/actions/selfhosted_heptools/build_heptools.sh +++ /dev/null @@ -1,85 +0,0 @@ -#!/usr/bin/env bash -# usage: build_heptools.sh [component ...] (default: all of them) -# Build into ~/.cache/HEPtools every requested HEPTools component that check_heptools -# does not find complete there, with the same install commands as the -# warm_cache.yml jobs. Runs from a pristine copy of the checked-out tree, so -# the job's own tree is left as checked out. -set -u -HEP="$HOME/.cache/HEPtools" -CHECK="$GITHUB_WORKSPACE/.github/actions/check_heptools/check_heptools.sh" -# The self-hosted machines are short on memory (a -j$(nproc) rivet build got -# the runner service OOM-killed): one compile per 2 GB available, at most one -# per core. -avail_gb=$(awk '/^MemAvailable:/ {print int($2 / 1048576)}' /proc/meminfo) -jobs=$(( avail_gb / 2 )) -[ "$jobs" -gt "$(nproc)" ] && jobs=$(nproc) -[ "$jobs" -lt 1 ] && jobs=1 -export MAKEFLAGS="-j$jobs" -echo "building with $MAKEFLAGS (${avail_gb} GB available, $(nproc) cores)" -mkdir -p "$HEP" - -# one build at a time per machine, should several runners share this home -exec 9> "$HEP.lock" -flock 9 - -complete() { - HEPTOOLS_PREFIX="$HEP" CHECK_MODE=fatal GITHUB_OUTPUT= bash "$CHECK" "$1" > /dev/null 2>&1 -} - -SRC="" -prepare_src() { - [ -n "$SRC" ] && return - SRC=$(mktemp -d "${RUNNER_TEMP:-/tmp}/heptools-src.XXXXXX") - git -C "$GITHUB_WORKSPACE" archive HEAD | tar -x -C "$SRC" - cp "$SRC/input/.mg7_configuration_default.txt" "$SRC/input/mg7_configuration.txt" - echo "heptools_install_dir=$HEP" >> "$SRC/input/mg7_configuration.txt" - cp "$SRC/Template/LO/Source/.make_opts" "$SRC/Template/LO/Source/make_opts" -} - -mg_install() { - printf '%s\n' "$@" > "$SRC/cmd" - (cd "$SRC" && ./bin/madgraph cmd) -} - -build_lhapdf() { - mg_install "install lhapdf6" - cd "$HEP/lhapdf6_py3/share/LHAPDF" || return 1 - for SET in NNPDF23_nlo_as_0118_qed cteq6l1 NNPDF40_lo_as_01180 NNPDF40_nlo_as_01180 \ - NNPDF40_nlo_as_01180_nf_4 NNPDF40MC_lo_as_01180 NNPDF23_lo_as_0130_qed; do - [ -d "$SET" ] && continue - wget -q "https://lhapdfsets.web.cern.ch/current/$SET.tar.gz" \ - && tar -xzpf "$SET.tar.gz" && rm -f "$SET.tar.gz" - done -} -build_boost() { mg_install "install boost"; } -build_pythia8() { mg_install "install pythia8"; } -build_emela() { mg_install "install eMELA"; } -build_contur() { mg_install "install rivet" "install contur"; } -build_looptools() { - # serial: the IREGI/CutTools makefiles do not declare their Fortran module - # dependencies, so a parallel make fails on a missing .mod - (cd "$SRC/vendor/IREGI/src" && MAKEFLAGS= make) || return 1 - (cd "$SRC/vendor/CutTools" && MAKEFLAGS= make) || return 1 - mkdir -p "$HEP/IREGI/src" "$HEP/CutTools/lib" - cp "$SRC/vendor/IREGI/src/libiregi.a" "$HEP/IREGI/src/" - cp "$SRC/vendor/CutTools/includects/libcts.a" "$SRC/vendor/CutTools/includects/mpmodule.mod" "$HEP/CutTools/lib" - mg_install "install collier" "install ninja" -} - -# dependency order: emela needs boost, contur needs pythia8 (hepmc) -requested=" ${*:-lhapdf boost pythia8 emela contur looptools} " -for tool in lhapdf boost pythia8 emela contur looptools; do - [[ "$requested" == *" $tool "* ]] || continue - if complete "$tool"; then - echo "$tool: already built on $RUNNER_NAME" - continue - fi - echo "::group::building $tool on $RUNNER_NAME (first use on this machine)" - prepare_src - ( "build_$tool" ) - echo "::endgroup::" - complete "$tool" || echo "::warning::HEPTools $tool could not be built on $RUNNER_NAME" -done - -[ -n "$SRC" ] && rm -rf "$SRC" -exit 0 diff --git a/.github/workflows/acceptancetest_madevent.yml b/.github/workflows/acceptancetest_madevent.yml index 64edc413d1..68164e7016 100644 --- a/.github/workflows/acceptancetest_madevent.yml +++ b/.github/workflows/acceptancetest_madevent.yml @@ -94,7 +94,7 @@ jobs: if: ${{ !cancelled() }} run: | #./tests/test_manager.py test_contur_from_file test_rivet_from_file -pA -t0 -l INFO - PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/contur/python3.10:$HOME/.cache/HEPTools/rivet/local/lib/python3.10/dist-packages/:$HOME/.cache/HEPTools/yoda/local/lib/python3.10/dist-packages/ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPTools/lib ./tests/test_manager.py test_rivet_from_file -pA -t0 -l INFO + PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/contur/python3.10:/home/runner/.cache/HEPTools/rivet/local/lib/python3.10/dist-packages/:/home/runner/.cache/HEPTools/yoda/local/lib/python3.10/dist-packages/ LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPTools/lib ./tests/test_manager.py test_rivet_from_file -pA -t0 -l INFO # ---- acceptancetest_60 ---- - name: "acceptancetest_60" @@ -257,18 +257,12 @@ jobs: # acceptancetest_24 acceptancetest_38 acceptancetest_45 acceptancetest_47 # acceptancetest_56 acceptancetest_density_ttbar # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore_heptools - # only what these tests need: rivet/contur and the loop libraries are - # not built on the (small) self-hosted machines - with: - selfhosted_tools: lhapdf boost pythia8 emela - uses: ./.github/actions/restore-pip-cache # ---- acceptancetest_20 ---- @@ -332,19 +326,13 @@ jobs: # former jobs, run one after the other: acceptancetest_37 acceptancetest_52 # acceptancetest_density_interface # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore-pip-cache - uses: ./.github/actions/restore_heptools - # only what these tests need: rivet/contur and the loop libraries are - # not built on the (small) self-hosted machines - with: - selfhosted_tools: lhapdf boost pythia8 emela # ---- acceptancetest_37 ---- - name: "acceptancetest_37" @@ -454,7 +442,7 @@ jobs: - name: "acceptancetest_contur2: run the test" if: ${{ !cancelled() }} run: | - PYTHONPATH=$PYTHONPATH:$HOME/.cache/HEPtools/contur/python3.10 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPTools/lib ./tests/test_manager.py test_rivet_from_file -pA -t0 -l INFO + PYTHONPATH=$PYTHONPATH:/home/runner/.cache/HEPtools/contur/python3.10 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPTools/lib ./tests/test_manager.py test_rivet_from_file -pA -t0 -l INFO # ---- acceptancetest_density_tttbartbar ---- - name: "acceptancetest_density_tttbartbar" @@ -472,18 +460,12 @@ jobs: # former jobs, run one after the other: acceptancetest_48 # acceptancetest_heft acceptancetest_madevent_flavor_zud # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore_heptools - # only what these tests need: rivet/contur and the loop libraries are - # not built on the (small) self-hosted machines - with: - selfhosted_tools: lhapdf boost pythia8 emela # ---- acceptancetest_48 ---- - name: "acceptancetest_48" @@ -512,9 +494,7 @@ jobs: acceptancetest_53: # The type of runner that the job will run on - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true # Steps represent a sequence of tasks that will be executed as part of the job @@ -523,10 +503,6 @@ jobs: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore_heptools - # only what these tests need: rivet/contur and the loop libraries are - # not built on the (small) self-hosted machines - with: - selfhosted_tools: lhapdf boost pythia8 emela - uses: ./.github/actions/restore-pip-cache - uses: ./.github/actions/restore_ufomodel @@ -561,7 +537,7 @@ jobs: - name: test one of the test test_loop_improved_reweighting run: | cd $GITHUB_WORKSPACE - export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPtools/lhapdf6_py3/lib + export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPtools/lhapdf6_py3/lib export PYTHONPATH=$PYTHONPATH:~/.cache/HEPtools/lhapdf6_py3/lib/python3.12/dist-packages export PYTHONPATH=$PYTHONPATH:~/.cache/HEPtools/lhapdf6_py3/lib/python3.10/dist-packages ./tests/test_manager.py test_nlo_reweighting -pA -t0 -l INFO @@ -571,7 +547,7 @@ jobs: if: ${{ !cancelled() }} run: | cd $GITHUB_WORKSPACE - export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.cache/HEPtools/lhapdf6_py3/lib + export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/runner/.cache/HEPtools/lhapdf6_py3/lib export PYTHONPATH=$PYTHONPATH:~/.cache/HEPtools/lhapdf6_py3/lib/python3.12/dist-packages export PYTHONPATH=$PYTHONPATH:~/.cache/HEPtools/lhapdf6_py3/lib/python3.10/dist-packages ./tests/test_manager.py test_nlo_reweighting_new_parameter -pA -t0 -l INFO @@ -587,18 +563,12 @@ jobs: # former jobs, run one after the other: acceptancetest_103_polarization # acceptancetest_flavor acceptancetest_madevent_vbf_merged_flavor # Each keeps its own steps, run even when an earlier one failed. - # Runs on the self-hosted alma10 runners (cern1, ...) to spare the hosted queue; - # fork PRs stay on ubuntu-24.04 so outside code never runs on our machines. - runs-on: ${{ github.event.pull_request.head.repo.fork && 'ubuntu-24.04' || fromJSON('["self-hosted", "alma10"]') }} + runs-on: ubuntu-24.04 if: github.event_name == 'push' || github.event.pull_request.head.repo.fork == true steps: - uses: actions/checkout@v4 - uses: ./.github/actions/checkout_mg5 - uses: ./.github/actions/restore_heptools - # only what these tests need: rivet/contur and the loop libraries are - # not built on the (small) self-hosted machines - with: - selfhosted_tools: lhapdf boost pythia8 emela # ---- acceptancetest_103_polarization ---- - name: "acceptancetest_103_polarization"