Skip to content

Commit 7981eb8

Browse files
committed
ci: run hw-coord on per-node runners; source Vivado settings64.sh
Previously hw-coord ran on the coordinator host (lbvm), but lbvm doesn't have Vivado installed. XSA-pipeline tests that depend on `sdtgen` therefore pytest-skipped silently — the matrix looked green but tests weren't actually exercising any XSA logic on bq/mini2. Relocate hw-coord to the per-node self-hosted runners (same `hw-<place>` label as hw-direct), where Vivado 2025.1 is available at /tools/Xilinx/2025.1/. Source settings64.sh before pytest in both hw-direct and hw-coord so sdtgen / xsct / xsdb are on PATH regardless of the runner service's login-shell setup. Use labgrid-client from the per-node adidt-venv (labgrid is a transitive dep) so we don't need a separate labgrid-venv on each runner. The hw-coordinator runner now only carries the preflight job.
1 parent b824416 commit 7981eb8

2 files changed

Lines changed: 28 additions & 6 deletions

File tree

.github/workflows/hardware-test.yml

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,10 @@ jobs:
140140
if: steps.check_direct_env.outputs.skip != 'true'
141141
run: |
142142
set -euo pipefail
143+
if [ -f /tools/Xilinx/2025.1/Vivado/settings64.sh ]; then
144+
# shellcheck disable=SC1091
145+
source /tools/Xilinx/2025.1/Vivado/settings64.sh
146+
fi
143147
export LG_ENV="$LG_DIRECT_ENV"
144148
"$HOME/.cache/adidt-ci/adidt-venv/bin/pytest" \
145149
-p no:genalyzer -v -s ${{ join(matrix.node.tests, ' ') }}
@@ -152,7 +156,11 @@ jobs:
152156
matrix:
153157
node: ${{ fromJSON(needs.preflight.outputs.available_nodes) }}
154158
name: hw-coord (${{ matrix.node.place }})
155-
runs-on: [self-hosted, hw-coordinator]
159+
# Run on the per-node runner (same label as hw-direct) so the
160+
# Xilinx toolchain (sdtgen, xsct) available there can drive the
161+
# XSA pipeline. The coordinator host (lbvm) lacks Vivado, so
162+
# running pytest there silently skips every XSA-dependent test.
163+
runs-on: [self-hosted, "${{ matrix.node.runner_label }}"]
156164
timeout-minutes: 40
157165
concurrency:
158166
group: hw-coord-${{ matrix.node.place }}
@@ -180,7 +188,9 @@ jobs:
180188
LG_COORDINATOR: ${{ env.COORDINATOR }}
181189
run: |
182190
set -euo pipefail
183-
LGCLIENT="$HOME/.cache/adidt-ci/labgrid-venv/bin/labgrid-client"
191+
# labgrid-client is a transitive dep of adidt's dev extras,
192+
# so it lands in the per-node adidt-venv.
193+
LGCLIENT="$HOME/.cache/adidt-ci/adidt-venv/bin/labgrid-client"
184194
"$LGCLIENT" -x "$LG_COORDINATOR" -p "${{ matrix.node.place }}" acquire
185195
186196
- name: Run coordinator-mode tests
@@ -189,6 +199,12 @@ jobs:
189199
LG_ENV: ${{ github.workspace }}/${{ matrix.node.env_remote }}
190200
run: |
191201
set -euo pipefail
202+
# Source Vivado settings so sdtgen / xsct / xsdb are on PATH
203+
# for XSA-pipeline tests.
204+
if [ -f /tools/Xilinx/2025.1/Vivado/settings64.sh ]; then
205+
# shellcheck disable=SC1091
206+
source /tools/Xilinx/2025.1/Vivado/settings64.sh
207+
fi
192208
"$HOME/.cache/adidt-ci/adidt-venv/bin/pytest" \
193209
-p no:genalyzer -v -s ${{ join(matrix.node.tests, ' ') }}
194210
@@ -198,5 +214,5 @@ jobs:
198214
LG_COORDINATOR: ${{ env.COORDINATOR }}
199215
run: |
200216
set -euo pipefail
201-
LGCLIENT="$HOME/.cache/adidt-ci/labgrid-venv/bin/labgrid-client"
217+
LGCLIENT="$HOME/.cache/adidt-ci/adidt-venv/bin/labgrid-client"
202218
"$LGCLIENT" -x "$LG_COORDINATOR" -p "${{ matrix.node.place }}" release || true

doc/source/developer/hardware_ci.rst

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,15 @@ The workflow has three jobs:
2828
``LG_DIRECT_ENV`` is unset on a runner the job skips all work and
2929
exits green — add the env entry in ``~/actions-runner/.env`` to
3030
light up direct-mode on that node.
31-
- **hw-coord** — a matrix job, one leg per available node, all
32-
running on the single ``hw-coordinator`` runner. Each leg uses the
33-
committed ``env_remote_<place>.yaml`` that the manifest declares.
31+
- **hw-coord** — a matrix job, one leg per available node, running
32+
on the **same per-node runner as hw-direct** (label
33+
``hw-<place>``). Each leg uses the committed
34+
``env_remote_<place>.yaml`` from the manifest and talks to the
35+
labgrid coordinator via ``LG_COORDINATOR`` — so pytest exercises
36+
the coordinator code path while the XSA toolchain (Vivado's
37+
sdtgen, xsct) and kernel build artifacts already present on the
38+
per-node runner are used in place. The ``hw-coordinator`` runner
39+
itself carries only the preflight job.
3440

3541
Fork-PR protection is handled by GitHub Actions' built-in workflow
3642
approval gate rather than a custom ``environment:``. Under *Settings

0 commit comments

Comments
 (0)