Skip to content

fix(installer): preserve Station Express recipe across host handoff#7204

Merged
jyaunches merged 6 commits into
NVIDIA:mainfrom
senthilr-nv:codex/station-express-resume-ports
Jul 20, 2026
Merged

fix(installer): preserve Station Express recipe across host handoff#7204
jyaunches merged 6 commits into
NVIDIA:mainfrom
senthilr-nv:codex/station-express-resume-ports

Conversation

@senthilr-nv

@senthilr-nv senthilr-nv commented Jul 19, 2026

Copy link
Copy Markdown
Collaborator

Summary

Station Express now publishes its owner-only recovery receipt before host preparation can require a reboot or new login. The continuation command and resumed onboarding preserve the accepted revision, agent, model, sandbox, policy tier, and gateway, dashboard, and vLLM ports instead of silently returning to default ports.

Related Issue

Fixes #7203

Changes

  • Extend the Station Express receipt with validated gateway, dashboard, and vLLM ports while continuing to accept existing three- and six-field receipts.
  • Stage the secret-free receipt before invoking Station host preparation and stop before the helper runs if safe publication fails.
  • Print and validate a complete continuation command for reboot, relogin, and revision-mismatch recovery.
  • Restore saved ports before resumed onboarding and reject malformed, conflicting, or mismatched extended receipt state.
  • Document the complete Station Express recovery contract.

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:
  • 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: Pending requested maintainer review.
  • Non-success, skipped, or missing CI check accepted by maintainer — check name, approval link, and follow-up issue:

Verification

  • PR description includes a Signed-off-by: line and every 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 — npx vitest run --project cli src/lib/onboard/station-express-resume.test.ts (48 passed); npx vitest run --project installer-integration (354 passed, 2 skipped)
  • Applicable broad gate passed — npm test for broad runtime/test-harness changes; npm run check for repo-wide validation/coverage changes — command/result: Not applicable; the complete installer integration project and normal repository hooks cover this scoped installer change.
  • 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) — build passed with 0 errors and 2 existing Fern warnings
  • Doc pages follow the style guide (doc changes only)
  • New doc pages include SPDX header and frontmatter (new pages only)

Signed-off-by: Senthil Ravichandran senthilr@nvidia.com

Summary by CodeRabbit

  • New Features
    • DGX Station Express now persists and replays gateway, dashboard, and vLLM port selections across reboots and sign-ins.
    • Resume instructions restore the exact accepted configuration (revision/model/agent/sandbox/policy tier, plus port bindings) via a printed resume command, without re-running the Express prompt.
    • The accepted Express recipe is saved before host preparation begins.
  • Bug Fixes
    • Added/expanded port validation (numeric range, distinctness, and rejection of zero-padded “numerically duplicate” values) and support for additional resume receipt formats while keeping prior receipts compatible.
  • Documentation
    • Updated “Generic Ubuntu” and “Installer Behavior and Platform Details” to reference the printed resume command.

Signed-off-by: Senthil Ravichandran <senthilr@nvidia.com>
@senthilr-nv senthilr-nv added platform: ubuntu Affects Ubuntu Linux environments platform: arm64 Affects ARM64 or aarch64 architecture area: install Install, setup, prerequisites, or uninstall flow area: onboarding Onboarding FSM, provider setup, sandbox launch, or first-run flow platform: dgx-station Affects DGX Station hardware or workflows v0.0.89 labels Jul 19, 2026
@senthilr-nv senthilr-nv self-assigned this Jul 19, 2026
@coderabbitai

coderabbitai Bot commented Jul 19, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: c5469055-bd59-4575-8179-77b451f92d14

📥 Commits

Reviewing files that changed from the base of the PR and between f3b9b11 and eadb500.

📒 Files selected for processing (1)
  • docs/get-started/dgx-station-preparation.mdx
🚧 Files skipped from review as they are similar to previous changes (1)
  • docs/get-started/dgx-station-preparation.mdx

📝 Walkthrough

Walkthrough

Station Express resume state now persists and validates gateway, dashboard, and vLLM ports before host preparation, restores them across reboot or login, and includes them in the printed continuation command. Tests and documentation cover receipt safety, legacy compatibility, recovery, and port mismatches.

Changes

Station Express resume flow

Layer / File(s) Summary
Extended receipt validation
src/lib/onboard/station-express-resume.ts, src/lib/onboard/station-express-resume.test.ts
Receipt parsing validates numeric ports in range, requires distinct bindings, accepts the extended format, and preserves malformed-receipt handling.
Port-aware resume persistence
scripts/install.sh, test/install-gateway-state-root.test.ts
Resume state stores, loads, exports, and replays gateway, dashboard, and vLLM ports, including compatibility handling for older state formats and normalized gateway state roots.
Host handoff and recovery coverage
test/install-express-prompt.test.ts, test/install-station-host-preparation.test.ts, docs/get-started/*
The accepted recipe is staged before host preparation, continuation messaging is updated, and tests cover pre-staging, safe publication, reboot recovery, restored ports, and mismatches.

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

Sequence Diagram(s)

sequenceDiagram
  participant StationExpressPrompt
  participant ensure_station_express_host
  participant ResumeState
  participant station_express_resume_command
  StationExpressPrompt->>ensure_station_express_host: accepted recipe and port settings
  ensure_station_express_host->>ResumeState: save receipt before host preparation
  ResumeState->>station_express_resume_command: load and export saved ports
  station_express_resume_command->>StationExpressPrompt: replay exact recipe without prompting
Loading

Possibly related PRs

Suggested labels: bug-fix

Suggested reviewers: cv, ericksoa

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title is concise and accurately describes the main change: preserving Station Express recipe state across host handoff.
Linked Issues check ✅ Passed The changes satisfy #7203 by staging the receipt before host prep, restoring ports on resume, handling legacy receipts, and validating malformed state.
Out of Scope Changes check ✅ Passed The patch stays focused on Station Express recovery, with docs, tests, and installer logic all directly supporting the linked issue.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

@github-actions

github-actions Bot commented Jul 19, 2026

Copy link
Copy Markdown
Contributor

PR Review Advisor — Informational

Advisor assessment: Informational / low confidence
Next action: No advisor follow-up needed.
Findings: 0 blockers · 0 warnings · 0 suggestions
Status: PR review advisor failed: PR review advisor SDK execution failed: session: 429 status code (no body); turn: reconcile-findings: 429 status code (no body)

Model lanes

  • GPT-5.6 Terra (primary): Failed
  • Nemotron 3 Ultra (second opinion): Failed after a partial review · low confidence · 1 blocker · 2 warnings · 2 suggestions

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-onboard, onboard-repair, onboard-resume

Workflow run details

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

@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.

Actionable comments posted: 1

🧹 Nitpick comments (1)
src/lib/onboard/station-express-resume.ts (1)

274-291: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Growing duplication across the legacy/current/port format branches.

The portFormat branch repeats the exact agent/sandbox/policy_tier checks already present in currentFormat above it. As more fields get added to the receipt (this is already the third format tier), this duplicated line-by-line prefix/validate pattern will keep expanding. Consider extracting a shared "parse and validate a labeled line" helper (e.g. parseLabeledLine(lines, index, prefix, validator)) that both currentFormat and portFormat reuse, so future format extensions add one call instead of repeating a block.

🤖 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 `@src/lib/onboard/station-express-resume.ts` around lines 274 - 291, Extract
the repeated agent, sandbox, and policy_tier parsing and validation from
currentFormat and portFormat into a shared labeled-line helper, such as
parseLabeledLine(lines, index, prefix, validator). Update both format branches
to reuse that helper while preserving their existing format-specific fields and
validation behavior.
🤖 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.

Inline comments:
In `@src/lib/onboard/station-express-resume.ts`:
- Around line 131-138: The port distinctness checks compare textual
representations instead of numeric values. In
src/lib/onboard/station-express-resume.ts lines 131-138, update
validReceiptPorts to normalize all ports numerically before constructing the
Set; in scripts/install.sh lines 3273-3296, normalize each port before the
comparisons in validate_station_express_resume_ports_distinct, while preserving
the existing validation behavior.

---

Nitpick comments:
In `@src/lib/onboard/station-express-resume.ts`:
- Around line 274-291: Extract the repeated agent, sandbox, and policy_tier
parsing and validation from currentFormat and portFormat into a shared
labeled-line helper, such as parseLabeledLine(lines, index, prefix, validator).
Update both format branches to reuse that helper while preserving their existing
format-specific fields and validation behavior.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: eeac607c-2ef3-4259-950a-757001bce93f

📥 Commits

Reviewing files that changed from the base of the PR and between bb5ec40 and b4aa7bd.

📒 Files selected for processing (7)
  • docs/get-started/dgx-station-preparation.mdx
  • docs/get-started/quickstart.mdx
  • scripts/install.sh
  • src/lib/onboard/station-express-resume.test.ts
  • src/lib/onboard/station-express-resume.ts
  • test/install-express-prompt.test.ts
  • test/install-station-host-preparation.test.ts

Comment thread src/lib/onboard/station-express-resume.ts
senthilr-nv and others added 2 commits July 19, 2026 08:48
Signed-off-by: Senthil Ravichandran <senthilr@nvidia.com>
Signed-off-by: Carlos Villela <cvillela@nvidia.com>
@cv

cv commented Jul 19, 2026

Copy link
Copy Markdown
Collaborator

Maintainer sweep update: I found and fixed one input-validation issue in the changed gateway-port normalization path. An overlong digit-only value could overflow Bash arithmetic and be accepted as a negative port. Commit f3b9b1184 now bounds the canonical decimal representation before arithmetic and adds a regression proving the value fails cleanly.

Verification after the fix:

  • gateway state-root tests: 11 passed
  • Station Express receipt tests: 49 passed
  • normal commit hooks passed, including ShellCheck
  • normal pre-push CLI type-check passed
  • documentation build had already passed for the PR documentation changes

The broader Station handoff change remains within accepted bug #7203. Fresh CI and automated review are running; I did not merge.

@cv

cv commented Jul 19, 2026

Copy link
Copy Markdown
Collaborator

Maintainer sweep disposition: deferred — no source changes requested.

The implementation and security review are clean after commit f3b9b1184:

  • Station Express publishes an owner-only, symlink-safe, secret-free receipt before host mutation;
  • revision, generation, agent, sandbox, policy tier, and all three ports are validated and restored fail-closed;
  • continuation-command values are constrained rather than shell-controlled;
  • overlong digit-only gateway ports now fail instead of overflowing Bash arithmetic;
  • PR-specific tests, docs, ShellCheck, type-check, installer integration, and the full current-base CI run passed;
  • the current advisor ledger has no actionable findings;
  • the fork E2E gate records an audited skip for cloud-onboard, onboard-repair, and onboard-resume; no fork code received repository secrets.

The remaining blocker is GitHub Actions run association, not this PR. The successful current-base CI run is 29694731282, but GitHub's API returns an empty pull_requests association for it. The deterministic maintainer gate therefore fails closed with incomplete latest-attempt evidence and does not permit approval. Once GitHub/tooling can bind the successful contexts to this PR, this is ready for a human merge decision without contributor code changes.

I did not merge.

@senthilr-nv
senthilr-nv requested a review from cv July 20, 2026 02:17
@jyaunches
jyaunches merged commit 91b99c8 into NVIDIA:main Jul 20, 2026
69 of 73 checks passed
@ericksoa ericksoa mentioned this pull request Jul 20, 2026
21 tasks
ericksoa added a commit that referenced this pull request Jul 20, 2026
<!-- markdownlint-disable MD041 -->
## Summary

Add the canonical dated changelog entry for NemoClaw `v0.0.89` before
the release plan captures the tag commit.
The entry summarizes the user-visible Station preparation, inference,
recovery, policy-disclosure, and CLI-containment changes merged since
`v0.0.88`.

## Changes

- Add `docs/changelog/2026-07-20.mdx` with the exact `## v0.0.89`
release heading, parser-safe SPDX comment, summary, and detailed
bullets.
- Link each shipped theme to the most specific published OpenClaw
documentation routes.
- Keep internal E2E, advisory-registry, and review-workflow refactors
out of the user-facing release summary.

Source summary:

- #7214, #7241, #7237, #7223, #7204, #7202, #7183, and #7090 ->
`docs/changelog/2026-07-20.mdx`: Summarize qualified DGX Station
identity, package-state, PackageKit, DKMS, and reboot-handoff fixes.
- #7242, #7221, #7186, #7164, and #6874 ->
`docs/changelog/2026-07-20.mdx`: Summarize inference endpoint
provenance, provider attachment, managed vLLM cleanup and progress, and
Ollama selection guidance.
- #7225, #7216, #7192, #7136, #7096, and #6910 ->
`docs/changelog/2026-07-20.mdx`: Summarize sandbox readiness, recovery
guidance, rebuilt model routing, durable Hermes state, and gateway
restart behavior.
- #7187 -> `docs/changelog/2026-07-20.mdx`: Summarize complete effective
messaging-preset egress disclosure before policy mutation.
- #7218, #7165, and #7184 -> `docs/changelog/2026-07-20.mdx`: Summarize
structured output containment, terminal-safe route display, and Hermes
forward cleanup.

## Type of Change

- [ ] Code change (feature, bug fix, or refactor)
- [ ] Code change with doc updates
- [x] 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:
- [x] Tests not applicable — justification: This PR adds release-history
prose only; the focused changelog contract test validates its required
structure and routes.
- [x] Docs updated for user-facing behavior changes
- [ ] Docs not applicable — justification:
- [ ] 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:

## 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 — `mise exec node@22.23.1 -- npx vitest
run test/changelog-docs.test.ts` (6 passed).
- [ ] Applicable broad gate passed — `npm test` for broad
runtime/test-harness changes; `npm run check` for repo-wide
validation/coverage changes — not applicable to this doc-only release
entry.
- [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) — `mise
exec node@22.23.1 -- npm run docs` completed with 0 errors and 2
existing site-wide warnings.
- [x] 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)
— the native changelog entry uses the required parser-safe MDX SPDX
comment and does not use frontmatter.

---
Signed-off-by: Aaron Erickson <aerickson@nvidia.com>


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

## Summary by CodeRabbit

* **New Features**
* Expanded DGX Station installation support for qualified GB300 and
OTA-upgraded environments.
* Preserved selected inference providers, endpoints, model pins, and
tuning settings during sandbox creation and rebuilds.
* Improved sandbox recovery by validating availability and stability
before restarting services.
* Added clearer policy output showing the complete effective messaging
egress configuration.

* **Bug Fixes**
* Hardened status and inference route displays by sanitizing terminal
control characters.
* Improved Hermes uninstall behavior by stopping detached dashboard
forwarding.

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

Signed-off-by: Aaron Erickson <aerickson@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: install Install, setup, prerequisites, or uninstall flow area: onboarding Onboarding FSM, provider setup, sandbox launch, or first-run flow platform: arm64 Affects ARM64 or aarch64 architecture platform: dgx-station Affects DGX Station hardware or workflows platform: ubuntu Affects Ubuntu Linux environments

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Station Express resume loses accepted state and custom ports at host handoff

5 participants