Skip to content

fix(sdk): require image.ref on every runtime - #14564

Merged
cv merged 4 commits into
v1from
fix/14551-sdk-default-agent-image-nc
Nov 18, 2026
Merged

cv merged 4 commits into
v1from
fix/14551-sdk-default-agent-image-nc

Conversation

@deepujain

@deepujain deepujain commented Nov 17, 2026 •

Copy link
Copy Markdown
Collaborator

A sandbox now has to name its agent image on every runtime, as it already did on Kubernetes and OpenShift. The SDK no longer falls back to a default agent image that exists only on the host that built it.

Problem

On Docker and Podman, a sandbox that omitted image.ref got the digest pinned in versions.json, nc-fabric-owner-20260924@sha256:c4c0d3add.... No registry holds that image, so it resolved only on the machine that built it. Every example that left the image out depended on it.

Resolves #14551. #13516 tracks publishing agent images, and #14235 tracks the onboarding suggestion that depended on the default.

Change

  • image.ref is required for every sandbox. A missing image, an empty image: {} and an empty ref are all rejected, and the error links to the agent image build instructions.
  • images.agent is gone from versions.json, along with the SDK's DEFAULT_AGENT_IMAGE constant and the code that filled it in.
  • The Kubernetes rule now requires only image.metadata, since image.ref is required everywhere.
  • Examples, the live cases, the SDK fixture and the provider contract fixtures that omitted the image, or carried the old digest, use a placeholder digest of the form nc-fabric@sha256:000...0. The live workflows already replace that digest with the image they build. The schema and configuration reference are regenerated, and the docs no longer describe a default image.
  • Onboarding asks for the image reference without a suggestion, because there is no published image to suggest. The question follows the inference preset, and the review screen shows none for an empty reference. Onboarding suggests an agent image that can't be pulled; match the harness to a published image #14235 can add a suggestion once Publish the v1 container images with each release #13516 publishes images.
  • A new SDK test checks that every omitted or empty form of image fails on a Fabric runtime and on Podman. The onboarding and authoring tests answer the new question.

Left out: publishing agent images (#13516) and changing the onboarding suggestion (#14235). Both stay with their issues.

Beyond CI

Nothing here needs a live run. The SDK, authoring and onboarding suites, the schema check and Clippy passed locally. The tests that need a local socket, a Git hook directory or a live engine could not run in my sandbox and are left to CI.

Summary by CodeRabbit

  • New Requirements
    • Every sandbox must specify an agent image with an immutable, SHA-256-pinned reference. Configurations that omit the image or provide an empty reference are rejected; no default agent image is supplied.
  • Documentation
    • Updated configuration guidance and examples to show where to provide an image reference and how to replace placeholder digests with the digest of a built agent image.
    • Clarified that the required image reference applies across runtimes.

A sandbox now has to name its agent image on every runtime, as it already
did on Kubernetes and OpenShift. The SDK no longer falls back to a default
agent image that exists only on the host that built it.

## Problem

On Docker and Podman, a sandbox that omitted `image.ref` got the digest
pinned in `versions.json`, `nc-fabric-owner-20260924@sha256:c4c0d3add...`.
No registry holds that image, so it resolved only on the machine that built
it. Every example that left the image out depended on it.

Resolves #14551. #13516 tracks publishing agent images, and #14235 tracks
the onboarding suggestion that depended on the default.

## Change

- `image.ref` is required for every sandbox. A missing `image`, an empty
  `image: {}` and an empty `ref` are all rejected, and the error links to
  the agent image build instructions.
- `images.agent` is gone from `versions.json`, along with the SDK's
  `DEFAULT_AGENT_IMAGE` constant and the code that filled it in.
- The Kubernetes rule now requires only `image.metadata`, since `image.ref`
  is required everywhere.
- Examples, the live cases, the SDK fixture and the provider contract
  fixtures that omitted the image, or carried the old digest, use a
  placeholder digest. The schema and configuration reference are
  regenerated, and the docs no longer describe a default image.
- Onboarding asks for the image reference without a suggestion until a
  published image exists (#14235).

Signed-off-by: Deepak Jain <[email protected]>
@copy-pr-bot

copy-pr-bot Bot commented Nov 17, 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.

@github-actions

Copy link
Copy Markdown
Contributor

@deepujain

Copy link
Copy Markdown
Collaborator Author
Authoring session — opening
Field Status Value Evidence or limit
Harness unavailable - Authoring harness evidence unavailable.
Skills unavailable - Authoring instruction evidence unavailable.
Instruction files unavailable - Authoring instruction-file evidence unavailable.
Tool calls unavailable - Authoring tool invocation evidence unavailable.
Tokens unavailable - Authoring token usage counters unavailable.
Session window unavailable - Authoring session timestamps unavailable.
Compactions unavailable - Authoring compaction evidence unavailable.
Models unavailable - Authoring model history unavailable.
Reasoning levels unavailable - Authoring reasoning-level history unavailable.

The integration scenarios `docker-openclaw-ollama`, `docker-ollama-proxy`
and `docker-hosted-ollama-two-agents` name the inference resources they
assert on with a hash that depends on the sandbox's image. The change that
requires `image.ref` gave those cases an explicit placeholder image, which
changed the hash, so each scenario referenced an `openshell_inference`
resource that no longer exists and failed in its `verify` run.

The scenarios now use the names the SDK compiles for the new image:
`local-d6ca74ad95e4f1d5f302f50e` for the two single-agent cases, and
`local-a21c64a088f98c60f915f82e` and `nvidia-7b10beb441f87130e1c5dc67` for
the two-agent case. `local-d6ca74ad95e4f1d5f302f50e` is also the name in the
regenerated `local` contract fixture.

Signed-off-by: Deepak Jain <[email protected]>
@deepujain
deepujain marked this pull request as ready for review November 17, 2026 23:39
@deepujain

Copy link
Copy Markdown
Collaborator Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor
Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai

coderabbitai Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

Every sandbox now requires an explicit SHA-256-pinned image reference. The SDK no longer provides a default agent image. Validation, onboarding tests, examples, documentation, and provider and end-to-end fixtures have been updated.

Changes

Required sandbox image contract

Layer / File(s) Summary
SDK image contract and validation
crates/nemoclaw-sdk/build.rs, crates/nemoclaw-sdk/src/config/*, crates/nemoclaw-sdk/tests/*, crates/nemoclaw-sdk/tests/fixtures/config/inline-recipe.yaml, schemas/nemoclaw-v1alpha1.schema.json, versions.json
The SDK removes its default agent image and requires a SHA-256-pinned image reference for each sandbox. Validation and tests now reject missing or empty image references.
Configuration examples and guidance
examples/*, examples/onboarding/*, examples/spark/*, docs/agents-inference/inference.md, docs/build-deploy/build.md, docs/reference/configuration.md, docs/references/sdk.md
Examples add placeholder image digests. Documentation states that every sandbox needs an explicit image reference and that the SDK publishes no default image.
Onboarding image entry and review
crates/nemoclaw-onboarding/src/tui/*, crates/nemoclaw-authoring/tests/journey_resolution.rs
Onboarding tests answer the image-reference question and check that the reference appears in review. The summary no longer labels a reference as the default image.
Provider and integration fixtures
crates/openshell-provider/tests/contract/fixtures/*, crates/nemoclaw-e2e/cases/*, crates/nemoclaw-e2e/tests/integration/hcl/*
Fixtures add explicit image references and update inference resource identifiers and references. Existing integration assertions use the updated identifiers.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Change: Bug fix · Severity of issue fixed: Medium

Possibly related issues

Merge Risk: Minimal · up to d2015

Every sandbox must now provide a SHA-256-pinned image.ref, and the SDK no longer supplies a default agent image. Examples, fixtures and docs were updated consistently, and no remaining dependency on the removed default was found.

Security architecture risk: Minimal · up to bb10d

Requiring an explicit digest-pinned image removes a hidden fallback and rejects incomplete configurations earlier. The inspected changes do not establish a new security bypass, broader image-selection authority or weakened recovery guarantee. Existing configurations that relied on the fallback must supply an image reference.

Retained concerns
No architecture-level concerns identified.

Security review details

Security Blast Radius

  • inferred — The changed boundary affects configuration authors and SDK consumers across runtimes. At the inspected image-selection boundary, authors could already specify images explicitly, so requiring that choice does not establish newly granted image-selection authority.

Trust Boundaries and Controls

  • observed — Required-field and digest-format checks apply globally rather than depending on the selected runtime. The cluster metadata control remains additional to those checks.

Resilience and Maintainability Implications

  • observed — The inspected journey update path validates answers before committing a cloned candidate. Successful answers, backtracking and new observations invalidate cached results. The terminal serializes interactions, returns no configuration on cancellation, and obtains validated saved YAML only after acceptance.
Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title "fix(sdk): require image.ref on every runtime" matches the main change. The PR makes image.ref required for every sandbox runtime, removes the DEFAULT_AGENT_IMAGE constant and the images.age…
Linked Issues check Passed Issue #14551 has four coding requirements. Each one maps to the reviewed head.
(1) Require image.ref on every runtime: the whole-PR summary shows validation.rs now requires image.ref for every sandbox…
Out of Scope Changes check Passed The changes map to #14551 objectives or to supporting work they require. Removing DEFAULT_AGENT_IMAGE requires the onboarding summary and TUI tests (tui/summary.rs, tui/tests.rs) to stop using it. Doc…
Full details: Title check

Explanation

The title "fix(sdk): require image.ref on every runtime" matches the main change. The PR makes image.ref required for every sandbox runtime, removes the DEFAULT_AGENT_IMAGE constant and the images.agent entry in versions.json, and adds validation that rejects missing, empty, or non-pinned image references. The title is short, specific, and uses a conventional commit prefix that scopes the change to the SDK.

Full details: Linked Issues check

Explanation

Issue #14551 has four coding requirements. Each one maps to the reviewed head.
(1) Require image.ref on every runtime: the whole-PR summary shows validation.rs now requires image.ref for every sandbox, validates it against the image pattern, and attaches the build-instructions error. The schema adds image to the sandbox required properties. The Kubernetes/OpenShift rule now requires only image.metadata. The SDK test in tests/config_input.rs covers omitted image, empty image object, and empty ref for fabric-openclaw.yaml and managed-podman.yaml. The incremental diff of validation.rs from the previous reviewed head is empty, so the earlier conclusion for that file still holds.
(2) Remove images.agent and DEFAULT_AGENT_IMAGE: the summary shows removal from versions.json, build.rs, config/mod.rs, and the onboarding summary (tui/summary.rs).
(3) Validation error links to the agent image build instructions: the shared image-reference error constant carries the link, and config_input tests assert the build-instructions text. The docs anchor itself was not checked against source.
(4) Spark examples and test fixtures that omit the image use a placeholder digest: examples/spark/vllm.yaml, examples/spark/remote-vllm.yaml, and the SDK and provider contract fixtures use nc-fabric@sha256:0...0.
The whole-PR diff could not be read in this review; the base blobs were unavailable. Conclusions rely on the whole-PR summary and the unchanged validation.rs increment. The author-reported live loading check (Docker and Podman rejected after the change) is consistent with these conclusions. Local socket, Git hook, and live engine tests were not run and are not verified here.

Full details: Out of Scope Changes check

Explanation

The changes map to #14551 objectives or to supporting work they require. Removing DEFAULT_AGENT_IMAGE requires the onboarding summary and TUI tests (tui/summary.rs, tui/tests.rs) to stop using it. Docs, schemas, and configuration reference describe the required image. Authoring journey, SDK harness, config tests, and e2e cases now supply an explicit image. The inference resource identifier renames in the provider contract fixtures and e2e tftest files are a derived consequence of the new placeholder image, as the commit message states; the generator was not traced in this review. The onboarding suggestion belongs to #14235 and is not implemented here, which matches the PR description. No change was found that lacks a connection to #14551. The whole-PR diff could not be read, so this conclusion rests on the whole-PR summary.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

A rabbit pins an image tight,
With SHA-256 in sight.
No default burrow fills the gap,
Each sandbox gets its own map.
The tests hop through the setup line,
And docs now mark the image sign.

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Enterprise
  • Run ID: 5da0f87c-f45c-44a2-a3bf-88083025a207
Commits

Reviewing files that changed from the base of the PR and between bb10d8c and d201574.

Files selected for processing: 1

  • versions.json
Files with no reviewable changes: 1

  • versions.json

Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 10 remain after this review.

@deepujain

Copy link
Copy Markdown
Collaborator Author

I used the real Rust SDK to load the same Docker and Podman YAML files on both revisions, with the Docker image omitted and the Podman image reference empty. I also built the docs through the repository's Fern workflow and opened the changed image build guide.

Before (base of this PR): both files were accepted, and the program printed "Loaded image.ref: nc-fabric-owner-20260924@sha256:c4c0d3add3869e49d0ce8d03bd7e41bbe2682d0df285ef6fde5f181b123cf83e". The guide said "Examples that omit image use the generic default agent image pin from versions.json."

14564-before

After (this PR): both files were rejected during loading with "image.ref must name an agent image pinned by a SHA-256 digest; no default image is published, so build one as described at https://github.com/NVIDIA/NemoClaw/blob/v1/docs/build-deploy/build.md#build-agent-images". The guide now says "Every sandbox requires image.ref; no default agent image is published."

14564-after

@deepujain
deepujain requested review from cv and kaofelix November 18, 2026 02:55
…gent-image-nc

Bring the branch up to date with v1 so it no longer conflicts.

The only conflict was in `versions.json`. v1 moved the OpenShell gateway,
supervisor, sandbox runtime and chart images to the 0.1.9 digests, and this
branch removed `images.agent`, because the SDK no longer defaults the agent
image. The resolution keeps v1's new digests and leaves `images.agent` out.

The inference resource names the SDK compiles depend on the sandbox image
reference and the harness, not on `versions.json`, so they are unchanged by
the merge. Regenerating the OpenShell contract fixtures produced no
differences, and the hand-written Ollama integration scenarios keep the
names they already use.

Signed-off-by: Deepak Jain <[email protected]>
@deepujain

Copy link
Copy Markdown
Collaborator Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor
Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Add a breaking-change release note: the SDK no longer supplies a default
agent image, so every sandbox must name one pinned by digest on every
runtime, and the Rust SDK drops config::DEFAULT_AGENT_IMAGE.

Signed-off-by: Carlos Villela <[email protected]>
@cv cv added this to the Roadmap: GTC DC 2026 milestone Nov 18, 2026
@cv
cv enabled auto-merge (squash) November 18, 2026 06:35
@cv
cv merged commit 7171b39 into v1 Nov 18, 2026
74 checks passed
@cv
cv deleted the fix/14551-sdk-default-agent-image-nc branch November 18, 2026 06:46
cv added a commit that referenced this pull request Nov 18, 2026
…n harness (#14579)

`nemoclaw onboard` now suggests, at the sandbox image question, a local
agent image that installs the chosen harness, pinned by digest, and
links the build instructions when the gateway's engine has none.

## Problem

Since #14564, every sandbox must
set `image.ref`, and onboarding asks for it with no suggestion, or with
the template's placeholder digest, even on a host whose engine holds
images built with `cargo images build` for the chosen harness. The user
has to find the digest with `docker image inspect` and paste it.

Part of #14235: this covers
matching the harness to local images. Suggesting published images waits
for #13516. Skipping the
question when exactly one image fits, and naming a missing image in the
review, are left for later.

## Change

- The SDK's discovery gains an `AgentImages` read for one engine and one
Fabric adapter. It returns, newest first, the digest reference
(`NAME@sha256:DIGEST`) of each image whose `io.nemoclaw.fabric.catalog`
label installs that adapter's runtime. It lists images through the
existing engine client, filtered by the label. An image without a
repository digest, as in Docker's classic image store, can't be pinned
and is left out. Plans never make this read.
- Onboarding makes the read at a sandbox image question once the
gateway's engine and the harness are authored. One function maps the
question to its read for both the TUI and the journey.
- The question offers those references as choices and suggests the
newest, unless its suggestion, such as a template's, is one of them.
With none, its note links [Build Agent
Images](https://github.com/NVIDIA/NemoClaw/blob/v1/docs/build-deploy/build.md#build-agent-images).
The question never offers an image the engine didn't list or one for
another harness.
- Matching uses the adapter IDs in each image's label, so it needs no
list of harnesses.
- Docs: the onboarding guide's target checks, the build page, the design
notes, and a release note.

Without discovery, or before the engine is known (several engines
answered for the runtime, so the engine question comes after the image
question), the image question is unchanged.

## Beyond CI

On a Linux host with Docker's containerd image store and locally built
agent images, `nemoclaw onboard` with Hermes listed the Hermes images by
digest and suggested the newest. With
`examples/onboarding/openclaw.yaml`, the newest local OpenClaw image
replaced the template's placeholder digest as the suggestion. Accepting
the suggestion reached the review; the image check that runs on saving
was not exercised. Podman was not tried.

---------

Signed-off-by: Carlos Villela <[email protected]>
@cv cv added the v1 NemoClaw v1 branch label Nov 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

v1 NemoClaw v1 branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants