Skip to content

fix: rehearse agent access and diagnostics, and fix what it found - #13466

Merged
cv merged 1 commit into
v1from
docs/rehearse-access
Oct 19, 2026
Merged

cv merged 1 commit into
v1from
docs/rehearse-access

Conversation

@cv

@cv cv commented Oct 19, 2026

Copy link
Copy Markdown
Collaborator

Closes #12642.

Failure

I rehearsed the documented access and diagnostics procedures as written: the first-deployment guide's steps 4 and 5, the request sections in agents.md, and the troubleshooting and recovery procedures. I used the OpenShell CLI matching versions.json (v0.1.4) on a NemoClaw-managed Docker gateway, with Hermes, Deep Agents and Pi against the hosted NVIDIA endpoint. The guide deploys OpenClaw, which can't start yet (#13372), so I swapped the harness. A managed gateway on loopback stands in for the guide's external one; access works the same way.

What failed as written:

  1. The documented request fails on every image. openshell sandbox exec … -- fabric-agent-ctl invoke exits 127, fabric-agent-ctl: command not found, because the tool is only at /opt/fabric/bin/fabric-agent-ctl, off the default PATH.
  2. The documented recovery for a dead sandbox couldn't complete. After a sandbox exits, plans fail with sandbox unavailable: SANDBOX_PHASE_ERROR, and the recovery is whole-deployment destroy, then reapply. But destroy stopped at the agent with observation query failed: removing an agent ran fabric-agent-ctl stop in the dead sandbox. That left the deployment in "unfinished destroy", which blocked every operation.
  3. Pi failed every request with pi_model_error unless its model's input and cost were set. Fabric's schema lists both as optional.
  4. The docs didn't distinguish the two statuses in a result. The outer status: succeeded only means fabric-agent-ctl completed the call; Pi's failed run was in result.status: failed.

Decision

  • Image: runtime-base links /usr/local/bin/fabric-agent-ctl to /opt/fabric/bin/fabric-agent-ctl, so commands in the sandbox find Fabric's sandbox host on the default PATH. Derived images inherit the link.
  • Fabric provider: stop_agent treats a sandbox that has exited as already stopped, since its runtime went with it, so removing the agent succeeds and the sandbox's own deletion proceeds. A new fake-gateway test, which failed before the change, covers the Error and Completed phases.
  • Docs:
    • The Pi section and examples/fabric-pi.yaml set input and cost as well as context_window.
    • agents.md and the first-deployment guide say to check result.status and result.artifacts.
    • Troubleshooting's log section covers OpenShell's sandbox log (openshell logs SANDBOX --source sandbox), files named in result.artifacts, and Fabric's message in diagnostics/fabric-SANDBOX.json. The failure table covers SANDBOX_PHASE_ERROR.
    • The replacement procedure in usage.md now covers any unusable runtime or exited sandbox, not only OpenClaw.
    • The prerequisites link OpenShell's installer (OPENSHELL_VERSION=v0.1.4) and its authentication guide (openshell gateway add for mTLS or OIDC), and the interfaces page links the same guide.
    • Claims of unrehearsed procedures are removed. limits.md keeps the OpenClaw walkthrough (OpenClaw does not start in OpenShell sandboxes with Fabric v0.5.0 #13372) and an external-gateway rehearsal (Qualify more platforms, placements, models, and integrations #12641).
    • The examples/fabric-pi.yaml fixture is regenerated.

Validation

  • Rehearsed: steps 4 and 5 of the first-deployment guide, run as written apart from the harness swap and the managed gateway:
    • Hermes: reply in 2.7 s.
    • Deep Agents: reply in 1.5 s, after a 13 s apply that replaced the sandbox.
    • Pi: reply after adding input and cost.
    • After the image link: the bare fabric-agent-ctl command works exactly as documented.
  • Diagnostics:
    • openshell logs --source sandbox on a running and an exited sandbox;
    • a forced validation failure, whose error named diagnostics/fabric-assistant.json (mode 600, holding Fabric's message);
    • a killed sandbox: plan reported SANDBOX_PHASE_ERROR, the resumed destroy completed with the fix, reapply recovered, and the agent answered.
  • cargo ci passes locally: 1,599 unit tests and 150 lifecycle tests. fern check reports 0 errors.

Not done here

  • A dead sandbox: arguably should plan as a replacement instead of failing the plan.
  • CLI output: labels the agent's configuration as terraform_data.agent_<name> rather than a readable name.
  • Pi's input and cost: the gap between Fabric's schema and Pi's behavior is Fabric's.
  • examples/managed-hermes.yaml: pairs Hermes with an 8,192-token context, below Hermes's 64,000-token minimum.

Commands run in the sandbox now find fabric-agent-ctl on the default PATH.
Removing an agent whose sandbox exited no longer runs stop in it, so destroy
completes and the documented recovery works. The docs set Pi's input and
cost, check result.status, and describe the logs and diagnostics that the
rehearsal used.
@cv
cv enabled auto-merge (squash) October 19, 2026 10:38
@github-actions

Copy link
Copy Markdown
Contributor

@cv
cv merged commit 524efa2 into v1 Oct 19, 2026
@cv
cv deleted the docs/rehearse-access branch October 19, 2026 10:52
@wscurran wscurran added area: docs Documentation, examples, guides, or docs build area: sandbox OpenShell sandbox lifecycle, runtime, config, or recovery bug-fix PR fixes a bug or regression platform: container Affects Docker, containerd, Podman, or images v1 NemoClaw v1 branch labels Oct 23, 2026
@cv cv added this to the Roadmap: GTC DC 2026 milestone Nov 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: docs Documentation, examples, guides, or docs build area: sandbox OpenShell sandbox lifecycle, runtime, config, or recovery bug-fix PR fixes a bug or regression platform: container Affects Docker, containerd, Podman, or images v1 NemoClaw v1 branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants