Skip to content

perf(e2e): skip disposable Hermes rebuild sandbox - #7590

Merged
jyaunches merged 17 commits into
mainfrom
codex/7144-rebuild-hermes-bootstrap
Jul 29, 2026
Merged

perf(e2e): skip disposable Hermes rebuild sandbox#7590
jyaunches merged 17 commits into
mainfrom
codex/7144-rebuild-hermes-bootstrap

Conversation

@apurvvkumaria

@apurvvkumaria apurvvkumaria commented Jul 26, 2026

Copy link
Copy Markdown
Collaborator

Summary

The rebuild-Hermes lanes now prepare the published current base, trusted gateway, hosted inference route, and dashboard port directly instead of onboarding and deleting a disposable current-Hermes sandbox. This removes one generated image build and its high-memory export while preserving the real historical-to-current rebuild and state-migration assertions.

The branch is refreshed onto exact main SHA c4c020ca5 after benchmark prerequisites #7571, #7580, #7582, #7586, and #7589 merged. Their changes collapse out of the PR diff; the remaining five changed files are limited to test/e2e/**.

Related Issue

Part of #7144
Parent epic: #7140

Changes

  • Resolve Hermes through production ensureAgentBaseImage, require the published immutable metadata, and fail if the lane constructs or overrides a base.
  • Start the nemoclaw gateway through the production recovery path, configure the exact compatible-endpoint route, and allocate the dashboard port through the production allocator.
  • Keep the real rebuild credentialless and retain old-base provenance, backup/restore, messaging placeholders, token rotation, final image identity, readiness, and inference validation.
  • Preserve the existing eight-phase contract with truthful setup wording and consistently numbered artifacts.
  • List forward ownership before cleanup and use sandbox-scoped stops so a reused port cannot terminate another sandbox's forward.
  • Run exit-capable production bootstrap functions in captured child processes so failures cannot terminate the Vitest worker.
  • Use the workflow-selected absolute OpenShell executable for every provider, readiness, sandbox, and validation operation so PATH drift cannot split the lane across binaries.
  • Record malformed persisted dashboard-port state, attempt every known sandbox-owned forward even when one stop fails, write cleanup evidence, and only then propagate one or aggregated cleanup failures.

Type of Change

  • 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

  • Tests added or updated for changed behavior
  • Existing tests cover changed behavior — justification:
  • Tests not applicable — justification:
  • Docs updated for user-facing behavior changes
  • Docs not applicable — justification: the diff only changes internal live-E2E orchestration and exposes no user-facing command, configuration, runtime default, or output.
  • 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: independent Codex maintainers reviewed the full exact diff through signed/Verified head c067fb6ce for credentials, gateway authority, immutable base identity, cleanup ownership, dashboard allocation, deterministic failure aggregation, evidence preservation, child-process failure propagation, and retained real rebuild/state/token/inference assertions. Final verdict: PASS with no findings.
  • Non-success, skipped, or missing CI check accepted by maintainer — check name, approval link, and follow-up issue:

