Repository navigation
Commit d3d5171
authored
fix(e2e): parse swap rows from GitHub runners (#7329)
<!-- markdownlint-disable MD041 -->
## Summary
Fix the Hermes rebuild swap probes so they accept the five-column
`swapon` rows returned by GitHub Actions runners. Before this change,
both probes reported healthy swap as zero; now they read the `SIZE`
field while preserving digit-only output support.
## Changes
- Parse digit-only `SIZE` output and validated `NAME TYPE SIZE USED
PRIO` runner rows.
- Add a regression test with the exact pre-provision and post-provision
row shapes from the failed release gate.
- Reject unrelated five-field output so diagnostics cannot bypass swap
provisioning.
- Record the escaped-defect cause: the parser assumed `--output SIZE`
always produced one column, and the test covered only that assumed
output.
## Type of Change
- [x] Code change (feature, bug fix, or refactor)
- [ ] Code change with doc updates
- [ ] Doc only (prose changes, no code sample modifications)
- [ ] Doc only (includes code sample changes)
## Quality Gates
- [x] Tests added or updated for changed behavior
- [ ] Existing tests cover changed behavior — justification:
- [ ] Tests not applicable — justification:
- [ ] Docs updated for user-facing behavior changes
- [x] Docs not applicable — justification: This change only affects
internal E2E release-validation infrastructure.
- [ ] Sensitive paths changed (security, policy, credentials, preflight,
onboarding, inference, runner, sandbox, or messaging)
- [ ] Sensitive-path review completed or maintainer-approved waiver
recorded — reviewer/approval link/justification:
- [ ] Non-success, skipped, or missing CI check accepted by maintainer —
check name, approval link, and follow-up issue:
## DGX Station Hardware Evidence
- [ ] Tested on DGX Station
- Tested commit: not applicable
- Station profile/scenario: not applicable
- Result: not applicable
- Supporting evidence: not applicable
## Verification
- [x] PR description includes a `Signed-off-by:` line and every commit
appears as `Verified` in GitHub
- [x] Normal `pre-commit`, `commit-msg`, and `pre-push` hooks passed, or
`npm run check:diff` passed when hooks were skipped or unavailable
- [x] Targeted behavior tests pass for the current change set, or tests
are marked not applicable above — `npx vitest run --project e2e-support
test/e2e/support/hermes-rebuild-swap.test.ts` (5 passed)
- [ ] Applicable broad gate passed — not applicable to this focused
helper change. A complete E2E-support run passed 1,273 tests; six
unrelated macOS time-out or fixture failures remain outside the changed
files.
- [x] Quality Gates section completed with required justifications or
waivers
- [x] No secrets, API keys, or credentials committed
- [ ] `npm run docs` builds without warnings (doc changes only)
- [ ] Doc pages follow the [style
guide](https://github.com/NVIDIA/NemoClaw/blob/main/docs/CONTRIBUTING.md)
(doc changes only)
- [ ] New doc pages include SPDX header and frontmatter (new pages only)
---
Signed-off-by: Julie Yaunches <[email protected]>
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* **Bug Fixes**
* Improved parsing of active swap information from multi-line
runner-style output, including handling file/partition rows and
descriptive columns.
* More reliably totals swap sizes and safely ignores unrelated rows,
improving swap-related decision behavior.
* **Tests**
* Added end-to-end test cases covering varied swap row formats and
validation of the summed total.
* Added coverage for ignoring irrelevant output and ensuring the rebuild
condition triggers appropriately.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->1 parent 5814d19 commit d3d5171
2 files changed
Lines changed: 26 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
13 | | - | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
14 | 22 | | |
15 | 23 | | |
16 | 24 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
18 | 34 | | |
19 | 35 | | |
20 | 36 | | |
| |||
0 commit comments