Skip to content

fix(tunnel): stop agent gateway forwards on shutdown - #6450

Merged
cv merged 18 commits into
NVIDIA:mainfrom
rluo8:fix/6392-nemohermes-stop-forward
Jul 8, 2026
Merged

fix(tunnel): stop agent gateway forwards on shutdown#6450
cv merged 18 commits into
NVIDIA:mainfrom
rluo8:fix/6392-nemohermes-stop-forward

Conversation

@rluo8

@rluo8 rluo8 commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

Summary

Fix nemohermes stop cleanup for Hermes sandboxes by stopping the active agent gateway and its host forwards instead of only looking for OpenClaw gateway processes. The fix also skips in-sandbox gateway shutdown for terminal-only agents, so terminal agent sessions are not accidentally killed.

Related Issue

Fixes #6392

Changes

  • Add agent-aware in-sandbox gateway stop patterns, including Hermes hermes.real gateway run.
  • Skip gateway process termination when the active agent has no gateway runtime.
  • Stop agent-declared host forwards plus the dashboard forward before releasing the managed OpenShell gateway port.
  • Run the OpenShell fallback stop script through stdin to avoid newline argv issues.
  • Add targeted coverage for Hermes stop, forward cleanup, terminal-agent guard behavior, and gateway stop pattern generation.

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: shutdown cleanup behavior changed, but no user-facing docs or commands changed.
  • [√] 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

  • [√] PR description includes the DCO sign-off declaration 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 — command/result or justification:
  • [√] Applicable broad gate passed — npm test for broad runtime/test-harness changes; npm run check for repo-wide validation/coverage changes — command/result:
  • [√] 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)

Signed-off-by: Rui Luo ruluo@nvidia.com

Summary by CodeRabbit

  • New Features

    • Improved shutdown handling for sandbox gateways and host port forwards, including better detection of which ports should be stopped.
  • Bug Fixes

    • Added safer fallbacks when gateway information is unavailable, reducing the chance of stopping the wrong forward.
    • Improved cleanup behavior when forwarded ports belong to another sandbox or can’t be confirmed released.
    • Refined shutdown flows for different agent/runtime types so unsupported cases are skipped cleanly.

@coderabbitai

coderabbitai Bot commented Jul 8, 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
📝 Walkthrough

Walkthrough

This PR adds stopAgentForwardPortsForStop, which best-effort stops host SSH port forwards for a session agent's declared ports and dashboard port via scoped OpenShell commands, then confirms port release. stopSandboxChannels is reworked to use agent runtime state and a shared GATEWAY_STOP_SCRIPT, and stopAll now wires forward-port cleanup accordingly, with expanded test coverage.

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

Changes

Agent-aware stop flow

Layer / File(s) Summary
Forward-port stop implementation
src/lib/tunnel/agent-forward-stop.ts
New stopAgentForwardPortsForStop derives candidate ports from agent forward_ports and dashboardPort, scopes OpenShell runners by gateway, stops matching forwards, and polls to confirm port release.
Forward-port stop tests
src/lib/tunnel/agent-forward-stop.test.ts
Covers success path, missing agent/ports early returns, ownership conflicts, enumeration failures, release-confirmation failure (#6392), and missing gateway binding.
Sandbox stop wiring and tests
src/lib/tunnel/services.ts, src/lib/tunnel/services-sandbox.test.ts, src/lib/tunnel/services-gateway-ownership.test.ts
stopSandboxChannels now branches on agent runtime gateway state, uses GATEWAY_STOP_SCRIPT via stdin, adds isSandboxPodName pod matching, and updates reportStopResult labeling; stopAll calls stopAgentForwardPortsForStop; tests mock agent/sandbox lookups and verify Hermes/terminal/gateway-unavailable scenarios and wiring.
Unrelated test call-shape fix
test/langchain-deepagents-code-image.test.ts
Adjusts a spawnSync call's structure without changing behavior or assertions.

Suggested labels: bug-fix, area: sandbox

Suggested reviewers: jyaunches, cv

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Out of Scope Changes check ⚠️ Warning The tweak in test/langchain-deepagents-code-image.test.ts is unrelated to tunnel shutdown and the linked issue scope. Split or remove the unrelated test-only change so this PR stays focused on the tunnel shutdown fix.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly states the tunnel shutdown behavior change and matches the main focus of the PR.
Linked Issues check ✅ Passed The PR stops agent forwards, releases the managed gateway port, and updates Hermes/OpenClaw shutdown messaging as required by #6392.
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.

@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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/lib/tunnel/services.ts (1)

636-658: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Failure-path message still says generic "in-sandbox gateway" instead of using gatewayLabel.

reportStopResult now threads gatewayLabel through the success (${gatewayLabel} stopped inside sandbox.) and not-running (${gatewayLabel} was not running inside sandbox.) branches, but the failure branch at Line 654 still hardcodes "Could not stop in-sandbox gateway" instead of ${gatewayLabel}. Given the linked issue explicitly calls for correcting the shutdown output to name the actual agent gateway, this branch should be updated too for consistency.

🐛 Proposed fix
   warn(
-    `Could not stop in-sandbox gateway (exit ${String(result.status ?? "unknown")}).` +
+    `Could not stop ${gatewayLabel} (exit ${String(result.status ?? "unknown")}).` +
       " The sandbox may be unreachable or the gateway may still be running." +
       (details ? ` Details: ${details}` : ""),
   );
🤖 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/tunnel/services.ts` around lines 636 - 658, The failure branch in
reportStopResult still hardcodes a generic “in-sandbox gateway” message instead
of using gatewayLabel, so update the warn call in reportStopResult to
interpolate the provided gatewayLabel consistently with the success and
not-running branches. Keep the existing stderr/stdout details handling, but make
the shutdown failure message identify the actual gateway being stopped.
🧹 Nitpick comments (2)
src/lib/tunnel/agent-forward-stop.test.ts (1)

20-126: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Add coverage for the default spawnSync runners and the "openshell not found" branch.

Every test here injects runOpenshell/runCaptureOpenshell/resolveOpenshell, so the real makeRunOpenshell/makeRunCaptureOpenshell (spawnSync command construction, stdio/timeout handling, throw-on-nonzero-status) and the openshell not found warn-and-return path in agent-forward-stop.ts are never exercised. Given this module is being wired into stopAll to fix the port-8642 release bug (#6392), it's worth locking down the actual host-boundary behavior, not just the injected-fake path.

🧪 Suggested additions
+  it("warns and returns when OpenShell cannot be resolved", () => {
+    const warn = vi.fn<(message: string) => void>();
+    const runOpenshell = vi.fn();
+
+    stopAgentForwardPortsForStop("nemohermes", {
+      getSessionAgent: () => ({ displayName: "Hermes Agent", forward_ports: [8642] }),
+      getSandbox: () => null,
+      resolveOpenshell: () => null,
+      runOpenshell,
+      warn,
+    });
+
+    expect(runOpenshell).not.toHaveBeenCalled();
+    expect(warn.mock.calls.map((call) => call[0]).join("\n")).toContain("openshell not found");
+  });
+
+  it("invokes the real OpenShell binary via spawnSync for a stop command", () => {
+    // mock node:child_process spawnSync via vi.mock to assert args/encoding/stdio
+    // without exercising deps.runOpenshell/runCaptureOpenshell overrides.
+  });
🤖 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/tunnel/agent-forward-stop.test.ts` around lines 20 - 126, The current
tests only cover injected fakes, so they miss the real default runner behavior
and the “openshell not found” branch in stopAgentForwardPortsForStop. Add
coverage that exercises the default makeRunOpenshell and makeRunCaptureOpenshell
paths so spawnSync command construction, stdio/timeout handling, and
nonzero-status errors are validated, and add a case where resolveOpenshell
returns nothing to assert the warn-and-return flow. Use the
stopAgentForwardPortsForStop, makeRunOpenshell, and makeRunCaptureOpenshell
symbols to target the relevant paths.
src/lib/tunnel/services-sandbox.test.ts (1)

138-165: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Consider suffixing the test title with the tracked issue.

Behavior-oriented title reads well, but this test directly exercises the fix for the linked issue.

✏️ Suggested title
-  it("uses the active agent gateway command for Hermes shutdown", () => {
+  it("uses the active agent gateway command for Hermes shutdown (`#6392`)", () => {

As per coding guidelines, "**/*.test.ts: Write behavior-oriented test titles, and put local issue references in a final (#1234) suffix."

🤖 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/tunnel/services-sandbox.test.ts` around lines 138 - 165, Update the
test title in services-sandbox.test.ts so it remains behavior-oriented but ends
with the tracked issue reference in the required suffix format, since this test
directly covers the fix. Adjust the it(...) description for the Hermes shutdown
test to include the local issue tag at the end, keeping the rest of the
assertion logic unchanged and matching the naming convention used by the
surrounding test suite.

Source: Coding guidelines

🤖 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/tunnel/services-sandbox.test.ts`:
- Line 242: The assertion in services-sandbox.test should be content-aware
because `expect(args).not.toContain(expect.stringContaining(...))` only compares
array elements by identity and can miss matching substrings. Update the check
near the `args` assertion to use a content-based matcher such as
`toContainEqual(expect.stringContaining("find_gateway_pids"))` or a predicate
over `args` that inspects each string’s contents, so the test actually verifies
whether any argument includes `find_gateway_pids`.

---

Outside diff comments:
In `@src/lib/tunnel/services.ts`:
- Around line 636-658: The failure branch in reportStopResult still hardcodes a
generic “in-sandbox gateway” message instead of using gatewayLabel, so update
the warn call in reportStopResult to interpolate the provided gatewayLabel
consistently with the success and not-running branches. Keep the existing
stderr/stdout details handling, but make the shutdown failure message identify
the actual gateway being stopped.

---

Nitpick comments:
In `@src/lib/tunnel/agent-forward-stop.test.ts`:
- Around line 20-126: The current tests only cover injected fakes, so they miss
the real default runner behavior and the “openshell not found” branch in
stopAgentForwardPortsForStop. Add coverage that exercises the default
makeRunOpenshell and makeRunCaptureOpenshell paths so spawnSync command
construction, stdio/timeout handling, and nonzero-status errors are validated,
and add a case where resolveOpenshell returns nothing to assert the
warn-and-return flow. Use the stopAgentForwardPortsForStop, makeRunOpenshell,
and makeRunCaptureOpenshell symbols to target the relevant paths.

In `@src/lib/tunnel/services-sandbox.test.ts`:
- Around line 138-165: Update the test title in services-sandbox.test.ts so it
remains behavior-oriented but ends with the tracked issue reference in the
required suffix format, since this test directly covers the fix. Adjust the
it(...) description for the Hermes shutdown test to include the local issue tag
at the end, keeping the rest of the assertion logic unchanged and matching the
naming convention used by the surrounding test suite.
🪄 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: b1a6b452-1917-4186-91ab-b359c243e8dc

📥 Commits

Reviewing files that changed from the base of the PR and between be3e7cc and 5aae2a6.

📒 Files selected for processing (5)
  • src/lib/tunnel/agent-forward-stop.test.ts
  • src/lib/tunnel/agent-forward-stop.ts
  • src/lib/tunnel/services-gateway-ownership.test.ts
  • src/lib/tunnel/services-sandbox.test.ts
  • src/lib/tunnel/services.ts

Comment thread src/lib/tunnel/services-sandbox.test.ts Outdated
rluo8 added 2 commits July 8, 2026 15:45
Signed-off-by: Rui Luo <ruluo@nvidia.com>
Signed-off-by: Rui Luo <ruluo@nvidia.com>
@rluo8
rluo8 force-pushed the fix/6392-nemohermes-stop-forward branch from 5aae2a6 to 7cd24b8 Compare July 8, 2026 07:58

@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/tunnel/agent-forward-stop.ts (1)

84-138: 🚀 Performance & Scalability | 🔵 Trivial | 💤 Low value

Avoid re-listing OpenShell for every port. stopAgentForwardPortsForStop calls bestEffortForwardStopForSandbox once per port, and each call runs openshell forward list again. If forward_ports can contain multiple entries, this adds one shell round-trip per port; hoist the list lookup out of the loop if the per-port refresh isn’t needed here.

🤖 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/tunnel/agent-forward-stop.ts` around lines 84 - 138,
`stopAgentForwardPortsForStop` is re-running the OpenShell forward list for
every entry in `forward_ports` via `bestEffortForwardStopForSandbox`, causing
unnecessary shell round-trips. Refactor the `stopAgentForwardPortsForStop` flow
to fetch the OpenShell forward list once outside the per-port loop (using the
existing `resolveOpenshell`, `makeRunOpenshell`, and `makeRunCaptureOpenshell`
wiring), then reuse that result while iterating ports, keeping the existing
stop/warn/info behavior intact.
🤖 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/tunnel/agent-forward-stop.ts`:
- Around line 84-138: The legacy OpenClaw gateway-stop path is still being
selected alongside the new agent-aware cleanup, so remove the obsolete
`openclaw-gateway` / `openclaw gateway` handling from `services.ts` and ensure
`stopAll` no longer routes through that branch. Update the stop flow to use
`stopAgentForwardPortsForStop` and related agent-forward logic only, and keep
any old path behind an explicit compatibility gate if it must remain.

---

Nitpick comments:
In `@src/lib/tunnel/agent-forward-stop.ts`:
- Around line 84-138: `stopAgentForwardPortsForStop` is re-running the OpenShell
forward list for every entry in `forward_ports` via
`bestEffortForwardStopForSandbox`, causing unnecessary shell round-trips.
Refactor the `stopAgentForwardPortsForStop` flow to fetch the OpenShell forward
list once outside the per-port loop (using the existing `resolveOpenshell`,
`makeRunOpenshell`, and `makeRunCaptureOpenshell` wiring), then reuse that
result while iterating ports, keeping the existing stop/warn/info behavior
intact.
🪄 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: 359f40e1-aef7-4170-8f5a-f56815411dd5

📥 Commits

Reviewing files that changed from the base of the PR and between 5aae2a6 and 7cd24b8.

📒 Files selected for processing (5)
  • src/lib/tunnel/agent-forward-stop.test.ts
  • src/lib/tunnel/agent-forward-stop.ts
  • src/lib/tunnel/services-gateway-ownership.test.ts
  • src/lib/tunnel/services-sandbox.test.ts
  • src/lib/tunnel/services.ts
🚧 Files skipped from review as they are similar to previous changes (4)
  • src/lib/tunnel/services-sandbox.test.ts
  • src/lib/tunnel/services-gateway-ownership.test.ts
  • src/lib/tunnel/agent-forward-stop.test.ts
  • src/lib/tunnel/services.ts

Comment thread src/lib/tunnel/agent-forward-stop.ts
Signed-off-by: Rui Luo <ruluo@nvidia.com>
@rluo8 rluo8 added the v0.0.77 label Jul 8, 2026
@prekshivyas

Copy link
Copy Markdown
Collaborator

Cross-PR coordination for #4960 / #4951: #4960 is now exact-head green and both review advisors recommend merge_as_is. This PR rewrites the same stopSandboxChannels matcher, but its OpenClaw patterns currently cover openclaw-gateway and openclaw gateway ..., not the post-startup bare openclaw argv that caused #4951. Please either rebase after #4960 or integrate its PID/starttime/owner/marker-gated bare-argv branch and Linux negative regressions so merge order cannot reintroduce the false-success shutdown bug.

@ericksoa ericksoa added v0.0.78 and removed v0.0.77 labels Jul 8, 2026
cv
cv previously approved these changes Jul 8, 2026

@cv cv left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Reviewed exact head 2b47214 with a focused security/process-boundary pass. Forward cleanup is sandbox-scoped and fails closed on ownership-list failure; port inputs are bounded; OpenShell calls use argv/stdin rather than shell interpolation; generated gateway regexes are escaped and shell-quoted; terminal-only agents are excluded. Focused tests cover cross-sandbox ownership, list failure, invalid/duplicate ports, Hermes launcher/re-exec patterns, fallback execution, and terminal-agent behavior. All 33 checks and contributor-compliance gates are green. No blocking findings.

@cv
cv dismissed their stale review July 8, 2026 16:21

Withdrawing approval pending the exact macOS/Colima acceptance evidence from #6392: on current head, nemohermes stop should release the openshell ssh-proxy listener on port 8642 within 5 seconds and emit Hermes-labeled output. The focused code/security review remains clean; this is an acceptance-evidence gap.

@cv

cv commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

Focused code/security review is clean: ownership lookup fails closed, stops are sandbox-scoped, manifest-derived patterns are escaped/quoted, and terminal agents are protected. One acceptance gap remains before approval: the green macOS job did not exercise Docker/Colima or this repro. Please record current-head macOS/Apple Silicon evidence for issue #6392 showing (1) lsof -ti :8642 -sTCP:LISTEN is non-empty before nemohermes stop, (2) it is empty within 5 seconds afterward, and (3) output identifies the Hermes Agent gateway. Unit tests prove command construction but not the OpenShell 0.0.72+ ssh-proxy teardown contract.

@cjagwani cjagwani assigned jyaunches and ericksoa and unassigned jyaunches Jul 8, 2026
ericksoa added 2 commits July 8, 2026 11:14
Signed-off-by: Aaron Erickson <aerickson@nvidia.com>
Signed-off-by: Aaron Erickson <aerickson@nvidia.com>
@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All selected jobs passed

Run: 28968021725
Workflow ref: codex/pr-6450-e2e-41033af
Requested targets: ubuntu-repo-cloud-openclaw,ubuntu-repo-cloud-langchain-deepagents-code
Requested jobs: (default — all default-enabled free-standing jobs; explicit-only jobs openshell-gateway-auth-contract, mcp-bridge-dev, hermes-gpu-startup, sandbox-rlimits-connect, and jetson-nvmap-gpu are skipped unless selected)
Summary: 1 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
live ✅ success

@ericksoa

ericksoa commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

Current-head macOS/Apple Silicon acceptance proof for #6392 (refreshed after the final helper-boundary validation):

  • Head: 3253c81c9782ccfe7b907e2487370eb666229527
  • Host: macOS / Darwin 25.5.0, arm64; Colima; OpenShell 0.0.72
  • Sandbox: pr6450-final-h on persisted gateway nemoclaw-18080
  • Before stop: lsof -tiTCP:8642 -sTCP:LISTEN returned PID 15716, and openshell forward list --gateway nemoclaw-18080 reported the forward as running.
  • I deliberately selected the other/default nemoclaw gateway before running stop; cleanup still used the target sandbox's persisted registry row and gateway binding.
  • node bin/nemohermes.js stop exited 0 and reported:
    • Hermes Agent gateway is managed by the sandbox; leaving it running while host forwards stop.
    • Stopped Hermes Agent host port forward 8642 for sandbox 'pr6450-final-h'.
  • After stop: port 8642 was listener-free on the first poll (released_within_seconds=0), and openshell forward list --gateway nemoclaw-18080 reported No active forwards.

This satisfies the requested real Apple Silicon/Colima proof on exact head 3253c81c: a non-empty listener before stop, release within five seconds, target-registry/persisted-gateway scoping, and Hermes Agent-labeled output.

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ❌ Some jobs failed

Run: 28968019581
Workflow ref: codex/pr-6450-e2e-41033af
Requested targets: (default — all supported)
Requested jobs: tunnel-lifecycle,sandbox-operations,hermes-dashboard
Summary: 2 passed, 1 failed, 0 cancelled, 0 skipped

Job Result
hermes-dashboard ✅ success
sandbox-operations ❌ failure
tunnel-lifecycle ✅ success

Failed jobs: sandbox-operations. Check run artifacts for logs.

@cjagwani cjagwani left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Approved exact verified head 41033af2284ec3c90a18c8ddde2bca1f950e04a9. The shutdown path is sandbox- and gateway-scoped, fails closed when ownership or binding cannot be established, preserves supervised non-OpenClaw gateway runtimes, and verifies host-forward release before reporting success. Exact-head required CI is green; 55 focused tunnel/process-boundary tests and Node 22 CLI typechecking pass locally. Current-head macOS arm64/Colima/OpenShell 0.0.72 acceptance evidence also proves port 8642 is listening before stop, released on the first poll, and reported with the Hermes Agent label.

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All requested jobs passed

Run: 28968460032
Workflow ref: codex/pr-6450-e2e-41033af
Requested targets: (default — all supported)
Requested jobs: sandbox-operations
Summary: 1 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
sandbox-operations ✅ success

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

Approved exact head 41033af2284ec3c90a18c8ddde2bca1f950e04a9 after focused correctness, process-boundary, and overlap review.

No blocking findings remain. This head scopes forward enumeration/stop to the sandbox's persisted gateway, confirms real listener release before reporting success, preserves sandbox-supervised Hermes gateway behavior, and integrates #4960's PID/start-time/owner/marker-gated OpenClaw shutdown plus exact pod selection.

Validation includes clean exact-head PR CI and CodeRabbit, 57 focused tests passing locally (15 Linux-only script cases skipped on macOS and passing in CI), real Apple Silicon/Colima proof that the 8642 listener is released immediately with Hermes Agent-labeled output, and passing advisor-required E2E coverage for tunnel lifecycle, Hermes dashboard, sandbox operations, and both typed live targets.

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

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All requested jobs passed

Run: 28968019581
Workflow ref: codex/pr-6450-e2e-41033af
Requested targets: (default — all supported)
Requested jobs: tunnel-lifecycle,sandbox-operations,hermes-dashboard
Summary: 3 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
hermes-dashboard ✅ success
sandbox-operations ✅ success
tunnel-lifecycle ✅ success

ericksoa added 2 commits July 8, 2026 12:15
Signed-off-by: Aaron Erickson <aerickson@nvidia.com>
Signed-off-by: Aaron Erickson <aerickson@nvidia.com>
@cjagwani

cjagwani commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

@rluo8 Main advanced through #4960 and made this PR dirty. I prepared the narrow current-main refresh at signed commit f16d6a39f1422e61dc930589cc6babfd2f0b4b91 (parents: reviewed 41033af228 + current main edf69f0bb).

The only conflicts were the expected services.ts/services-sandbox.test.ts overlap with #4960. The resolution keeps main's PID/start-time/owner/marker-gated OpenClaw matcher, this PR's persisted gateway binding and stdin-based fallback, and the supervised Hermes forward cleanup. Verification on the merged tree: 55 focused tunnel/process tests pass, the generated CLI build passes, and Node 22 CLI typechecking passes.

GitHub reports maintainerCanModify, but its smart-HTTP endpoint gives this maintainer only READ/HTTP 503 for the fork, so I could not update your branch directly. The signed fast-forward is published at NVIDIA/NemoClaw:codex/pr-6450-main-refresh; you can relay it without rewriting history:

git fetch https://github.com/NVIDIA/NemoClaw.git codex/pr-6450-main-refresh
git push origin FETCH_HEAD:fix/6392-nemohermes-stop-forward

I will recheck the exact relayed head and CI immediately afterward.

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All requested jobs passed

Run: 28973140165
Workflow ref: codex/pr-6450-e2e-32a0451
Requested targets: (default — all supported)
Requested jobs: tunnel-lifecycle,sandbox-operations,hermes-dashboard,concurrent-gateway-ports,hermes-e2e
Summary: 5 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
concurrent-gateway-ports ✅ success
hermes-dashboard ✅ success
hermes-e2e ✅ success
sandbox-operations ✅ success
tunnel-lifecycle ✅ success

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ⚠️ Run cancelled — no signal

Run: 28973393283
Workflow ref: codex/pr-6450-e2e-32a0451
Requested targets: (default — all supported)
Requested jobs: channels-stop-start
Summary: 0 passed, 0 failed, 1 cancelled, 0 skipped

Job Result
channels-stop-start ⚠️ cancelled

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All selected jobs passed

Run: 28973716384
Workflow ref: codex/pr-6450-e2e-5cc9044
Requested targets: ubuntu-repo-cloud-openclaw,ubuntu-repo-cloud-langchain-deepagents-code
Requested jobs: (default — all default-enabled free-standing jobs; explicit-only jobs openshell-gateway-auth-contract, mcp-bridge-dev, hermes-gpu-startup, sandbox-rlimits-connect, and jetson-nvmap-gpu are skipped unless selected)
Summary: 1 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
live ✅ success

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

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ⚠️ Some jobs cancelled — partial pass

Run: 28973716353
Workflow ref: codex/pr-6450-e2e-5cc9044
Requested targets: (default — all supported)
Requested jobs: channels-stop-start,tunnel-lifecycle,sandbox-operations,hermes-dashboard,concurrent-gateway-ports,hermes-e2e
Summary: 2 passed, 0 failed, 4 cancelled, 0 skipped

Job Result
channels-stop-start ⚠️ cancelled
concurrent-gateway-ports ✅ success
hermes-dashboard ⚠️ cancelled
hermes-e2e ⚠️ cancelled
sandbox-operations ⚠️ cancelled
tunnel-lifecycle ✅ success

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ❌ Some jobs failed

Run: 28974149007
Workflow ref: codex/pr-6450-e2e-3253c81
Requested targets: ubuntu-repo-cloud-openclaw,ubuntu-repo-cloud-langchain-deepagents-code
Requested jobs: (default — all default-enabled free-standing jobs; explicit-only jobs openshell-gateway-auth-contract, mcp-bridge-dev, hermes-gpu-startup, sandbox-rlimits-connect, and jetson-nvmap-gpu are skipped unless selected)
Summary: 0 passed, 1 failed, 0 cancelled, 0 skipped

Job Result
live ❌ failure

Failed jobs: live. Check run artifacts for logs.

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All requested jobs passed

Run: 28974148865
Workflow ref: codex/pr-6450-e2e-3253c81
Requested targets: (default — all supported)
Requested jobs: tunnel-lifecycle,sandbox-operations,hermes-dashboard,concurrent-gateway-ports,hermes-e2e
Summary: 5 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
concurrent-gateway-ports ✅ success
hermes-dashboard ✅ success
hermes-e2e ✅ success
sandbox-operations ✅ success
tunnel-lifecycle ✅ success

ericksoa added 2 commits July 8, 2026 13:50
Signed-off-by: Aaron Erickson <aerickson@nvidia.com>
Signed-off-by: Aaron Erickson <aerickson@nvidia.com>
@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ⚠️ Run cancelled — no signal

Run: 28974605815
Workflow ref: codex/pr-6450-e2e-3253c81
Requested targets: (default — all supported)
Requested jobs: full-e2e
Summary: 0 passed, 0 failed, 1 cancelled, 0 skipped

Job Result
full-e2e ⚠️ cancelled

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ❌ Some jobs failed

Run: 28975011600
Workflow ref: codex/pr-6450-e2e-e5191a1
Requested targets: (selector rejected by workflow validation)
Requested jobs: (selector rejected by workflow validation)
Summary: 0 passed, 1 failed, 0 cancelled, 0 skipped

Job Result
generate-matrix ❌ failure

Failed jobs: generate-matrix. Check run artifacts for logs.

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All selected jobs passed

Run: 28975084156
Workflow ref: codex/pr-6450-e2e-e5191a1
Requested targets: ubuntu-repo-cloud-langchain-deepagents-code,ubuntu-repo-cloud-openclaw
Requested jobs: (default — all default-enabled free-standing jobs; explicit-only jobs openshell-gateway-auth-contract, mcp-bridge-dev, hermes-gpu-startup, sandbox-rlimits-connect, and jetson-nvmap-gpu are skipped unless selected)
Summary: 1 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
live ✅ success

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

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ❌ Some jobs failed

Run: 28975082325
Workflow ref: codex/pr-6450-e2e-e5191a1
Requested targets: (default — all supported)
Requested jobs: hermes-dashboard,concurrent-gateway-ports,tunnel-lifecycle,hermes-e2e,sandbox-operations,full-e2e
Summary: 5 passed, 1 failed, 0 cancelled, 0 skipped

Job Result
concurrent-gateway-ports ✅ success
full-e2e ❌ failure
hermes-dashboard ✅ success
hermes-e2e ✅ success
sandbox-operations ✅ success
tunnel-lifecycle ✅ success

Failed jobs: full-e2e. Check run artifacts for logs.

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ❌ Some jobs failed

Run: 28975686326
Workflow ref: codex/pr-6450-e2e-453700b
Requested targets: (default — all supported)
Requested jobs: tunnel-lifecycle,sandbox-operations,hermes-e2e
Summary: 2 passed, 1 failed, 0 cancelled, 0 skipped

Job Result
hermes-e2e ❌ failure
sandbox-operations ✅ success
tunnel-lifecycle ✅ success

Failed jobs: hermes-e2e. Check run artifacts for logs.

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All requested jobs passed

Run: 28975948133
Workflow ref: codex/pr-6450-e2e-453700b
Requested targets: (default — all supported)
Requested jobs: full-e2e
Summary: 1 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
full-e2e ✅ success

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All requested jobs passed

Run: 28976061199
Workflow ref: codex/pr-6450-e2e-453700b
Requested targets: (default — all supported)
Requested jobs: concurrent-gateway-ports
Summary: 1 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
concurrent-gateway-ports ✅ success

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

E2E Target Results — ✅ All requested jobs passed

Run: 28975540880
Workflow ref: codex/pr-6450-e2e-e5191a1
Requested targets: (default — all supported)
Requested jobs: hermes-e2e,hermes-dashboard,sandbox-operations,concurrent-gateway-ports,tunnel-lifecycle,channels-stop-start
Summary: 6 passed, 0 failed, 0 cancelled, 0 skipped

Job Result
channels-stop-start ✅ success
concurrent-gateway-ports ✅ success
hermes-dashboard ✅ success
hermes-e2e ✅ success
sandbox-operations ✅ success
tunnel-lifecycle ✅ success

@cv
cv merged commit 7dc1f2f into NVIDIA:main Jul 8, 2026
337 of 340 checks passed
@cjagwani cjagwani mentioned this pull request Jul 9, 2026
21 tasks
cv pushed a commit that referenced this pull request Jul 9, 2026
<!-- markdownlint-disable MD041 -->
## Summary

Prepares the user documentation for NemoClaw v0.0.78 by replacing the
unreleased section with release highlights and synchronizing the
affected inference, lifecycle, messaging, and CLI reference pages with
merged behavior.

## Changes

- Publish the v0.0.78 release-notes section with links to the most
specific user guides for each shipped behavior.
- Document authoritative Deep Agents route health, Nemotron Ultra
profile behavior, and Hermes compatible-endpoint context metadata.
- Document forced rebuild recovery after total backup failure and the
ownership-safe tunnel/full-stop behavior.
- Keep command examples and shared agent variants aligned with the
current OpenClaw, Hermes, and Deep Agents interfaces.

Source mapping:

- [#3787](#3787) ->
`docs/about/release-notes.mdx`: Record reliable workspace template
seeding during sandbox startup.
- [#4960](#4960) ->
`docs/about/release-notes.mdx`: Record safer detection of rewritten
OpenClaw gateway processes.
- [#5676](#5676) ->
`docs/about/release-notes.mdx`: Record warning-tolerant agent-list JSON
handling.
- [#5857](#5857) ->
`docs/about/release-notes.mdx`: Record synchronization of explicit
OpenClaw main-agent model state.
- [#5929](#5929) ->
`docs/about/release-notes.mdx`: Record copyable SSH port-forward
guidance for remote dashboards.
- [#6068](#6068) ->
`docs/about/release-notes.mdx`: Record custom-image plugin provenance
reconciliation.
- [#6116](#6116) ->
`docs/about/release-notes.mdx`: Record live-loopback dashboard-forward
recovery.
- [#6122](#6122) ->
`docs/about/release-notes.mdx`: Announce validated, round-trippable
policy YAML output.
- [#6211](#6211) ->
`docs/manage-sandboxes/lifecycle.mdx`, `docs/reference/commands.mdx`,
`docs/about/release-notes.mdx`: Explain the explicit no-backup `rebuild
--force` recovery boundary.
- [#6283](#6283) ->
`docs/about/release-notes.mdx`: Record Hermes WebUI port alignment.
- [#6293](#6293) ->
`docs/inference/switch-inference-providers.mdx`,
`docs/about/release-notes.mdx`: Document compatible-endpoint
context-length probing for Hermes.
- [#6320](#6320) ->
`docs/about/release-notes.mdx`: Record bounded gateway-recovery waits.
- [#6377](#6377) ->
`docs/reference/commands.mdx`, `docs/about/release-notes.mdx`: Explain
rebuild diagnostics and prepared MCP-destroy recovery.
- [#6412](#6412) ->
`docs/get-started/quickstart-langchain-deepagents-code.mdx`,
`docs/about/release-notes.mdx`: Document authoritative agent-visible
inference route health.
- [#6421](#6421) ->
`docs/about/release-notes.mdx`: Record the longer quiet-pull window for
managed vLLM images.
- [#6431](#6431) ->
`docs/inference/model-capability-audit.mdx`,
`docs/about/release-notes.mdx`: Document the version-pinned Nemotron
Ultra profile plugin.
- [#6439](#6439) ->
`docs/about/release-notes.mdx`: Summarize the authenticated, pinned
credential-capture helper boundary.
- [#6450](#6450) ->
`docs/manage-sandboxes/messaging-channels.mdx`,
`docs/reference/commands.mdx`, `docs/about/release-notes.mdx`: Document
host-forward cleanup and ownership-safe gateway-port release.
- [#6474](#6474) ->
`docs/manage-sandboxes/messaging-channels.mdx`,
`docs/about/release-notes.mdx`: Record composable OpenClaw messaging
runtime loaders.
- [#6475](#6475) ->
`docs/about/release-notes.mdx`: Record removal of the unavailable Kimi
K2.6 production endpoint option.
- [#6480](#6480) ->
`docs/about/release-notes.mdx`: Record stderr routing for the plugin
registration banner.
- [#6481](#6481) ->
`docs/about/release-notes.mdx`: Record post-pull Ollama model discovery
checks.
- [#6482](#6482) ->
`docs/about/release-notes.mdx`: Record Ollama model warm-up after daemon
restart.
- [#6486](#6486) ->
`docs/about/release-notes.mdx`: Publish the opt-in, thread-scoped Deep
Agents auto-approval boundary.
- [#6490](#6490) ->
`docs/about/release-notes.mdx`: Record diagnostics for custom images
missing the managed runtime.
- [#6494](#6494) ->
`docs/inference/model-capability-audit.mdx`,
`docs/about/release-notes.mdx`: Document nonempty tool-call content
preservation and placeholder rejection.
- [#6497](#6497) ->
`docs/get-started/quickstart-langchain-deepagents-code.mdx`,
`docs/about/release-notes.mdx`: Document isolated Deep Agents
route-probe output.
- [#6506](#6506) ->
`docs/get-started/quickstart-langchain-deepagents-code.mdx`,
`docs/about/release-notes.mdx`: Document observability-preserving
managed route probes.
- [#6508](#6508) ->
`docs/about/release-notes.mdx`: Link the new extension taxonomy and
SDK-readiness reference from the release summary.

Release-source verification: GitHub reports all 29 cited source PRs as
merged with base `main`, and every merge commit is an ancestor of
`origin/main` at `17bf9a6a9688b3b1d69cf4b37d3f23110acb055e`. No
source-mapping mismatches were found.

## Type of Change

- [ ] Code change (feature, bug fix, or refactor)
- [ ] Code change with doc updates
- [ ] Doc only (prose changes, no code sample modifications)
- [x] Doc only (includes code sample changes)

## Quality Gates

<!-- Check exactly one tests line and one docs line. Check other lines
when applicable. Add every requested justification or approval
reference. -->
- [ ] Tests added or updated for changed behavior
- [ ] Existing tests cover changed behavior — justification:
- [x] Tests not applicable — justification: Documentation-only
release-prep changes; `npm run docs` validates variants, routes, and
Fern content.
- [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

<!-- 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 the DCO sign-off declaration 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: Tests
are not applicable to this documentation-only change set.
- [ ] 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) — exited
0 with zero errors; Fern reported the existing unauthenticated
redirect-check and light-mode contrast 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)

---
<!-- 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: Charan Jagwani <cjagwani@nvidia.com>

---------

Signed-off-by: cjagwani <cjagwani@nvidia.com>
Hadar301 pushed a commit to Hadar301/NemoClaw-OpenShift that referenced this pull request Jul 12, 2026
<!-- markdownlint-disable MD041 -->
## Summary
<!-- 1-3 sentences: what this PR does and why. -->
Fix `nemohermes stop` cleanup for Hermes sandboxes by stopping the
active agent gateway and its host forwards instead of only looking for
OpenClaw gateway processes. The fix also skips in-sandbox gateway
shutdown for terminal-only agents, so terminal agent sessions are not
accidentally killed.

## Related Issue
<!-- Fixes #NNN or Closes #NNN. Remove this section if none. -->
Fixes NVIDIA#6392

## Changes
<!-- Bullet list of key changes. -->
- Add agent-aware in-sandbox gateway stop patterns, including Hermes
`hermes.real gateway run`.
- Skip gateway process termination when the active agent has no gateway
runtime.
- Stop agent-declared host forwards plus the dashboard forward before
releasing the managed OpenShell gateway port.
- Run the OpenShell fallback stop script through stdin to avoid newline
argv issues.
- Add targeted coverage for Hermes stop, forward cleanup, terminal-agent
guard behavior, and gateway stop pattern generation.

## 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
<!-- Check exactly one tests line and one docs line. Check other lines
when applicable. Add every requested justification or approval
reference. -->
- [√] 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: shutdown cleanup behavior
changed, but no user-facing docs or commands changed.
- [√] 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
<!-- 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. -->
- [√] PR description includes the DCO sign-off declaration 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 — command/result or justification:
- [√] Applicable broad gate passed — `npm test` for broad
runtime/test-harness changes; `npm run check` for repo-wide
validation/coverage changes — command/result:
- [√] 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](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: Rui Luo <ruluo@nvidia.com>


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

* **New Features**
* Improved shutdown handling for sandbox gateways and host port
forwards, including better detection of which ports should be stopped.

* **Bug Fixes**
* Added safer fallbacks when gateway information is unavailable,
reducing the chance of stopping the wrong forward.
* Improved cleanup behavior when forwarded ports belong to another
sandbox or can’t be confirmed released.
* Refined shutdown flows for different agent/runtime types so
unsupported cases are skipped cleanly.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Signed-off-by: Rui Luo <ruluo@nvidia.com>
Signed-off-by: Aaron Erickson <aerickson@nvidia.com>
Signed-off-by: cjagwani <cjagwani@nvidia.com>
Co-authored-by: Aaron Erickson <aerickson@nvidia.com>
Co-authored-by: cjagwani <cjagwani@nvidia.com>
Hadar301 pushed a commit to Hadar301/NemoClaw-OpenShift that referenced this pull request Jul 12, 2026
<!-- markdownlint-disable MD041 -->
## Summary

Prepares the user documentation for NemoClaw v0.0.78 by replacing the
unreleased section with release highlights and synchronizing the
affected inference, lifecycle, messaging, and CLI reference pages with
merged behavior.

## Changes

- Publish the v0.0.78 release-notes section with links to the most
specific user guides for each shipped behavior.
- Document authoritative Deep Agents route health, Nemotron Ultra
profile behavior, and Hermes compatible-endpoint context metadata.
- Document forced rebuild recovery after total backup failure and the
ownership-safe tunnel/full-stop behavior.
- Keep command examples and shared agent variants aligned with the
current OpenClaw, Hermes, and Deep Agents interfaces.

Source mapping:

- [NVIDIA#3787](NVIDIA#3787) ->
`docs/about/release-notes.mdx`: Record reliable workspace template
seeding during sandbox startup.
- [NVIDIA#4960](NVIDIA#4960) ->
`docs/about/release-notes.mdx`: Record safer detection of rewritten
OpenClaw gateway processes.
- [NVIDIA#5676](NVIDIA#5676) ->
`docs/about/release-notes.mdx`: Record warning-tolerant agent-list JSON
handling.
- [NVIDIA#5857](NVIDIA#5857) ->
`docs/about/release-notes.mdx`: Record synchronization of explicit
OpenClaw main-agent model state.
- [NVIDIA#5929](NVIDIA#5929) ->
`docs/about/release-notes.mdx`: Record copyable SSH port-forward
guidance for remote dashboards.
- [NVIDIA#6068](NVIDIA#6068) ->
`docs/about/release-notes.mdx`: Record custom-image plugin provenance
reconciliation.
- [NVIDIA#6116](NVIDIA#6116) ->
`docs/about/release-notes.mdx`: Record live-loopback dashboard-forward
recovery.
- [NVIDIA#6122](NVIDIA#6122) ->
`docs/about/release-notes.mdx`: Announce validated, round-trippable
policy YAML output.
- [NVIDIA#6211](NVIDIA#6211) ->
`docs/manage-sandboxes/lifecycle.mdx`, `docs/reference/commands.mdx`,
`docs/about/release-notes.mdx`: Explain the explicit no-backup `rebuild
--force` recovery boundary.
- [NVIDIA#6283](NVIDIA#6283) ->
`docs/about/release-notes.mdx`: Record Hermes WebUI port alignment.
- [NVIDIA#6293](NVIDIA#6293) ->
`docs/inference/switch-inference-providers.mdx`,
`docs/about/release-notes.mdx`: Document compatible-endpoint
context-length probing for Hermes.
- [NVIDIA#6320](NVIDIA#6320) ->
`docs/about/release-notes.mdx`: Record bounded gateway-recovery waits.
- [NVIDIA#6377](NVIDIA#6377) ->
`docs/reference/commands.mdx`, `docs/about/release-notes.mdx`: Explain
rebuild diagnostics and prepared MCP-destroy recovery.
- [NVIDIA#6412](NVIDIA#6412) ->
`docs/get-started/quickstart-langchain-deepagents-code.mdx`,
`docs/about/release-notes.mdx`: Document authoritative agent-visible
inference route health.
- [NVIDIA#6421](NVIDIA#6421) ->
`docs/about/release-notes.mdx`: Record the longer quiet-pull window for
managed vLLM images.
- [NVIDIA#6431](NVIDIA#6431) ->
`docs/inference/model-capability-audit.mdx`,
`docs/about/release-notes.mdx`: Document the version-pinned Nemotron
Ultra profile plugin.
- [NVIDIA#6439](NVIDIA#6439) ->
`docs/about/release-notes.mdx`: Summarize the authenticated, pinned
credential-capture helper boundary.
- [NVIDIA#6450](NVIDIA#6450) ->
`docs/manage-sandboxes/messaging-channels.mdx`,
`docs/reference/commands.mdx`, `docs/about/release-notes.mdx`: Document
host-forward cleanup and ownership-safe gateway-port release.
- [NVIDIA#6474](NVIDIA#6474) ->
`docs/manage-sandboxes/messaging-channels.mdx`,
`docs/about/release-notes.mdx`: Record composable OpenClaw messaging
runtime loaders.
- [NVIDIA#6475](NVIDIA#6475) ->
`docs/about/release-notes.mdx`: Record removal of the unavailable Kimi
K2.6 production endpoint option.
- [NVIDIA#6480](NVIDIA#6480) ->
`docs/about/release-notes.mdx`: Record stderr routing for the plugin
registration banner.
- [NVIDIA#6481](NVIDIA#6481) ->
`docs/about/release-notes.mdx`: Record post-pull Ollama model discovery
checks.
- [NVIDIA#6482](NVIDIA#6482) ->
`docs/about/release-notes.mdx`: Record Ollama model warm-up after daemon
restart.
- [NVIDIA#6486](NVIDIA#6486) ->
`docs/about/release-notes.mdx`: Publish the opt-in, thread-scoped Deep
Agents auto-approval boundary.
- [NVIDIA#6490](NVIDIA#6490) ->
`docs/about/release-notes.mdx`: Record diagnostics for custom images
missing the managed runtime.
- [NVIDIA#6494](NVIDIA#6494) ->
`docs/inference/model-capability-audit.mdx`,
`docs/about/release-notes.mdx`: Document nonempty tool-call content
preservation and placeholder rejection.
- [NVIDIA#6497](NVIDIA#6497) ->
`docs/get-started/quickstart-langchain-deepagents-code.mdx`,
`docs/about/release-notes.mdx`: Document isolated Deep Agents
route-probe output.
- [NVIDIA#6506](NVIDIA#6506) ->
`docs/get-started/quickstart-langchain-deepagents-code.mdx`,
`docs/about/release-notes.mdx`: Document observability-preserving
managed route probes.
- [NVIDIA#6508](NVIDIA#6508) ->
`docs/about/release-notes.mdx`: Link the new extension taxonomy and
SDK-readiness reference from the release summary.

Release-source verification: GitHub reports all 29 cited source PRs as
merged with base `main`, and every merge commit is an ancestor of
`origin/main` at `17bf9a6a9688b3b1d69cf4b37d3f23110acb055e`. No
source-mapping mismatches were found.

## Type of Change

- [ ] Code change (feature, bug fix, or refactor)
- [ ] Code change with doc updates
- [ ] Doc only (prose changes, no code sample modifications)
- [x] Doc only (includes code sample changes)

## Quality Gates

<!-- Check exactly one tests line and one docs line. Check other lines
when applicable. Add every requested justification or approval
reference. -->
- [ ] Tests added or updated for changed behavior
- [ ] Existing tests cover changed behavior — justification:
- [x] Tests not applicable — justification: Documentation-only
release-prep changes; `npm run docs` validates variants, routes, and
Fern content.
- [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

<!-- 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 the DCO sign-off declaration 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: Tests
are not applicable to this documentation-only change set.
- [ ] 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) — exited
0 with zero errors; Fern reported the existing unauthenticated
redirect-check and light-mode contrast 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)

---
<!-- 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: Charan Jagwani <cjagwani@nvidia.com>

---------

Signed-off-by: cjagwani <cjagwani@nvidia.com>
@wscurran wscurran added area: cli Command line interface, flags, terminal UX, or output area: sandbox OpenShell sandbox lifecycle, runtime, config, or recovery bug-fix PR fixes a bug or regression integration: hermes Hermes integration behavior platform: macos Affects macOS, including Apple Silicon labels Jul 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: cli Command line interface, flags, terminal UX, or output area: sandbox OpenShell sandbox lifecycle, runtime, config, or recovery bug-fix PR fixes a bug or regression integration: hermes Hermes integration behavior platform: macos Affects macOS, including Apple Silicon

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[macOS][CLI&UX] nemohermes stop does not release port 8642 — SSH port-forward process survives after deprecated full stop

7 participants