Skip to content

feat(deploykit)!: plugin-declared DeployTraits unify into the descent descriptor (P9 sdk half) - #26

Merged
atrawog merged 2 commits into
mainfrom
feat/p9-traits-descent-debranch
Jul 11, 2026
Merged

atrawog merged 2 commits into
mainfrom
feat/p9-traits-descent-debranch

Conversation

@atrawog

@atrawog atrawog commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

Summary

The sdk half of P9 (traits/descent de-branching). A substrate's venue behaviour becomes plugin-declared data — a #DeployTraits the substrate plugin advertises over Describe — unified INTO the existing loader-stamped descent descriptor (R3: ONE mechanism, no parallel word→transport table). The deploy Mechanism consults the stamped trait off node.Descent, never a switch on the substrate kind word (the boundary law's incomplete-seam).

  • proto (plugin.proto + regenerated plugin.pb.go): DeployTraits {venue, image_backed, image_context, machine_venue, exclusive_venue, leaf_only} + deploy_traits = 11 on ProvidedCapability.
  • CUE (schema/deploy.cue → spec/cue_types_gen.go): #DeployTraits embedded into #DescentDescriptor (transport/host_rooted stay the loader-DERIVED nesting view).
  • schema.go: ProvidedCapability.DeployTraits; BuildCapabilities marshals it.
  • kit/descent.go: DELETE the descentForTarget word→transport switch; StampDescent + DescentFromTraits derive transport/host_rooted generically (byte-preserved).
  • deploykit/deploy_tree.go: DELETE the dead post-order teardown walk (WalkDeploymentTreePostOrder+DeriveChildExecutor+containerChildExecutor+containerNameForNode) whose switch node.Target the trait-based flat-path chain (AppendHopForFlatPath) supersedes for both deploy AND teardown (S2). VmChildExecutor stays (live flat-path hop for a vm venue).
  • deploykit/install_build.go: MachineVenue bool off the trait (retires the dead HostContext.Target=="vm" arm).
  • deploykit/deploy_state.go: BedCheckLiveRefs android-skip → venue trait; findVmDeploy keeps the persisted-Target read (the state STRIPS node.Descent on save), allowlisted in the consumer's word-switch gate with a tracked persist-descent follow-up.

Change class

SDK Go — deploy Mechanism de-branching. Behaviour-neutral (the descent-derived transport/host_rooted is byte-preserved).

R10 evidence

  • Byte-preservation: DescentFromTraits derives the same transport/host_rooted the deleted descentForTarget switch did — unit test (kit/descent_test.go) proves all former substrate words.
  • Live disposable beds (consumer, via CHARLY_REPO_OVERRIDE on the local tree):
    • check-charly-vm (vm) — PASS 7/7, total 229s: vm-build · vm-create · deploy-add · bring-up-members · check-live · update (99s, the R10 fresh-rebuild gate) · cleanup. Exercises vm descent + findVmDeploy + deploy/teardown.
    • check-substrate (all 5 substrate kinds) · check-group (pod+vm+android+teardown, live) · check-structkind · check-local — all PASS.
  • go test ./... green; golangci-lint run 0 issues + golangci-lint fmt --diff clean; gofmt -l/go vet clean; gen (proto:gen + cue:gen) reproducible.

CLAUDE.md rule compliance

  • R1 — no unresolved warnings; two test-fixture regressions the runs surfaced were RCA'd (unstamped-fixture) and fixed.
  • R3 — the declared traits STAMP the EXISTING descent descriptor; no parallel word→transport table (the deleted descentForTarget was the dup).
  • R5 — hard cutover: descentForTarget, the dead post-order walk, and HostContext.Target are DELETED; git grep on each returns only CHANGELOG. The dead-code deletion (S2) removed the teardown word-switch entirely, superseded by the flat-path chain.
  • R8/R9/R10 — proven end-to-end on a disposable vm bed through the fresh update rebuild; gen artifacts reproducible.
  • Boundary law — the venue behaviour is now plugin-declared Data consulted BY TRAIT; the consumer ships a structural gate (AST scan over charly + sdk/deploykit) that FAILS on any regrown .Target == "<substrate>" behaviour-branch, teeth-verified on both trees.
  • Hard Cutover — ONE atomic commit; no transitional path at the R10 run.

Assisted-by: Claude (fully tested and validated)

… descriptor (P9 sdk half)