Documentation Writer Review

  • Documentation writer subagent reviewed the completed changes
  • Result: no-docs-needed
  • Evidence: Exact diff c4c020ca5..c067fb6ce changes only test/e2e/** test infrastructure. No documentation paths or user-facing behavior changed. git diff --check passed.
  • Agent: Codex Desktop

DGX Station Hardware Evidence

  • Tested on DGX Station
  • Tested commit: not applicable
  • Station profile/scenario: not applicable
  • Result: not applicable; scripts/prepare-dgx-station-host.sh is unchanged.
  • Supporting evidence:

Verification

  • PR description includes a Signed-off-by: line and every pushed commit appears as Verified in GitHub
  • Normal pre-commit, commit-msg, and pre-push hooks passed, or npm run check:diff passed when hooks were skipped or unavailable
  • Targeted behavior tests pass for the current change set, or tests are marked not applicable above — the prepared current-main sync passed its 17/17 focused support tests; the prior broader exact suite passed all ten rebuild-Hermes support files (10 files, 63 tests), including the fail-closed markerless-bootstrap and all-forwards cleanup regressions.
  • Applicable broad gate passed — not applicable; this is scoped to one live target and its focused support contracts. A prior full local e2e-support attempt passed 154 files and hit nine unrelated macOS host/process timing failures outside the changed files.
  • Quality Gates section completed with required justifications or waivers
  • No secrets, API keys, or credentials committed
  • npm run docs builds without warnings (doc changes only)
  • Doc pages follow the style guide (doc changes only)
  • New doc pages include SPDX header and frontmatter (new pages only)

Additional validation on the refreshed head:

  • npm run test:e2e-phases:check
  • npm run typecheck:cli
  • npm run source-shape:check
  • npm run test-size:check
  • npm run test:titles:check
  • npm run test:projects:check
  • npm run test-conditionals:scan -- --top 25
  • npx prek run --from-ref origin/main --to-ref HEAD --stage pre-commit
  • npx prek run --from-ref origin/main --to-ref HEAD --stage pre-push

Five-run benchmark baseline:

  • Exact main SHA: 0b185498155a0a51a3f682a3e2b57f80c95eeaaa
  • Runner routing: E2E_LARGER_RUNNER_LABEL unset; standard ubuntu-latest, Linux/x64, 4 CPU, about 16 GB memory
  • Protocol: five sequential selective e2e.yaml dispatches; attempt 1 only; both lanes required to pass; zero Docker build cache at scenario start
Sample Workflow run Normal total Stale-base total
1 30241442305 322,906 ms 323,358 ms
2 30241954029 324,529 ms 324,778 ms
3 30242448958 321,993 ms 322,012 ms
4 30242980946 325,750 ms 327,602 ms
5 30243543432 323,497 ms 443,959 ms
Median 323,497 ms 324,778 ms

Median phase evidence:

  • Disposable current-Hermes onboard removed by this PR: normal 138,276 ms; stale-base 138,599 ms
  • Historical fixture pull: normal 46,237 ms; stale-base 50,446 ms
  • Historical sandbox creation: normal 27,257 ms; stale-base 31,883 ms
  • Actual Hermes rebuild retained by this PR: normal 90,521 ms; stale-base 80,321 ms
  • The removed onboard alone represents 42.7% of each baseline median. This identifies the expected gain but is not substituted for the required post-change measurement.

Resource evidence:

  • All ten lanes began with zero build cache, used zero swap, recorded zero memory-full PSI, passed semantic validation, uploaded artifacts, and completed cleanup without failures.
  • Peak BuildKit RSS ranged from 3,124,420 to 4,075,160 KiB while minimum available memory stayed at or above 10,371,420 KiB; the baseline does not show memory exhaustion.
  • Sample 5 stale-base is an I/O/runner-class outlier: its onboard phase took 256,419 ms on Intel Xeon 6973P-C with 40.84% peak I/O-full PSI. The outlier does not move the five-run median.

Remaining acceptance evidence:


Signed-off-by: Apurv Kumaria akumaria@nvidia.com

Summary by CodeRabbit

  • New Features
    • Added end-to-end helper coverage for rebuilding Hermes, including trusted current-base resolution and hosted inference gateway bootstrapping with readiness markers and bootstrap artifacts.
    • Introduced stricter validation for OpenShell selection, inference route/provider-model matching, and dashboard/forward port handling.
  • Bug Fixes
    • Improved error messaging when current-base evidence validation fails during rebuild.
  • Tests
    • Added a dedicated “rebuild Hermes direct bootstrap” e2e suite with marker, environment, routing, and cleanup assertions.
    • Updated the live rebuild e2e flow to use the dynamically selected OpenShell and enhanced forward-port tracking/cleanup behavior.

Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
@apurvvkumaria apurvvkumaria added integration: hermes Hermes integration behavior area: e2e End-to-end tests, nightly failures, or validation infrastructure area: performance Latency, throughput, resource use, benchmarks, or scaling v0.0.96 labels Jul 26, 2026
@apurvvkumaria apurvvkumaria self-assigned this Jul 26, 2026
@copy-pr-bot

copy-pr-bot Bot commented Jul 26, 2026

Copy link
Copy Markdown

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@coderabbitai

coderabbitai Bot commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

The PR adds Hermes current-base resolution and gateway bootstrap helpers, integrates them into the live rebuild workflow, parameterizes OpenShell execution, tracks dashboard forwards, validates hosted inference, and adds support tests and phase-contract updates.

Changes

Hermes rebuild workflow

Layer / File(s) Summary
Current base resolution and validation
test/e2e/live/rebuild-hermes-bootstrap.ts, test/e2e/live/rebuild-hermes-base-identity.ts, test/e2e/support/rebuild-hermes-bootstrap.test.ts
Current-base evidence is generated and parsed, published pinned identity is enforced, resolver environment overrides are rejected, and validation paths are tested.
Gateway and dashboard bootstrap
test/e2e/live/rebuild-hermes-bootstrap.ts, test/e2e/live/rebuild-hermes.test.ts, test/e2e/support/rebuild-hermes-bootstrap.test.ts
The reusable gateway is configured and its compatible-endpoint provider/model route and dashboard port are verified and recorded.
Forward cleanup and evidence tracking
test/e2e/live/rebuild-hermes-bootstrap.ts, test/e2e/live/rebuild-hermes.test.ts, test/e2e/support/rebuild-hermes-bootstrap.test.ts
Sandbox-owned forwards are tracked and cleaned up with rejected-port evidence and failure-ordering coverage.
Live workflow integration and regression coverage
test/e2e/live/rebuild-hermes.test.ts, test/e2e/live/rebuild-hermes-phases.ts, test/e2e/support/rebuild-hermes-bootstrap.test.ts
The live test uses the selected OpenShell binary across setup and rebuild phases, updates artifacts, and verifies the no-disposable-current-sandbox contract.

Estimated code review effort: 4 (Complex) | ~60 minutes

Sequence Diagram(s)

sequenceDiagram
  participant LiveTest
  participant CurrentBaseResolver
  participant HostCliClient
  participant NemoclawGateway
  LiveTest->>HostCliClient: Probe selected OpenShell binary
  LiveTest->>CurrentBaseResolver: Resolve published current base
  CurrentBaseResolver->>HostCliClient: Inspect resolved image
  LiveTest->>NemoclawGateway: Configure compatible-endpoint inference
  LiveTest->>HostCliClient: Verify route and dashboard forward
Loading

Possibly related issues

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the main change: skipping the disposable Hermes rebuild sandbox in the E2E flow.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/7144-rebuild-hermes-bootstrap

Comment @coderabbitai help to get the list of available commands.

@github-code-quality

github-code-quality Bot commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

Code Coverage Overview

Languages: TypeScript

TypeScript / code-coverage/plugin

The overall coverage in commit c067fb6 in the codex/7144-rebuild-h... branch remains at 96%, unchanged from commit cf34b72 in the main branch.

TypeScript / code-coverage/cli

The overall coverage in commit c067fb6 in the codex/7144-rebuild-h... branch remains at 81%, unchanged from commit c4c020c in the main branch.

Show a code coverage summary of the most impacted files.
File main c4c020c codex/7144-rebuild-h... c067fb6 +/-
src/lib/onboard...ndbox-create.ts 83% 33% -50%
src/lib/onboard...box-prebuild.ts 92% 74% -18%
src/lib/actions...ocker-health.ts 82% 65% -17%
src/lib/actions...confirmation.ts 79% 69% -10%
src/lib/onboard...ndbox-create.ts 91% 83% -8%
src/lib/actions...light-guards.ts 90% 86% -4%
src/lib/onboard/preflight.ts 80% 80% 0%
src/lib/onboard...shboard-port.ts 93% 96% +3%
src/lib/onboard...host-anchors.ts 90% 94% +4%
src/lib/onboard/docker-cdi.ts 70% 80% +10%

Updated July 28, 2026 22:04 UTC

@github-actions

github-actions Bot commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

PR Review Advisor — No blocking findings reported

Advisor assessment: No blocking advisor findings reported
Next action: No advisor follow-up needed.
Findings: 0 blockers · 0 warnings · 0 suggestions

Model lanes

  • GPT-5.6 Terra (primary): Completed · high confidence · 0 blockers · 0 warnings · 0 suggestions
  • Nemotron 3 Ultra (second opinion): Completed · high confidence · 0 blockers · 0 warnings · 0 suggestions
  • Model comparison: normalized findings match; normalized E2E selections differ; severity counts match.

Nemotron output stays in workflow artifacts and does not change the assessment above.

E2E guidance

Advisory only. E2E / PR Gate selects and runs jobs independently.

Recommended E2E: cloud-inference, cloud-onboard, security-posture, rebuild-hermes, rebuild-hermes-stale-base

Workflow run details

This automated review informs maintainers. Warnings and suggestions do not require a response. A maintainer decides whether to merge.

Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
…rmes-bootstrap-review

Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
Signed-off-by: Prekshi Vyas <prekshiv@nvidia.com>
ericksoa pushed a commit that referenced this pull request Jul 27, 2026
## Summary

GitHub may canonicalize a PR gate check details URL to the check own
/runs/<check-id> URL even when the exact child-bound summary is
persisted. The controller introduced by #7594 rejected that valid
response, revoked authorization, and prevented the selected #7590 Hermes
lanes from starting. This change accepts only the exact child URL or the
exact canonical check URL while preserving every authorization identity
check.

## Related Issue

Part of #7140. Follow-up to #7593 and #7594; aligns the parent
controller with the canonicalization behavior already protected by
#7515.

## Changes

- Accept the selected child Actions URL or the exact canonical
/runs/<check-id> URL after the check ID, GitHub Actions app, PR
head/base identity, status, title, and child-bound summary all validate.
- Continue rejecting foreign repositories, wrong check IDs, alternate
schemes, query or fragment variants, and unrelated URLs.
- Cover both allowed URL forms after a lost PATCH response and prove a
foreign canonical URL still revokes authorization before child
cancellation.

## 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: existing E2E operational
documentation already states that GitHub may canonicalize details_url to
/runs/<check-id>; no user-facing command or workflow changes.
- [x] Sensitive paths changed (security, policy, credentials, preflight,
onboarding, inference, runner, sandbox, or messaging)
- [x] Sensitive-path review completed or maintainer-approved waiver
recorded — reviewer/approval link/justification: independent Codex
Desktop code and security reviews verified the exact URL allowlist and
the retained check ID, app, PR/head/base, status, plan, jobs, targets,
and child-run summary binding; no findings remained.
- [ ] Non-success, skipped, or missing CI check accepted by maintainer —
check name, approval link, and follow-up issue:

## Documentation Writer Review

- [x] Documentation writer subagent reviewed the completed changes.
- Result: `no-docs-needed`
- Evidence: Exact head `d4f53a19618b4d810494e2094c6aff6b9f6602cc`
changes only the E2E controller’s canonical check-URL validation and
focused tests. `test/e2e/README.md` already documents direct-read
recovery, exact persisted child binding, and GitHub canonicalization to
`/runs/<check-id>`. Changed test text is behavior-oriented and
introduces no issue references. No docs build was needed because no
documentation source changed.
- Agent: Codex Desktop
<!-- docs-review-head-sha: d4f53a1 -->
<!-- docs-review-agents-blob-sha:
be20a09 -->

## DGX Station Hardware Evidence

- [ ] Tested on DGX Station
- Tested commit: not applicable
- Station profile/scenario: not applicable
- Result: not applicable; scripts/prepare-dgx-station-host.sh is
unchanged.
- Supporting evidence:

## 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 — 19 PR-E2E files, 313 tests passed; the
E2E workflow boundary added 39 passing tests.
- [x] Applicable broad gate passed — CLI typecheck, source-shape,
test-size, title-style, project isolation, Biome, and the complete
changed-file hook set passed. Post-rebase focused validation passed 41
tests.
- [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 (doc changes only)
- [ ] New doc pages include SPDX header and frontmatter (new doc pages
only)

Failure evidence: controller run 30221481816 and child run 30221620499.
The parent published the exact child-bound summary but GitHub returned
the canonical check URL, so the old strict URL comparison revoked the
otherwise valid authorization.

Self-hosting evidence: #7599 controller run 30224207359 checked out
trusted base `2f66902b`, rejected the canonical URL for check
89851619986, and could not cancel child run 30224558462 after GitHub
returned HTTP 500. The orphan child then failed closed because trusted
controller authorization had not been published. A same-revision retry
is not supported after dispatch; the exact fix requires the repository's
approved controller-bootstrap governance path.

---
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
* Improved pull request gate recovery when an authorization update
response is lost, ensuring check details URLs are set correctly after
retry behavior.
* Updated gate check validation to accept both dispatched child run URLs
and canonical controller check URLs.
* **Tests**
* Expanded end-to-end coverage with parameterized published-details URL
variants and scenarios where lost updates result in a foreign check URL.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
@apurvvkumaria
apurvvkumaria marked this pull request as ready for review July 27, 2026 21:51
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (2)
test/e2e/live/rebuild-hermes-bootstrap.ts (1)

403-419: 🩺 Stability & Availability | 🔵 Trivial | ⚡ Quick win

Cleanup aborts remaining forwards on the first failure.

The for loop rethrows immediately, so a failure on one tracked port (e.g. a transient forward list error) leaves the other tracked forwards running and leaks host ports across lanes. Collect per-port outcomes and throw once at the end so every tracked port gets a stop attempt.

♻️ Suggested failure isolation
   const rejectedPort = trackRebuildHermesCleanupPort(ports, recordedDashboardPort);
+  const failures: unknown[] = [];
   try {
     for (const port of ports) {
-      await cleanupForward(port);
+      try {
+        await cleanupForward(port);
+      } catch (error) {
+        failures.push(error);
+      }
     }
   } finally {
     await writeEvidence({ rejectedPort });
   }
+  if (failures.length > 0) {
+    throw new AggregateError(failures, "Hermes tracked forward cleanup failed");
+  }
 }
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@test/e2e/live/rebuild-hermes-bootstrap.ts` around lines 403 - 419, The
cleanupRebuildHermesTrackedForwards function must attempt cleanupForward for
every tracked port even when one attempt fails. Capture each per-port failure
while continuing the loop, then after all stop attempts and writeEvidence
completes, propagate the collected failure(s) once; preserve rejectedPort
evidence writing in the finally path.
test/e2e/support/rebuild-hermes-bootstrap.test.ts (1)

412-443: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Source-text and indexOf ordering assertions lock in the live test's implementation.

The negative assertions (Lines 415-419) reasonably prove the disposable-sandbox path is gone, but the positive toContain checks and the indexOf ordering comparisons (Lines 422-443) will break on any harmless refactor (renamed local, reordered artifact write, extracted helper) without indicating a real regression. Consider narrowing this test to the removal-proof assertions and expressing phase ordering through the phase contract (REBUILD_HERMES_PHASES / meta.e2ePhases) instead of the file's byte offsets.

As per path instructions, "Prefer observable outcomes through the public boundary over source-text, private-shape, or mock-call assertions" and "Migration tests must prove the superseded path is unreachable or removed, not merely prove that the new path also works."

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@test/e2e/support/rebuild-hermes-bootstrap.test.ts` around lines 412 - 443,
Refactor the assertions in the live rebuild test to retain only checks proving
the superseded disposable-sandbox and direct openshell paths are absent. Remove
brittle positive source-text checks and byte-offset comparisons based on local
names or statement order, and validate rebuild phase ordering through the public
phase contract using REBUILD_HERMES_PHASES or meta.e2ePhases instead.

Source: Path instructions

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@test/e2e/live/rebuild-hermes-bootstrap.ts`:
- Around line 403-419: The cleanupRebuildHermesTrackedForwards function must
attempt cleanupForward for every tracked port even when one attempt fails.
Capture each per-port failure while continuing the loop, then after all stop
attempts and writeEvidence completes, propagate the collected failure(s) once;
preserve rejectedPort evidence writing in the finally path.

In `@test/e2e/support/rebuild-hermes-bootstrap.test.ts`:
- Around line 412-443: Refactor the assertions in the live rebuild test to
retain only checks proving the superseded disposable-sandbox and direct
openshell paths are absent. Remove brittle positive source-text checks and
byte-offset comparisons based on local names or statement order, and validate
rebuild phase ordering through the public phase contract using
REBUILD_HERMES_PHASES or meta.e2ePhases instead.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: e34604d9-7b50-4afe-8ba7-55c95b2bb597

📥 Commits

Reviewing files that changed from the base of the PR and between f6b0c98 and 9e7e09f.

📒 Files selected for processing (5)
  • test/e2e/live/rebuild-hermes-base-identity.ts
  • test/e2e/live/rebuild-hermes-bootstrap.ts
  • test/e2e/live/rebuild-hermes-phases.ts
  • test/e2e/live/rebuild-hermes.test.ts
  • test/e2e/support/rebuild-hermes-bootstrap.test.ts

Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
test/e2e/support/rebuild-hermes-bootstrap.test.ts (1)

453-466: 🎯 Functional Correctness | 🔵 Trivial | 🏗️ Heavy lift

Replace source-text checks with behavior-level migration coverage.

These literal-fragment assertions can pass if a superseded onboarding or disposable-sandbox path is reintroduced under different names. Capture the live workflow’s executed probes/artifacts and prove those operations are unreachable while the rebuild completes its declared phases. As per path instructions, “Migration tests must prove the superseded path is unreachable or removed, not merely prove that the new path also works.”

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@test/e2e/support/rebuild-hermes-bootstrap.test.ts` around lines 453 - 466,
Replace the literal source-text assertions in the test “keeps superseded live
rebuild paths unreachable (`#7144`)” with behavior-level migration coverage:
capture executed probes or artifacts from the live rebuild workflow, assert the
superseded onboarding, disposable-sandbox cleanup, image-removal, forwarding,
and openshell operations are never executed, and verify the rebuild still
completes its declared phases.

Source: Path instructions

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@test/e2e/support/rebuild-hermes-bootstrap.test.ts`:
- Around line 453-466: Replace the literal source-text assertions in the test
“keeps superseded live rebuild paths unreachable (`#7144`)” with behavior-level
migration coverage: capture executed probes or artifacts from the live rebuild
workflow, assert the superseded onboarding, disposable-sandbox cleanup,
image-removal, forwarding, and openshell operations are never executed, and
verify the rebuild still completes its declared phases.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 4f2ca71f-cdc1-4a5e-a38a-472c945627a4

📥 Commits

Reviewing files that changed from the base of the PR and between ffda3c9 and 95c81d0.

📒 Files selected for processing (2)
  • test/e2e/live/rebuild-hermes-bootstrap.ts
  • test/e2e/support/rebuild-hermes-bootstrap.test.ts
🚧 Files skipped from review as they are similar to previous changes (1)
  • test/e2e/live/rebuild-hermes-bootstrap.ts

Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
cv pushed a commit that referenced this pull request Jul 28, 2026
<!-- markdownlint-disable MD041 -->
## Summary
<!-- 1-3 plain sentences: what changes and why. Describe
before-and-after behavior when it applies. Follow the NemoClaw Writing
Guide: https://github.com/NVIDIA/NemoClaw/blob/main/WRITING.md. Do not
add unrelated prose cleanup. -->
Replace the mutable NodeSource bootstrap in both WSL workflows with
checksum-verified official Node.js 22.23.1 archives. This removes the
shared installer failure affecting current PR lanes while keeping the
runtime on the supported, security-current Node 22 LTS line.

## Changes
<!-- List concrete changes. If this adds an abstraction, configuration,
fallback, migration, or compatibility path, name its current requirement
and consumer, explain why a direct change is insufficient, and identify
the test that protects it. -->
- Install official Node.js 22.23.1 archives for `x64` and `arm64`, with
exact SHA-256 pins, HTTPS-only bounded downloads, temporary-directory
cleanup, and fail-closed architecture handling.
- Verify each archive before extraction and assert the installed runtime
version.
- Protect both workflow consumers with
`test/platform-vitest-main-workflow.test.ts`, including
architecture-to-digest bindings and the repository's approved security
source-shape contract.
- Address the same WSL bootstrap failure observed on
[#7590](https://github.com/NVIDIA/NemoClaw/actions/runs/30312091098/job/90131121904),
[#7629](https://github.com/NVIDIA/NemoClaw/actions/runs/30311922489/job/90131122471),
[#7603](https://github.com/NVIDIA/NemoClaw/actions/runs/30311696352/job/90131123359),
and
[#7626](https://github.com/NVIDIA/NemoClaw/actions/runs/30312801807/job/90132378380).

## 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
<!-- Check one tests line and one docs line. Check other lines when
applicable. Add every requested justification or approval reference. -->
- [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 changes internal CI
bootstrap behavior only; public installation requirements remain
unchanged.
- [x] Sensitive paths changed (security, policy, credentials, preflight,
onboarding, inference, runner, sandbox, or messaging)
- [x] Sensitive-path review completed or maintainer-approved waiver
recorded — reviewer/approval link/justification: Codex security review
PASS across all nine categories on exact diff fingerprint
`2981cff1a79a0c0acfaf5b0a8e55353809ec472c0565fa1f168996f92107b7ae`.
- [ ] Non-success, skipped, or missing CI check accepted by maintainer —
check name, approval link, and follow-up issue:

## Documentation Writer Review
<!-- Required for code and documentation changes after the changes and
applicable validation are complete. Keep one review checkbox and one
instance of each visible or hidden field. For Evidence, list changed
documentation paths. For documentation-only changes, also state that the
writing rules and documentation style were reviewed. For other results,
explain why no documentation change is needed or why the review is
blocked. For Agent, use a consistent product and surface name, such as
Codex Desktop, Codex CLI, Claude Code, or Cursor. After committing all
review changes, put `git rev-parse --short HEAD` and `git rev-parse
--short HEAD:AGENTS.md` in the hidden metadata below. Rerun the review
and refresh that metadata after any new commit. This receipt is advisory
during the data-collection pilot. -->
- [x] Documentation writer subagent reviewed the completed changes
- Result: `no-docs-needed`
- Evidence: Exact-head review confirmed the change is limited to CI
bootstrap workflows and their executable contract; public Node.js
requirements do not change.
- Agent: Codex Desktop
<!-- docs-review-head-sha: 062779c -->
<!-- docs-review-agents-blob-sha: be20a09 -->

## DGX Station Hardware Evidence
<!-- Required only when scripts/prepare-dgx-station-host.sh changes.
Maintainers must review the linked evidence before approving or merging.
This is human-reviewed evidence, not authenticated hardware provenance.
Exceptional bypasses use existing repository governance and must be
documented on the PR. -->
- [ ] Tested on DGX Station
- Tested commit:
- Station profile/scenario:
- Result:
- Supporting evidence:

## Verification
<!-- Check each applicable item only when supported by the requested
evidence. Run targeted tests once per relevant change set and rerun
after later edits or hook autofixes that can affect the tested behavior.
Do not rerun hook-covered checks. -->
- [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 — command/result or justification: `npx
vitest run --project integration
test/platform-vitest-main-workflow.test.ts` (3 passed); both embedded
WSL installers pass `bash -n`.
- [ ] Applicable broad gate passed — `npm test` for broad
runtime/test-harness changes; `npm run check` for repo-wide
validation/coverage changes — command/result:
- [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)

---
<!-- DCO sign-off is required in this PR description, and every commit
must appear as Verified in GitHub. Run: git config user.name && git
config user.email -->
Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **CI Improvements**
* Standardized Node.js 22 installation across WSL workflows with a
pinned version and architecture-specific downloads.
* Added archive checksum verification, version validation, cleanup, and
explicit failure handling.

* **Tests**
* Added coverage to verify secure, deterministic Node.js installation
behavior in both WSL workflows.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Signed-off-by: Apurv Kumaria <akumaria@nvidia.com>
@jyaunches
jyaunches merged commit 19230e2 into main Jul 29, 2026
73 of 76 checks passed
@jyaunches
jyaunches deleted the codex/7144-rebuild-hermes-bootstrap branch July 29, 2026 13:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: e2e End-to-end tests, nightly failures, or validation infrastructure area: performance Latency, throughput, resource use, benchmarks, or scaling integration: hermes Hermes integration behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants