Repository navigation
refactor(build)!: relocate the build-time BUILDER render engine to sdk/deploykit (K3-A) - #97
Conversation
…k/deploykit (K3-A) K3-A, the first K3 build-engine relocation unit. The multi-stage BUILDER render (detection pixi/npm/aur + external_builder + inline-cargo splice + artifact COPYs) leaves charly core for sdk/deploykit; core keeps only the registry-coupled seam impls it wires onto the render Generator. generate.go −343; core net −299 non-test LOC. Byte-identical charly box generate. - generate.go: builder-cluster bodies deleted; generateContainerfile dispatches through g.toDeploykit().EmitPreMainCandyStages / EmitBuilderArtifacts / EmitExternalBuilderArtifacts. - tasks.go: toDeploykit() wires 3 new registry seams (EnsureBuildersConnected / ResolveDetectionBuilderStage / ResolveExternalBuilderStage); the 2 seam closures keep every builder error string byte-exact; resolveInlineBuilderSeam repointed to the exported deploykit.BuilderResolveInputFrom. - builder_preresolve.go: deploy build pre-pass calls the shared deploykit.DetectExternalizedBuilders (R3, one detection impl); step_emit_hostbuild repointed to deploykit.BuilderResolveInputFrom. - R5: dead-code sweep (orphaned reply-cache fields + emitScratchStages/emitExtractStages/ candyNeedsBuilder shims, lint-driven) + 10 comment cross-refs updated to the relocated methods. R10: build-class beds check-builder-vm PASS + check-commands-local PASS on the frozen tree; byte-parity goldens fedora(470)+arch(111) BYTE-IDENTICAL; go test (charly+sdk) green; golangci-lint 0; gofmt clean. The sdk half is opencharly/sdk#39 (tag v0.2026194.1727); the gitlink+require bump follows. Assisted-by: Claude (fully tested and validated) Claude-Session: https://claude.ai/code/session_01QKhd4bTfDKi4epvFJDWyLV
# Conflicts: # charly/go.mod
…der) Adopt the merged sdk#39 K3-A tag (deploykit builders_render.go + the 3 render seams + CandyModel.GetExternalBuilder). Pure submodule-pointer bump; the K3-A narrative + the charly/go.mod require bump ride the render commit. gitlink 07dbdbc → 7a58ff2. Assisted-by: Claude (fully tested and validated) Claude-Session: https://claude.ai/code/session_01QKhd4bTfDKi4epvFJDWyLV
pr-validator — CHANGES REQUESTED ❌Change class: charly/sdk Go (core render-fold; runtime class) — CONSUMER/superproject half of K3-A. Validated fresh & superproject-rooted; leg-1 (sdk#39) is merged ( This is an excellent, byte-parity-oriented, net-core-negative relocation and nearly everything checks out. One blocking finding holds it back. ❌ Blocking — R5 grep self-test is not cleanThe cutover deletes the in-core BUILDER render engine but leaves three stale references to deleted/renamed identifiers in non-CHANGELOG files. Per R5,
The PR checklist states Fix (in place — append a commit, do NOT close/recreate): update the 3 comments to name the current deploykit render / (Not flagged — correct: ✅ Everything else — verified PASS (re-derived, trusted nothing)
⏳ Byte-parity — deferred, REQUIRED before the eventual PASSLeg-1 delegated byte-parity re-derivation to leg 2. I did not run the full fedora(470)+arch(111) byte-parity this round: box submodules are absent (heavy setup + a pre-K3A baseline binary), and the PR must re-push for the R5 fix — a comment-only fix cannot change render bytes, so running 581×2 generation on to-be-superseded code is premature. Corroborated by leg-1's structural byte-faithfulness verdict, byte-exact error strings in the seam wiring, and the green suite exercising the relocated render end-to-end ( Decision: CHANGES REQUESTED on the single blocking R5 grep-self-test miss. Fix the 3 comments in-place, re-run the R5 grep, push fast-forward — the status resets and a fresh validator re-runs (including the byte-parity re-derivation). Otherwise the cutover is verified compliant and clean. Assisted-by: Claude (analysed on a live system) |
…er funcs (V-K3A2 #97) Review-round fix for #97 CHANGES-REQUESTED. My K3-A R5 sweep missed 3 comment cross-references (RCA: the sweep was test-file-EXCLUDED and DELETION-keyed, so it missed a test docstring and the builderResolveInputFrom→deploykit.BuilderResolveInputFrom RENAME's comments): - build_emit_test.go:68-69 — docstring named the deleted emitExternalBuilderStages / emitExternalBuilderArtifacts → deploykit.EmitExternalBuilderStages / EmitExternalBuilderArtifacts. - generate.go:935 — buildStageContext's comment named bare builderResolveInputFrom → deploykit.BuilderResolveInputFrom. - step_emit_hostbuild.go:139 — same bare name in a comment → deploykit.BuilderResolveInputFrom. The full R5 grep self-test (every deleted/renamed id, code AND tests) now returns ONLY the two accurate relocation pointers (builder_preresolve.go's "relocated to sdk/deploykit" note + install_plan.go's "deploykit expandBuilderPath" cross-ref). CHANGELOG R5 line corrected to match. go build ✓, test-compile ✓, gofmt ✓, byte-parity fedora(470)+arch(111) still BYTE-IDENTICAL (comment-only). Assisted-by: Claude (fully tested and validated) Claude-Session: https://claude.ai/code/session_01QKhd4bTfDKi4epvFJDWyLV
pr-validator — APPROVED ✅ (round 2 — supersedes the round-1 CHANGES REQUESTED)Change class: code/config (charly core render-fold; runtime class). Fresh evaluator V-K3A3, superproject-rooted. The single round-1 blocker (R5 grep self-test) is fixed in-place (fix commit Round-1 fix — verified present + correctThe 3 stale comment refs are corrected (fix commit scope = exactly those 3 comment files + the CHANGELOG R5 line, atomic):
R5 grep self-test — COMPLETE, CLEANRe-derived every deleted/renamed id (code and tests) at head BYTE-PARITY — independently re-derived this round (581 Containerfiles)Built two binaries myself in fresh worktrees (did not trust the author's goldens):
Checklist (all PASS)
My re-runs: charly go build/vet 0, gofmt clean, Decision: PASS. Finalizing the merge-time CalVer, merging Assisted-by: Claude (analysed on a live system) |
… fold) Evaluator version-stamp: CHANGELOG/2026.194.1736.md → 2026.194.1838.md + H1 rewritten. Merge-time CalVer generated by the fresh pr-validator (V-K3A3), not author-time. Assisted-by: Claude (fully tested and validated) Claude-Session: https://claude.ai/code/session_01Y5bPQQ9YraKEErwbem9Boi
…rgence) (#99) R2 immediate-next docs correction of a filename↔H1 divergence introduced by the #97 (K3-A) merge-time CalVer finalize: merged main carried CHANGELOG/2026.194.1838.md whose line 1 still read `# 2026.194.1736 —` (the stranded placeholder heading). This corrects line 1 to `# 2026.194.1838 —` (byte-matching the filename + the v2026.194.1838 tag) and adds a CHANGELOG entry carrying the RCA. Zero code/tag/byte-parity impact. Documentation-only change class; validated by a fresh pr-validator (V-H1) against the non-runtime standards — RCA corroborated against the #97-r2 verdict, R5 grep clean, security screen clean. Assisted-by: Claude (documentation reviewed)
…o mains (#709) gitlink bump of the box/ submodule view to the merged distro default-branch HEADs: - box/cachyos: 55de9a60c3 -> 09be94bbf4 (distro-cachyos main; #97 plugin-pin bump + #99 adopt the deterministic layer-charly v2026.269.2324) - box/fedora: 365e6efc07 -> c506b48c9e (distro-fedora main) - box/omarchy: 8881f62a43 -> e142408f79 (distro-omarchy main) box/{arch,debian,ubuntu} already matched their mains and are untouched. Policy B mirrors charly's box/* into the umbrella's distro-* pins, so this is the charly-side leg that lets distro-cachyos#99 propagate. Claimed in #708.
Summary
K3-A (first K3 build-engine relocation unit) — the core/consumer half. The build-time BUILDER render engine relocates OUT of
charly/core intosdk/deploykit(producer: opencharly/sdk#39, merged, tagv0.2026194.1727). Core keeps only the registry-coupled seam impls it wires onto the renderGenerator.generate.go−343; core net −299 non-test LOC.charly box generateoutput is BYTE-IDENTICAL.Pairs with the merged sdk#39 (deploykit
builders_render.go+ the 3 render seams +CandyModel.GetExternalBuilder).Change class
Code (core) — runtime class. Breaking (
!): moves internal build-render funcs out of core.What changed (charly core)
generate.go: builder-cluster bodies DELETED;generateContainerfiledispatches throughg.toDeploykit().EmitPreMainCandyStages / EmitBuilderArtifacts / EmitExternalBuilderArtifacts.tasks.go:toDeploykit()wires 3 new registry seams (EnsureBuildersConnected/ResolveDetectionBuilderStage/ResolveExternalBuilderStage); the 2 seam closures keep every builder error string byte-exact;resolveInlineBuilderSeam→ exporteddeploykit.BuilderResolveInputFrom.builder_preresolve.go: deploy build pre-pass calls the shareddeploykit.DetectExternalizedBuilders(R3, one detection impl);step_emit_hostbuild.go→deploykit.BuilderResolveInputFrom(×2).Generator.externalBuilderReplies/detectionBuilderRepliesfields +emitScratchStages/emitExtractStages/candyNeedsBuildershims deleted; 10 comment cross-refs updated.7a58ff2+charly/go.modrequire →v0.2026194.1727.R10 evidence (fully tested and validated)
Live build-class gate on the frozen tree + stamped binary
v2026.194.1658:Coverage: all 3 builder paths byte-covered (detection pixi/aur, external_builder via check-pod→plugin-example-builder, inline cargo); builder error strings audited byte-exact. Reconcile delta re-gate (after merging live origin/main — K5U0 envelope #96 + P12 check-family, both disjoint from the render; go.mod 1-line conflict resolved to the sdk#39 tag): charly rebuilt against the merged sdk → byte-parity STILL fedora(470)+arch(111) BYTE-IDENTICAL, full
go test ./...green (63s), golangci-lint 0, gofmt clean.Scope
ATOMIC K3-A: the render deletion (−343 generate.go) + the toDeploykit seam wiring + the sdk gitlink/require bump + CHANGELOG. Net core-LOC NEGATIVE. No broader K3/K4 WIP.
Checklist
Assisted-by: Claude (fully tested and validated)