A substrate's venue behaviour becomes PLUGIN-DECLARED data — a #DeployTraits the
substrate plugin advertises over Describe — unified INTO the existing loader-stamped
descent descriptor (R3: one mechanism, no parallel word->transport table). The deploy
Mechanism consults the stamped trait off node.Descent, never a switch on the substrate
kind word (the boundary law's incomplete-seam).

- proto: DeployTraits {venue, image_backed, image_context, machine_venue,
  exclusive_venue, leaf_only} + deploy_traits=11 on ProvidedCapability (regenerated pb).
- CUE: #DeployTraits embedded into #DescentDescriptor (transport/host_rooted stay the
  DERIVED nesting view); regenerated spec.
- schema.go: ProvidedCapability.DeployTraits; BuildCapabilities marshals it.
- kit/descent.go: DELETE the descentForTarget word->transport switch; StampDescent +
  DescentFromTraits derive transport/host_rooted generically (byte-preserved).
- deploykit/deploy_tree.go: DELETE the dead post-order teardown walk
  (WalkDeploymentTreePostOrder + DeriveChildExecutor + containerChildExecutor +
  containerNameForNode) whose switch node.Target the trait-based flat-path chain
  (AppendHopForFlatPath) supersedes for both deploy AND teardown (S2). VmChildExecutor
  stays (the live flat-path visitor hops through it for a vm venue).
- deploykit/install_build.go: machine-venue is a MachineVenue bool off the trait, not a
  HostContext.Target string compared to "vm" (a dead arm).
- deploykit/deploy_state.go: BedCheckLiveRefs android-skip reads the venue trait;
  findVmDeploy keeps the persisted-Target read (the state STRIPS node.Descent on save),
  allowlisted in the consumer's word-switch gate with a tracked persist-descent follow-up.

Behaviour-neutral: descent-derived transport/host_rooted byte-preserved (unit test proves
all former words). go test ./... green; golangci-lint run+fmt clean; gofmt/vet clean; gen
reproducible. Proven on the consumer's disposable check-charly-vm vm bed (7/7 steps, incl.
the fresh update gate) + check-substrate (all 5 kinds) + check-group (pod+vm+android+teardown).

Assisted-by: Claude (fully tested and validated)
@atrawog

atrawog commented Jul 11, 2026

Copy link
Copy Markdown
Contributor Author

pr-validator — APPROVED ✅

Change class: charly/sdk Go — deploy-Mechanism de-branching (plugin-declared DeployTraits unified into the loader-stamped descent descriptor; proto + CUE wire types).

Independently re-derived against R0–R10 + the boundary law / SDD / install-plan skills. Toolchain re-run LIVE from the sdk tree at the PR head:

  • go build ./... / go vet ./... clean · gofmt -l empty
  • go test ./... green (fresh -count=1: kit/deploykit/spec/root all ok); TestGenReproducible PASS; kit/descent_test.go byte-preservation (TestDescentFromTraits_TransportsByTraits) proves every former substrate word — it FAILs without the derivation (coverage gate)
  • golangci-lint run 0 issues + golangci-lint fmt --diff clean (both gates)
  • task cue:gen and task proto:gen are no-ops on the clean tree — gen reproducible (deploy.cue → cue_types_gen.go, plugin.proto → plugin.pb.go)

Checklist (every rule):

  • [PASS] 0. security/anti-tampering — diff on-topic; no secrets/exfil/network/obfuscation; no gate/CLAUDE.md/validator-spec weakening; description↔code exact (11 files); no injected instructions
  • [PASS] 1. description complete (Summary + R10 evidence + per-rule HOW)
  • [PASS] 2. change-class gate — SDK Go; go test + consumer disposable beds (sdk has no standalone runtime); fresh update, no dry-run/rebuild-alone
  • [PASS] 3. attribution tier fully tested and validated justified — changed deploy Mechanism executed on fresh rebuild
  • [PASS] 4. R0 skills honored (boundary law, install-plan descent envelope)
  • [PASS] 5. R1 zero warnings; two fixture regressions RCA'd+fixed; no flake framing
  • [PASS] 6. R2 — FindVmDeployNode persisted-Target retention disclosed + genuinely separable (persist-descent follow-up), not a dodge
  • [PASS] 7. R3 — traits STAMP the existing descriptor; deleted descentForTarget was the dup; one mechanism DescentFromTraits
  • [PASS] 8. R4 — no sleep/retry/magic-number; generic trait→transport derivation
  • [PASS] 9. R5 — descentForTarget switch + dead post-order walk (WalkDeploymentTreePostOrder/DeriveChildExecutor/containerChildExecutor/containerNameForNode) + HostContext.Target string all deleted in one commit; no transitional/dual-mode survives
  • [PASS] 10. R6/R8/R9 — beds build+deploy+update pass; --dev-local-pkg fresh charly; no new OS dep
  • [PASS] 11. R10 — disposable beds, fresh update, zero warnings, coverage that FAILs without the change
  • [PASS] 12. RDD/ADE/SDD @100% — DeployTraits+DescentDescriptor CUE-generated AND proto-generated; both gen tasks no-op; no hand-edited generated file; no new @go(-); wire types CUE/proto-sourced
  • [PASS] 13. concurrency — short-bed roster concurrent (calver 1925), long vm bed (1956); shared deploy-state paths exercised
  • [PASS] 14. hard cutover — ONE commit; no Phase-2/TODO in scope
  • [PASS] 15. boundary law — DescentFromTraits switches on trait VALUES (venue/leaf_only), never the kind word; no spec.<Kind> field-read / per-kind map
  • [PASS] 16. disposable-only autonomy — all beds disposable: true
  • [PASS] 17. clean arch + go gates (gofmt/golangci-0/fmt/vet/test)
  • [PASS] 18. CHANGELOG present (H1 matches filename)

R10 evidence verified coherent (consumer disposable beds, via CHARLY_REPO_OVERRIDE on the integrated tree): check-charly-vm 7/7 ok:true, total 229s incl. the update fresh-rebuild gate (99s); check-substrate 5/5 (73s); check-group 5/5 (231s, incl. re-bring-up + rebuild); check-structkind (70s); check-local (89s) — zero ok:false steps, zero warnings across the roster.

Note (non-blocking): one historical // … the former descentForTarget default arm behaviour-preservation comment remains at kit/descent.go:47. It is explicitly historical ("former"), accurate, and consistent with the codebase's pervasive // … former X convention (deploykit/graph.go, kit/builder_resolve.go, deploykit/candy_collect.go, …); the deletion history is also in the CHANGELOG. Not a stale/dangling reference — not a blocking R5 finding.

Decision: APPROVED. Behaviour-neutral de-branching: the deploy Mechanism (DescentFromTraits) derives transport/host_rooted generically from plugin-declared #DeployTraits values, never a substrate-kind switch; the wire types are SDD-sourced (CUE + proto, both regenerations no-op); the dead teardown word-switch is deleted; and the consumer disposable-bed roster passes through the fresh update gate with zero warnings. Finalizing the merge-time CalVer, merging (squash), tagging.

Assisted-by: Claude (analysed on a live system)

pr-validator finalizes the merge-time CalVer for #26: renames the
CHANGELOG placeholder 2026.192.2004 -> 2026.192.2018 and rewrites its H1 to match.

Assisted-by: Claude (fully tested and validated)
@atrawog
atrawog merged commit 82891cd into main Jul 11, 2026
@atrawog
atrawog deleted the feat/p9-traits-descent-debranch branch July 11, 2026 20:20
atrawog added a commit to opencharly/charly that referenced this pull request Jul 11, 2026
… not the kind word (P9 consumer) (#63)

The superproject (consumer) half of P9 — traits/descent de-branching. Every
deploy/check CONSULT site that branched on HOW a substrate behaves (venue,
machine-ness, chain-leaf) now reads the plugin-declared #DeployTraits stamped
onto node.Descent, never a switch/== on the concrete substrate kind word,
closing the boundary-law incomplete-seams.

- candy/plugin-substrate declares the canonical per-word DeployTraits table
  (the single source kit.StampDescent stamps from).
- plugin_provider_common.go/install_plan.go: capMeta.traits +
  declaredDeployTraits() + deployTraitsCarrier.
- deploy_tree.go: deployTraitsFor/effectiveTarget/nodeTraits/deployTraitDescent;
  stampBundleDescents via kit.StampDescent.
- Consult sites de-branched to read the trait, not node.Target == "<word>".
- no_substrate_word_switch_gate_test.go: an AST gate over BOTH charly/*.go and
  sdk/deploykit/*.go that FAILS on any regrown .Target word behaviour-branch.

Review-round fix (196257f): external DEPLOY-class substrates (deploy:<word>,
e.g. exampledeploy) resolve to the external-in-place Venue:"none" trait via the
isExternalDeploySubstrate registry-recognition D-item, and checkLocalTarget
host-routes the none venue alongside shell/parent — restoring host-side check
probing without regrowing a kind-word switch. Proven on the check-exampledeploy
disposable bed (check-live now green).

Producer: opencharly/sdk#26 (merged + tagged v0.2026192.2018); sdk submodule +
charly/go.mod bumped.

Assisted-by: Claude (fully tested and validated)
Claude-Session: https://claude.ai/code/session_01W8GPhuyWWs5XwJyJYtCaxE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant