Repository navigation
feat(deps): adopt spec v0.2026322.1814 + sdk v0.2026322.1853, and ask the contract for the resource-kind set (TODO 3.1, leg 3 of 3) - #1209
Conversation
… the contract for the resource-kind set (TODO 3.1, leg 3 of 3) Two units in one change because either alone is red. PIN BUMP, PAIRED. spec v0.2026322.1239 predates spec.ResourceKindSet (spec#381's tag), so the one-line swap cannot compile at the old pin. Bumping spec ALONE also fails, and the reason is a finding about the org's dependency shape rather than about this repo: charly pins sdk v0.2026322.1227, whose kit/checkvars.go still reads meta.AcmeEmail — the field spec#379 deleted. The deletion reached this repo THROUGH the sdk pin, two hops from the repo that made it. Not a consumer: a consumer's consumer. So spec and sdk travel together (sdk v0.2026322.1853 carries the acme adaptation and leg 2 of this cutover), and the pair is the only state in which the build is green. THE SWAP. charly derived its own copy of the #ResourceKind membership at init: resourceKindSet = setFromSlice(spec.ResourceKinds) // reserved_registry.go:46 Two live predicates read it — isExternalDeploySubstrate (plugin_prescan.go) and unresolvedDeployTargetError (unified_targets.go) — plus two test fixtures. All four now ask spec.ResourceKindSet(), and the copy is gone. setFromSlice stays standing for its four other callers (authoredOpFieldSet and a two-vocabulary consistency check). RED-first, behavioural. The test moves spec.ResourceKinds and asks unresolvedDeployTargetError, whose two outcomes differ by WORDING rather than by a returned token. Before the change the stale snapshot answers with the typo branch and enumerates the words it knows: unknown target "resourcekindtest" (want local|vm|pod|kubernetes|android) After it, the same call reaches the "known substrate, no plugin serves it" branch. The control asserts an undeclared word still classifies as unknown. Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)
Review — PASSHead SHA: Security screen: PASS — no secrets/exfiltration, no guardrail weakening, no scope mismatch; the two pin moves are the stated purpose (T3 supply-chain reviewed, coherent). Change class: behaviour + dependency pins (Go core). The diff matches the body exactly: paired Non-blocking notes (do not change the verdict):
Verdict: PASS ollama-cloud/deepseek-v4.1-flash — action-review. |
|
TAKING OVER — authority: lead integrating a red class gate on an inactive author.
$ git -C charly show origin/main:tools/gomod-canonical/go.mod | grep opencharly
github.com/opencharly/sdk v0.2026322.1227 // indirect
github.com/opencharly/spec v0.2026322.1239 // indirectPre-existing on gomod_canonical_test.go:123: ../../tools/gomod-canonical/go.mod: requires sdk v0.2026322.1227,
but the shared sdk pin is … — run `charly task mods-tidy`I am applying it in this PR rather than filing it, for the reason R1 gives: this change's class gate is red because of it, so it is blocking, and it is fixed here whoever caused it. The body will say so with that measurement, and Agent: lead |
`charly`'s `go` workflow runs `Test tools modules`, and four of the five fail it on `origin/main` (`992ae979`): `tools/generate-packages`, `tools/golden-cloudinit`, `tools/golden-compile` and `tools/gomod-canonical` still require `sdk v0.2026322.1227` / `spec v0.2026322.1239` while the core module pins `sdk v0.2026322.1853` / `spec v0.2026322.1814`. Applied with the test's own named remedy, `charly task mods-tidy` (2 steps, 0 failed), run from this worktree's binary. `gomod-canonical`'s requires were indirect and nothing in that module imports either contract, so tidy drops them and the module leaves the lockstep glob — which is why the module named after the gate ends up carrying no pin of its own. Pre-existing, not introduced here: measured at `origin/main` before this branch was touched. It lands in this change because this change's class gate is red because of it. GOWORK=off go test ./... returns rc=0 in all five tools modules. Assisted-by: DeepSeek Harness deepseek-v4.1-flash (analysed on a live system)
Review — PASSHead SHA: Security screen: PASS — first-party pin bumps ( Comments considered
Non-blocking notes
Verdict: PASS ollama-cloud/deepseek-v4.1-flash — action-review. |
## Summary The compiled-in build drive advances to the merged `candy/plugin-build/v0.2026322.2319` (opencharly/plugin-build#60, squash `16b57922375cfba3592d34dd2098230dc3ed8973`, tag `v2026.322.2319`), so the `charly` binary links the build resolve that stops a caller's `--tag` from renaming a borrowed builder node. **The pin, before and after — two files, +3/−3.** | File | Before | After | |---|---|---| | `charly/go.mod:16` `github.com/opencharly/plugin-build/candy/plugin-build` | `v0.2026322.1325` | `v0.2026322.2319` | | `charly/go.sum:160` (module hash) | `v0.2026322.1325 h1:p4aD3N4f…` | `v0.2026322.2319 h1:0vCOtaaS2uzkFSr9wHDaiDLIloZ6KT4PjrLiOd9u+N4=` | | `charly/go.sum:161` (`/go.mod` hash) | `v0.2026322.1325/go.mod h1:du0+Gb9s…` | `v0.2026322.2319/go.mod h1:du0+Gb9slRRh4VfSg9Lwex94TLHA7jrw9UD7tJkkWIE=` | The base moved since issue #1208 was last described: `origin/main` no longer carries `v0.2026317.2215` — charly#1204's squash (CHANGELOG `2026.322.1604`, merged 2026-11-18T16:04Z) advanced that require to `v0.2026322.1325`. This leg is therefore a **one-tag** delta (`1325` → `2319`), not two, and the brief's `v0.2026317.2215` is stale rather than a second bump. **What the bump delivers.** plugin-build#60 splits the two tag roles the resolve always had. `borrowedTag` — `buildkit.ComputeCalVer()`, computed once per resolve — stays on every box the build does **not** produce: a builder borrowed from another repository's namespace, and any auto-intermediate off a target's own chain. `targetTag` — the caller's `req.Tag` from `charly box build <box> --tag <t>` — is stamped on exactly the boxes the build **produces**, and the resolve's output set is promoted to it after the fact. So a check bed's `--tag check-comfyui-pod-<calver>` no longer renames `arch-builder`, and the emitted Containerfile no longer names `ghcr.io/opencharly/arch-builder:check-comfyui-pod-<calver>` — a ref no registry serves, which died as `failed to resolve source metadata: … not found` even though the image was in the local store under its own tag (#1208). DESIGN.md **D-KIND-2** — vocabulary data is nodes in the repositories that own it — is the requirement this obeys: a caller's tag has no business renaming another repository's node. **Nothing else moves.** `plugin-build`'s own `go.mod` is byte-identical between the two tags (its `/go.mod` checksum `du0+Gb9slRRh4VfSg9Lwex94TLHA7jrw9UD7tJkkWIE=` is unchanged at both pins), so this bump drags no `sdk`/`spec`/plugin pin with it. Confirmed against the tree: the only three occurrences of the old version string outside `CHANGELOG/` were the three lines above. ## How tested On branch `chore/pin-plugin-build`, in the session worktree off `origin/main` (`5286f448712328a45d5d3d42cde86377677de639`). This repo's declared gate for the class (`AGENTS.md`: `go build`, `go vet`, `gofmt`, `go test`, then `charly box validate`, then the org-wide `charly/pr-validator`) plus this repo's own witness bed for a pin adoption, `check-wave-pins`, run on that tree. The tag is the merged one, read from the remote and from the proxy — not taken from the brief: ```console $ git ls-remote --tags https://github.com/opencharly/plugin-build | tail -2 09de5ec84d1189861a239ea6ba77859abd71f2a3 refs/tags/v2026.322.1325 16b57922375cfba3592d34dd2098230dc3ed8973 refs/tags/v2026.322.2319 $ go list -m -versions github.com/opencharly/plugin-build/candy/plugin-build | tr " " "\n" | tail -3 v0.2026319.1655 v0.2026322.1325 v0.2026322.2319 ``` The bump, and the module graph after it: ```console $ go get github.com/opencharly/plugin-build/candy/[email protected] go: downloading github.com/opencharly/plugin-build/candy/plugin-build v0.2026322.2319 go: upgraded github.com/opencharly/plugin-build/candy/plugin-build v0.2026322.1325 => v0.2026322.2319 $ go mod tidy; echo "tidy rc=$?" tidy rc=0 $ grep -n 'plugin-build' go.sum 160:github.com/opencharly/plugin-build/candy/plugin-build v0.2026322.2319 h1:0vCOtaaS2uzkFSr9wHDaiDLIloZ6KT4PjrLiOd9u+N4= 161:github.com/opencharly/plugin-build/candy/plugin-build v0.2026322.2319/go.mod h1:du0+Gb9slRRh4VfSg9Lwex94TLHA7jrw9UD7tJkkWIE= ``` The go gate, on the tree this commit carries: ```console $ go build ./...; echo "build rc=$?" build rc=0 $ go vet ./...; echo "vet rc=$?" vet rc=0 $ gofmt -l .; echo "gofmt rc=$?" gofmt rc=0 $ go test ./... ok github.com/opencharly/charly/charly 242.459s ok github.com/opencharly/charly/charly/internal/pluginsgen 135.070s rc=0 ``` R9 — the binary is the worktree's own, rebuilt from this tree, and its stamp equals the source: ```console $ ./scripts/bootstrap-charly.sh bootstrap-charly: regenerating compiled-in plugin wiring bootstrap-charly: building bin/charly bootstrap-charly: built ./bin/charly (2026.322.2235) $ ./bin/charly version 2026.322.2235 $ git log -1 --format='%s (%ci)' docs: add CHANGELOG 2026.322.2235 for PR #1209 (2026-11-18 22:35:26 +0000) $ git status --short ``` `charly box validate` on the same binary: ```console $ ./bin/charly box validate; echo "validate rc=$?" charly box validate: OK — checked 548 candies, 107 boxes, 51 deploys, 6 distros, 7 builders; 0 warnings, 0 errors validate rc=0 ``` This repo's own witness bed for the change class, on the same tree — `check-wave-pins` (`kind: local`, `disposable: true`, `host: local`), whose header names exactly this class: ```console $ ./bin/charly check run check-wave-pins; echo "bed rc=$?" charly check run check-wave-pins: [deploy-add] PASS after 1m9.269s charly check run check-wave-pins: [bring-up-members] PASS after 3ms charly check run check-wave-pins: [check-live] PASS after 2m4.236s PASS the module graph the binary was built from carries the pins charly/go.mod declares [wp-pins] exit=0 PASS the adopted plugin-build ANSWERS in-process — `charly box generate` dispatches the compiled-in build-generate provider and renders a box Containerfile [wp-build-generate] exit=0 PASS the adopted plugin-vm ANSWERS in-process — `charly vm list` dispatches the compiled-in command:vm provider [wp-vm-list] exit=0 3 steps: 3 passed, 0 failed, 0 skipped charly check run check-wave-pins: [update] PASS after 41.804s charly check run check-wave-pins: [cleanup] PASS after 38.0s charly check run check-wave-pins: [cleanup-members] PASS after 0s charly check run check-wave-pins: PASS (steps=6) bed rc=0 ``` `.check/check-wave-pins/2026.322.2330/summary.yml`: `status: PASS`, `ok: true`, `diagnostics: errors 0, warnings 0`, `skipped_checks: 0`, `driver_version: 2026.322.2235`. What `wp-pins` asserts is the property a pin advance must have — the graph the BINARY was built from agrees with what this tree adopts, read from both sides rather than from a literal: ```console $ go version -m ./.worktrees/pin-plugin-build/charly/bin/charly | tr '\t' ' ' | grep plugin-build dep github.com/opencharly/plugin-build/candy/plugin-build v0.2026322.2319 h1:0vCOtaaS2uzkFSr9wHDaiDLIloZ6KT4PjrLiOd9u+N4= ``` and `wp-build-generate` shows the adopted module dispatching in-process: `charly box generate my-box` rendered `/tmp/charly-wave-pins-boxbed/.build/my-box/Containerfile`. ### What was NOT run, plainly **No `pod:` bed, and not issue #1208's own closure arm.** `charly check run check-comfyui-pod` is the bed that reproduces this defect end to end, and it cannot be resolved from any MERGED project closure: the bed lives only on the still-OPEN opencharly/distro-cachyos#206 (`fix/nvidia-cdi-pod-contract`), which adds the `check-comfyui-pod:` entity to that repo's `charly.yml`. `grep` over the merged `distro-cachyos` checkout and over this project's closure finds no such bed, so the verb has nothing to dispatch. That is why this commit carries `analysed on a live system` and not `fully tested and validated`, and why #1208 stays open with the live arm as its closure criterion. **No synthetic `--tag` build arm either**, and here is the measurement behind that: the discriminating arm needs a builder image that exists in local storage **under its own tag** so the resolve does not rebuild it (that is exactly the comfyui bed's situation). On this host the local store carries no `arch-builder`/`*-builder` image at all and the charly OCI store `$XDG_DATA_HOME/charly/images` does not exist, so such an arm would first build the builder — which proves the build, not the tag scope. ## Rulebook compliance - **R0** — `/charly-internals:git-workflow` and `/charly-internals:go` loaded before the first git action; the umbrella `AGENTS.md` read from `origin/main` (the R11 form) and this repo's own `AGENTS.md` read from `origin/main` before touching the tree. - **R1** — every finding met on the way is fixed here or named: the stale pin value in the brief is corrected above from the tree and the proxy rather than repeated; there is no warning to file (the validate line is `0 warnings, 0 errors`). - **R2/R3** — no code in this change. The behaviour change is the adopted module, whose rule has ONE home (`candy/plugin-build/build_tag_scope.go`), and no retry or fallback is introduced here. - **R4** — no prose routes around a defect; no documented command changes. - **R5** — the old `require` is replaced, not shadowed: the claim-keyed grep for the retired version over the tracked tree (excluding `CHANGELOG/`) returns nothing, and no `replace` directive exists. - **R6** — `git status --short` was empty before the edit; work is in `.worktrees/pin-plugin-build/charly` on `chore/pin-plugin-build`, never in the submodule checkout; no force-push, no direct `main` push, no other session's branch touched (opencharly/charly has no other open PR at this head). - **R7** — the coverage that proves the changed rule fails without it is the producer's (`build_tag_scope_test.go`, its before-arm pasted in opencharly/plugin-build#60); this leg proves the adopted module is the one the binary links and dispatches, in `wp-pins` and `wp-build-generate`. The live arm this change exists for is named under *What was NOT run*. - **R8** — no service boundary is crossed or mocked in this change. - **R9** — built by `scripts/bootstrap-charly.sh` in the worktree; `./bin/charly version` prints `2026.322.2235`, equal to the CalVer of HEAD, and the tree is clean after the build (the generated `go.work` / `plugins_generated.go` are byte-identical to the committed ones). No shared install, and no new runtime OS dependency, so nothing moves in `packaging:`. - **R10** — `check-wave-pins` is the bed this repo declares for exactly this change class (its header: *"the change class here is a Go module dependency-pin adoption whose runtime effect is the COMPILED-IN plugins charly loads in-process"*), and it ran on this tree; its output is pasted above. The `pod:` bed that would prove the DEFECT is fixed is unmerged — stated, not hidden. - **R11** — DESIGN.md **D-KIND-2** is the requirement this serves and it is cited, not amended: a builder is a vocabulary node owned by the repository that declares it, and the adopted resolve stops a caller renaming it. No field, shape, kind, verb or mechanism is added here, so no other D-id is touched. ## Change classification A compiled-in module pin advance: every build that passes `--tag` keeps its own produced boxes on that tag and leaves borrowed builder nodes on the CalVer their owning repository gave them; a build with no `--tag` is byte-identical to today's behaviour. **Breaking change + rollback:** none — the pointer moves to a module tag the org has already merged and published, no wire shape, schema or CLI flag changes, and the rollback is reverting this commit, which restores `v0.2026322.1325` and the pre-fix tag stamping. ## Filed issues No issue is filed: nothing met here is separable from the change, and #1208 stays open as the tracker for the one leg this repo cannot run — the live `check-comfyui-pod` bed. *Agent: comfyui-vram-fix · DeepSeek Harness session 20261118-2110* Assisted-by: DeepSeek Harness ollama-cloud deepseek-v4.1-flash (analysed on a live system)
Summary
TODO.md 3.1, leg 3 of 3 (leg 1:
spec#381; leg 2:sdk#564; tracking:spec#380). Two units in one change, because either alone is red.The paired pin bump.
charly'sspecpin (v0.2026322.1239) predatesspec.ResourceKindSet(shipped inspec#381's tag), so the swap cannot compile at the old pin. Bumpingspecalone also fails, and the reason is a finding about the org's dependency shape:charlypinssdk v0.2026322.1227, whosekit/still read the fieldspec#379deleted. The deletion reached this repo through thesdkpin — two hops from the repo that made it. Not a consumer: a consumer's consumer. Sospecandsdktravel together (sdk v0.2026322.1853carries the acme adaptation and leg 2), and the pair is the only state in which the build is green.The swap. Core derived its own copy of the
#ResourceKindmembership at init —resourceKindSet = setFromSlice(spec.ResourceKinds)(reserved_registry.go:46). Two live predicates read it (isExternalDeploySubstrate,unresolvedDeployTargetError) plus two test fixtures; all four now askspec.ResourceKindSet(), and the copy is gone.setFromSlicestays standing for its four other callers (authoredOpFieldSetand a two-vocabulary consistency check) — measured, not assumed.How tested
The RED, behavioural — the two vocabularies in one line of output. The test moves
spec.ResourceKindsand asksunresolvedDeployTargetError, whose two outcomes differ by wording rather than by a returned token, so no prescan setup is needed:The
want …enumeration is the snapshot reading itself out loud; the branch the call failed to reach is the contract's answer. The two vocabularies appear side by side in one line. Green after the change, with the control arm assertingdefinitely-not-a-kind-wordstill lands on the typo branch:The module gate:
The live proof — ONE of the beds the class feeds, not the gate:
check-pod-overlayis adisposable: truebed run on the committed tree, and its fresh rebuild is the R10 leg. The three skipped checks are declared[runtime]-context checks a box-mode run cannot execute; the bed reports them rather than passing silently.Why the class's full gate is not run, stated as three separate reasons (
charly#1205,charly#1207):kind:check-rosterroster the matrix names does not exist.git -C charly grep -c 'kind: *check-roster' origin/main -- '*.yml'→0, and no roster entity is declared inplugin-checkeither. The matrix's mechanism is unavailable, so the matching set was derived by reading the classifier and run bed by bed.check-local; that entity does not exist. Its live relatives arecheck-local-app(nodisposable:key, akind:localapply against the operator's host) andcheck-local-vm(a VM bed). Running the first would violate Disposable-Only Autonomy —disposable: trueis never inferred from a name.check-k3s-vmandcheck-local-vmneed an active libvirt;systemctl is-active libvirtd virtqemudreportedinactive/inactiveon this machine.So this PR carries one of the three matching beds — real live evidence about the pod half of the classifier, and explicitly not the gate. A green on one of three is exactly the partial roster the matrix forbids, and its stated reason is that the missing bed is where a routing error surfaces.
The gates above were run on the branch's own commit; the merge from
maintouches no file this diff touches.Rulebook compliance
R0 —
/charly-internals:goand/charly-internals:git-workflowloaded before the first git action;charly/AGENTS.mdread (Part II refactor(charly): P1 lint/dead/dup rewrite + concurrency & correctness fixes #4), including its boundary law and its statement thatgo build/go testare cheap smoke rather than the acceptance gate.R1 — four findings were raised and filed, not absorbed:
sdk#560(theacme_emaildeletion's six reader sites, which is why the bump is paired),spec#382(C3's typed-word destination),charly#1205(no roster entity exists for this class),charly#1207(the bed map names two beds that no longer exist, and the replacement set has no autonomously runnable local or VM leg). The bed that could be run was run and its summary pasted; the two that could not are named with their reasons rather than skipped.R2 — the core's private copy of the resource-kind membership is deleted and the one derivation lives in the contract;
setFromSliceis left standing for its four other callers, so the deletion removes a duplicate derivation without removing a shared helper.R3 — no workaround: no cached snapshot kept for speed, no fallback to the old set, no fixture edited to pass, and no bed substituted for another. The unrerunnable beds are reported, not circumvented.
R4 — no documented command changed; the classification now asks the source of truth it already claimed to follow.
R5 — the reader proof, two columns, at both refs: the name
resourceKindSetno longer appears at either live read site, and its reason survives as the comment at the declaration site rather than being deleted with the code.R6 —
git statusread before every move; the work is onfeat/resource-kind-set-leg3in a session worktree offorigin/main(992ae979), the trackedcharly/checkout untouched; no force-push, no bypass, no branch of another session pushed.R7 — the RED is pasted and fails on this change's own subject, the changed path executes in the suite, and the one bed that can run ran live with its summary retained.
R8 — no live service is crossed and nothing is mocked: the bed ran a real rootless podman deployment and removed it.
R9 — the worktree-local CalVer binary was built by
scripts/bootstrap-charly.shandbin/charly versionreports2026.322.1902; no shared install was used.R10 — the fresh-rebuild leg of
check-pod-overlaypassed (check-live-rebuild, 1m28.87s). The full class gate is unreachable for the reasons tabled above and filed ascharly#1205/charly#1207; this PR claimsanalysed on a live system, notfully tested and validated.R11 — conforms. Two requirements govern this change and neither is amended. D-LAW-4 ("Schema first. Every shape has one CUE definition … parsing, validation and Go code derive from it") — the deleted
resourceKindSetwas a hand-maintained Go mirror of the schema's kind set, so deleting it and askingspec.ResourceKindSet()is the requirement applied, not a deviation from it. D-KIND-1 ("the complete first-party kind set" is stated once) — the set is now stated in exactly one place,spec/schema/candy.cue, and the core derives from it. No DESIGN.md or DESIGN.cue amendment is owed, and no gap is widened: the diff removes a second copy of a contract fact rather than adding a third.Change classification
Kind: behaviour + dependency pins. The
#ResourceKindmembership now comes from the contract at consult time, so a vocabulary the contract declares is visible to core immediately; thespecandsdkpins move together because either alone fails to build. Breaking change + rollback: for this repo's consumers, nothing in the public CLI surface changes and no authored key moves; the breakage is internal to the build graph, where the paired bump is the only coherent state. Rollback is reverting this one commit — the pins return tospec v0.2026322.1239/sdk v0.2026322.1227and the core returns to its private copy, which still compiles against that pair.Filed issues
spec#379's un-sweptacme_emaildeletion: six reader sites acrosskit/anddeploykit/, which is why this bump is paired rather than a single pin move.Valid()" is implemented for no vocabulary in the contract module; the destinationspec.ResourceKindSet()records.kind: check-rosterentity exists, so a cross-cutting loader change has no roster to run.check-pod/check-local, neither of which exists; of the live replacements onlycheck-pod-overlayis disposable, so the class's gate cannot be run by an agent without an operator or an active libvirt.Files changed
charly/go.modspec→v0.2026322.1814,sdk→v0.2026322.1853(paired: either alone is red)charly/go.sumcharly/reserved_registry.goresourceKindSetdeclaration deleted; the reason it existed recorded at the site that now asks the contractcharly/plugin_prescan.goisExternalDeploySubstrateasksspec.ResourceKindSet()charly/unified_targets.gounresolvedDeployTargetErrorasksspec.ResourceKindSet()charly/reserved_registry_test.gocharly/deploy_del_diagnostics_test.gocharly/resource_kind_set_test.gotools/generate-packages/go.modspec/sdkpairtools/generate-packages/go.sumtools/golden-cloudinit/go.modspec/sdkpairtools/golden-cloudinit/go.sumtools/golden-compile/go.modspec/sdkpairtools/golden-compile/go.sumtools/gomod-canonical/go.modtools/gomod-canonical/go.sum16 files, +84/−163. The eight
tools/rows are not this row's work:charly'sgoworkflow runs
Test tools modules, and four of the five fail it onorigin/main(
992ae979) because they still requiresdk v0.2026322.1227/spec v0.2026322.1239.This change's class gate was red because of that, so it is fixed here — with the test's
own named remedy,
charly task mods-tidy(2 steps, 0 failed), from this worktree'sbinary.
Agent:
lead· DeepSeek Harness session0d9af4c2ae6eAssisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)