Repository navigation
feat(bundle)!: charly bundle CLI → compiled-in command:bundle plugin (P13) - #71
Conversation
… (P13)
The charly bundle deployment CLI moves out of charly core into a COMPILED-IN
command:bundle plugin candy (candy/plugin-bundle), mirroring the landed P10
command:vm pattern. The plugin owns the CLI GRAMMAR; the deploy ORCHESTRATION stays
in core behind four new host-build seams that run the existing handlers VERBATIM.
- candy/plugin-bundle: the BundleCmd Kong grammar (9 subcommands add/del/from-box/
show/export/import/reset/path/status) dispatched IN-PROC via Invoke(OpRun). Each
leaf reaches the host over hostDeploySeam (R3): add/del/from-box to
HostBuild(deploy-add/deploy-del/deploy-from-box); show/export/import/reset/status to
HostBuild(deploy-config) op-discriminated; path via kit.DefaultDeployConfigPath
entirely plugin-side (no seam).
- host_build_deploy_{add,del,from_box,config}.go: the four class-generic host seams
(F11) that reconstruct the renamed core orchestration struct and run its existing
Run() VERBATIM. The old CLI types were renamed to internal host structs with Kong
tags stripped (BundleAddCmd to deployAddCmd, etc.); the BundleCmd group + the old
builtin registration (plugin_command_bundle.go) are DELETED.
- deploy-config is a DISTINCT seam from config-resolve/config-persist (whole-file
operator management vs entity-scoped runtime state, zero shared handler code, R3).
Boundary-law note: bundle add is the deploy KERNEL DRIVER, not wrappable capability
code, so net core LOC is ~flat (CLI grammar leaves, seam wrappers enter) and the
original plan LOC premise is revised (recorded in CHANGELOG). C15 partial state fold:
LoadDeployFile + RemoveBoxDeploy + the pure volume naming + VolumeMount fold to
sdk/deploykit; the rest stays core (loader/flock/migrate/Config-coupled). deploy_ref.go
+ reconcile.go stay core (generic Mechanisms, boundary-law verdict recorded).
Assisted-by: Claude (analysed on a live system)
Claude-Session: https://claude.ai/code/session_019F9qvuw1b3twtH1HZEGvVY
# Conflicts: # charly/charly.yml # charly/plugin_command_bundle.go # charly/plugins_generated.go # go.work
…seams, v0.2026193.1222) Assisted-by: Claude (analysed on a live system) Claude-Session: https://claude.ai/code/session_019F9qvuw1b3twtH1HZEGvVY
pr-validator — CHANGES REQUESTED ❌Change class: charly/sdk Go + compiled-in plugin candy ( I re-derived the verdict independently from the repo, CLAUDE.md, and the loaded skills — trusting none of the PR's claims. The architecture, code gates, boundary-law, SDD, and R5 identifier sweep all PASS. There is one blocking issue: an R1/R5 documentation-divergence incident. ❌ BLOCKING — R1/R5 documentation divergence (bundle plugin describes seams it does not use / that do not exist)The Actual code — False claim — that the plugin reaches the host via "config-resolve / config-persist / deploy-apply / cli HostBuild seams and verb:egress / verb:arbiter" — appears in four surfaces:
Why it is a real divergence, not a stylistic nit:
Per CLAUDE.md R1 ("a divergence between any … code comment and observed reality … is an incident … BLOCKING in the current cutover") + R5 (claim-keyed sweep across the whole sibling-set). The CHANGELOG is correct (names the 4 real seams), so the divergence is confined to the 4 files above. Fix (update-in-place — append a fix commit; do NOT close/recreate): sweep all 4 surfaces to name the actual seams ( Checklist (verified from a fresh clone at d30004f)
Decision: CHANGES REQUESTED. The cutover is architecturally sound and every code/SDD/boundary-law/lint gate is green, but the Assisted-by: Claude (analysed on a live system) |
The plugin-bundle skeleton doc comments + baked description named non-existent seams (config-resolve/config-persist/deploy-apply/cli + verb:egress/verb:arbiter, copied from the plugin-vm template) instead of the four actual host-build seams deploy-add/deploy-del/deploy-from-box/deploy-config. Swept all four surfaces (plugin.go/command.go/host_seams.go + the baked charly.yml description) to name the real seams; also removed the stray claim that the plugin compiles InstallPlans (the host does, behind the seam). R1/R5 documentation-divergence fix surfaced by V-71; false claim contained to these four surfaces (grep-verified). Docs-only, non-behavioral. Assisted-by: Claude (analysed on a live system) Claude-Session: https://claude.ai/code/session_019F9qvuw1b3twtH1HZEGvVY
Merge-time version stamp applied by the fresh pr-validator: the CHANGELOG placeholder is renamed to the merge CalVer and its H1 rewritten to match. No schema bump (no #SchemaVersion change in this cutover). Assisted-by: Claude (analysed on a live system) Claude-Session: https://claude.ai/code/session_01PojeSiBRThQS2v5w8PziAR
pr-validator — APPROVED ✅ (supersedes the earlier CHANGES-REQUESTED verdict)Change class: charly/sdk Go + compiled-in plugin candy ( The prior blocking finding (R1/R5 documentation divergence — the plugin described Checklist (re-derived from a fresh clone)
Decision: APPROVED. The Assisted-by: Claude (analysed on a live system) |
Rebase #70 onto merged main 3f6ef75 (strict:true up-to-date). Only charly/go.mod conflicted (sdk require): kept v0.2026193.1308 (ccd68e0, descendant of P13 sdk). Re-ran pluginsgen: plugin-build + plugin-bundle + plugin-alias all compiled-in (go.work + plugins_generated.go). P13 did not touch the build-engine files (no overlap). Fresh-rebuild R10 re-confirmed: build exit0 + go test green + golangci-lint 0 issues + real fedora build exit0. Assisted-by: Claude (fully tested and validated) Claude-Session: https://claude.ai/code/session_01R8UGGr3ui1959oTb5JuSif
…ks + module-key validation fix The check/bed correctness batch — three pre-existing bed/validation defects landed as one atomic superproject cutover (producer legs merged first: sdk#47 image_tag wire field + plugins#55 agents-SKILL R1 correction). #75 — bed-scoped fixture image tags (the shared-tag concurrency collision class): a per-run <bed-root>-<runCalver> tag threaded via spec.CheckBedReply.ImageTag, passed as --tag on every build + deploy, with resolveNodeOverlays seeding node.Version and the k8s preresolver honoring it (mirroring build_overlay's tag!="" branch). Retention-safe (same image name → same label group). #66 — debootstrap-builder baked checks: qemu-img version scalar-equals → contains matcher (R4); grub-install check kept (correct) + the missing grub2-common added (provides /usr/sbin/grub-install, dropped by --no-install-recommends). #71 — validatePkgConfig module/modules Raw-key mismatch: Raw["modules"]→Raw["module"] (the singular authored key), making the rule reachable; discriminating test + guard. sdk gitlink → merged 5ad481d (v0.2026195.742); plugins gitlink → merged 7075eda (v2026.195.0759). Validated independently by a fresh pr-validator: delta re-gate green after update-branch (golangci-0 + tests on all 3 modules), forward-gitlinks verified, #75 concurrent-pair R10 corroborated. Assisted-by: Claude (fully tested and validated)
plugins docs PR #71 merged; plugins main is now a11d933 (tag v2026.197.0726), a fast-forward descendant of this branch's prior pin (784c4ba), verified via `git merge-base --is-ancestor` before applying. The bumped range is entirely documentation (a CHANGELOG entry plus skill .md edits) — no code. Assisted-by: Claude (documentation reviewed)
…#55 step 3-I) Core's host-owned resolved-project envelope projector becomes the plugin capability `build:project` on candy/plugin-build (Op OpResolve for resolve, OpValidate for the error-tolerant validate leg) — a class-generic word on the existing build class (F11, no new core seam). The ~8 peer consumers (box-inspect, bundle node-resolve+compile, check-project, preempt-arbiter, installstep, status nested-tree, substrate k8s/android status) swap HostBuild("resolved-project") → InvokeProvider("build","project"). ResolvedBox becomes a CUE-sourced spec contract (embedding wrapper). hostBuildResolvedProject / buildResolvedProjectFromDir / resolvedProjectBuilderKind + their registration + the projectResolvedProject wrapper are deleted from core; the render-coupled projectResolvedProjectWithBoxes/fillNamespacedBoxes remain with a named exit to step 3-II (task #71). Net non-test core: −29 LOC; loaderkit coupling removed from 20 core files. Producers merged first (B2): spec v0.2026210.1533, sdk v0.2026210.1407. R10: check-pod 13/13 + check-builder-vm 10/10 on a fresh ./bin/charly rebuild; go build/test/vet/gofmt/box-validate green; TestPluginsGenReproducible + TestNoSinglePluginAPISurface pass. R5 grep self-test (whole-tree, both directions) clean. Assisted-by: Claude Code Anthropic Claude Opus 4.8 (fully tested and validated)
…k/buildkit onto spec #55 step 3-III (final B2 leg): charly core + build plugins repoint the build-vocabulary value-type containers buildkit.{DistroConfig,BuilderConfig,BuilderMap,WrapDistroDef,DistroTagChain} → spec.X (+ DistroDef→spec.ResolvedDistro / FormatDef→spec.Format / BuilderDef→spec.Builder), dropping the now-unused sdk/buildkit import where no behaviour symbol remains. Import-purity: charly files importing sdk/buildkit 51 → 42. InitConfig stays in buildkit (init-composition policy → #65/#71). Consumes merged spec v0.2026210.2052 + sdk v0.2026210.2103. Runtime-neutral: the repointed types are type aliases in sdk/buildkit (DistroConfig = spec.DistroConfig, …), so the rename produces byte-identical compiled code — gated by check-pod-overlay 13/13 + check-builder-vm 10/10 on a fresh rebuild. Assisted-by: Claude Code Anthropic Claude Opus 4.8 (fully tested and validated)
P13 — the
charly bundleCLI becomes the compiled-incommand:bundlepluginThe superproject half of P13 (consumes sdk#29, merged: deploykit seams +
deploykit.VolumeMount).The
charly bundle …deployment CLI moves out of charly core into a COMPILED-INcommand:bundleplugin candy (candy/plugin-bundle), mirroring the landed P10command:vmpattern. The plugin owns the CLI GRAMMAR; the deploy ORCHESTRATION stays in core behind four
new host-build seams that run the existing handlers VERBATIM.
The plugin (
candy/plugin-bundle, compiled-incommand:bundle)Owns the full
BundleCmdKong grammar — 9 subcommands (add/del/from-box/show/export/import/reset/path/status), verbatim tags. Dispatch is IN-PROC viaInvoke(OpRun)(runBundleCommand→ kong-parse). Each leaf reaches the host overhostDeploySeam(the ONE bridge, R3):add/del/from-box→deploy-add/deploy-del/deploy-from-box;show/export/import/reset/status→deploy-config(op-discriminated);path→kit.DefaultDeployConfigPath()entirely plugin-side (no seam).The four host seams (core, class-generic F11 nouns)
host_build_deploy_{add,del,from_box,config}.goreconstruct the renamed core orchestrationstruct from the wire request and run its existing
Run()VERBATIM. The old CLI types wererenamed to internal host-orchestration structs with Kong tags stripped
(
BundleAddCmd→deployAddCmd, …); theBundleCmdgroup + the old builtin(
plugin_command_bundle.go) are DELETED. Orchestration bodies are byte-identical.deploy-configis a DISTINCT seam from the entity-scopedconfig-resolve/config-persist(whole-file operator management vs single-entity runtime state, zero shared handler code, R3).
Boundary-law outcome + the plan LOC-premise revision
bundle addis the deploy KERNEL DRIVER (loader, InstallPlan compiler,ResolveTarget,live-executor composition — all Mechanisms that stay core), NOT wrappable capability code. So
net core LOC is ~flat (CLI grammar leaves, seam wrappers enter); the win is ARCHITECTURAL
(
command:bundleis now a dual-placement plugin, nocharly bundleCLI struct in core). Theoriginal plan counted bundle as ~1710 movable LOC; this is corrected in the CHANGELOG. C15
partial state fold:
LoadDeployFile+RemoveBoxDeploy+pure volume naming+VolumeMount→sdk/deploykit; the rest stays core (loader/flock/migrate/Config-coupled).deploy_ref.go+reconcile.gostay core (generic Mechanisms — boundary-law verdict recorded).Verification (this branch)
go build ./...+go test ./...(charly; the 2 box/* tests are submodule-env only) +golangci-lint run0 issues +gofmtclean +pluginsgenreproducible + the R5 grepself-test (every removed
Bundle*Cmdreturns only CHANGELOG). Live smoke of thecompiled-in command:
charly bundle add/path/show/statusdispatch through the seams(exit 0, zero warnings;
bundle addruns the byte-identical orchestration). Rebased ontomerged main (P14b #68 alias); sdk pointer bumped to merged sdk main (v0.2026193.1222). The
full disposable-bed roster —
bundle addis every bed's entry — is the cross-cuttingacceptance gate.
Assisted-by: Claude (analysed on a live system)
https://claude.ai/code/session_019F9qvuw1b3twtH1HZEGvVY