sandbox: a manifest is pinned only when its image AND every feature are digest-addressed #270

Merged
dcharlot merged 1 commit from fix/manifest-pinned-means-pinned into main 2026-10-15 22:35:42 -04:00

2026-10-15

Transaction Science
sandbox: a manifest is pinned only when its image AND every feature are digest-addressed
Some checks failed
repository checks / lockfiles, tests in CI, workflow hygiene, spec and section references, public text (pull_request) Successful in 55s
standards workspaces build + test / which workspaces this change touches (pull_request) Successful in 5s
standards workspaces build + test / joule-code-rs (joule-code/joule-code-rs, joule-code-rs, linux-arm64, true) (pull_request) Successful in 2m2s
standards workspaces build + test / joulecontract-rs (joulecontract/joulecontract-rs, joulecontract-rs, linux-arm64, true) (pull_request) Successful in 1m42s
standards workspaces build + test / macOS energy backends (pull_request) Successful in 6m24s
standards workspaces build + test / jouledesk-rs (jouledesk/jouledesk-rs, jouledesk-rs, macos) (pull_request) Successful in 1m26s
standards workspaces build + test / jcp-rs (jcp-conformance, jcp/jcp-rs, -p jcp-energy --features nvml, jcp-rs, linux) (pull_request) Failing after 1m7s
standards workspaces build + test / joule-ui-rs (joule-ui/joule-ui-rs, joule-ui-rs, linux) (pull_request) Successful in 1m16s
standards workspaces build + test / proof-rs (proof-conformance, proof/proof-rs, proof-rs, linux, true) (pull_request) Successful in 1m32s
standards workspaces build + test / sandbox-rs (sandbox-conformance, sandbox/sandbox-rs, sandbox-rs, linux) (pull_request) Successful in 2m31s
`EnvironmentManifest::is_pinned()` checked the base image's digest alone,
while its doc promised "fully pinned" and "same address ⇒ same bytes". Its
own test asserted it true for a manifest whose features were `rust:1` and
`node:1`. Those are tags, which resolve to whatever was last pushed under
them, so two hosts can run different toolchains under one address. The
spec repeated the overclaim: it called such a manifest pinned, and so fit
for a cross-host "same environment" claim.

- `Feature::is_pinned()`: the reference carries an `@sha256:` digest.
- `EnvironmentManifest::is_pinned()`: the image and every feature are
  digest-addressed. `image_pinned()` is the old image-only check.
- Its docs, the spec (spec/environment-manifest.md, SPEC §14): pinned means
  the whole toolchain. Mounted content is data and never part of the
  address, so a pinned manifest says nothing about what its mounts hold.
- C7 conformance checks the image (as it always said it did), that a
  feature by tag leaves the manifest unpinned, and that digest features pin
  it.

Pinned-ness is not in the manifest core, so no content address or vector
changes.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-15 20:50:37 -04:00