Repository navigation
feat(build,check,deploy,credential,settings)!: Cutover 1 — plugins-for-everything part 1 (cone capability out of core, −2,612 LOC) - #188
Conversation
…erb:enc InvokeProvider
Wave γ (credential/enc/settings InvokeProvider unification), first slice:
the `charly config status|mount|unmount|passwd` leaves were the last
CLI-invoked commands still forwarding to core over a HostBuild
("pod-config-<leaf>") seam purely to reach the core-only credential/enc
registry APIs (providerRegistry.resolve + connectPluginByWord).
Applies the ALREADY-LIVE pattern candy/plugin-deploy-pod/lifecycle.go
proves for the start/stop path: command:config already holds a real
reverse-channel *sdk.Executor (cmdExec, stashed at Invoke(OpRun) entry —
host_seams.go), so verb:enc and verb:credential are now dispatched
DIRECTLY from candy/plugin-pod (new enc_cmd.go), no core round-trip.
- candy/plugin-pod/enc_cmd.go (new): pluginEncStatus/Mount/Unmount/Passwd
(direct ports of charly/enc.go's encStatus/encMount/encUnmount/
encPasswd) + a plugin-side deploykit.CredentialAccess adapter backed by
InvokeProvider(verb:credential) instead of the core-only
ResolveCredential/DefaultCredentialStore chain. Fast-path short-circuit
(defect C: skip the passphrase lookup when every volume is already
mounted) preserved byte-identical.
- candy/plugin-pod/pod_cmd.go: the four Config*Cmd.Run() methods call the
new plugin-local functions instead of hostPodSeam.
- charly/enc.go: encMount/encStatus/encPasswd + their mount-only
passphrase path (resolveEncPassphraseForMount/
awaitKeyringUnlockViaPlugin) deleted — fully dead once the CLI leaves
moved. encUnmount/ensureEncryptedMounts/resolveEncPassphrase/
encExecViaPlugin/coreCredentialAccess STAY: still called by
hostBuildPodConfigEncMounts (the `charly config setup` orchestration
family) and pod_lifecycle_resolve.go's start-lifecycle plan builder —
a different family, out of this slice's scope per the wave γ scoping
map (scratchpad/wave-gamma-scoping-map.md).
- charly/config_image.go: BoxConfigStatusCmd/MountCmd/UnmountCmd/
PasswdCmd deleted (dead — their sole callers were the now-removed
HostBuild handlers).
- charly/host_build_pod_config.go: hostBuildPodConfigStatus/Mount/
Unmount/Passwd + their builder-kind consts + registrations deleted.
- sdk (schema/seam.cue + regenerated spec/cue_types_gen.go): the four
now-dead PodConfig{Status,Mount,Unmount,Passwd}{Request,Reply} CUE wire
defs removed; the adjacent comment falsely claiming these leaves "do
NOT move" corrected (R1 divergence, fixed in the same change).
- Test coverage: charly/enc_mount_short_circuit_test.go ported to
candy/plugin-pod/enc_cmd_test.go (TestPluginEncMount_ShortCircuit_
AllMounted / _NoShortCircuit_WhenOneUnmounted), registering a fake
deploykit.DeployStateHost the same way sdk/deploykit's own
load_bundle_config_seam_test.go already establishes the pattern for.
R1 finding surfaced while porting the test (not a regression in the
port): deploykit.LoadBundleConfig() silently degrades to "no entries"
outside the charly-core process (documented in deploy_file.go's own
comment on this exact historical failure mode) because it needs
deploykit.DeployStateHost registered, which only happens in charly-core's
init(). Production is unaffected — command:pod is compiled-in-only
(CliMain refuses out-of-process placement), so it always shares charly's
process/init before any command dispatches; only a bare `go test` of the
plugin package (which never runs charly's init) needed the fake seam.
Verification: go build/vet clean for charly/, candy/plugin-pod/, and sdk/;
`go test ./charly/...` full suite green (174.9s); `go test ./...` in
candy/plugin-pod green; R5 grep self-test clean (every deleted identifier
survives only in explanatory "formerly X" comments, the codebase's
established convention, never a live reference); `task cue:gen` reproduces
a clean, minimal diff (SDD no-op elsewhere).
This is slice 1 of wave γ (~1,600-1,750 net core LOC target, grown with
K1-α residue + seam-helper fold-ins at landing per the wave contract in
scratchpad/loc-ledger.md). Remaining in this family: secrets.go,
layer_secrets.go, config_secret_migration.go, credential_plugin.go
(capstone deletion), runtime_config_values.go + host_build_settings.go,
the pod_lifecycle_resolve.go start/stop enc plan-builders, and the ADE
check-coverage gap (no bed exercises `charly config mount/unmount/status/
passwd` or `charly settings` end-to-end) — none landed in this commit.
Assisted-by: Claude Code (Anthropic Claude Sonnet 4.5; analysed on a live system)
…, retire settings seam
Wave γ (credential/enc/settings InvokeProvider unification), slice 2: the
"settings" HostBuild seam existed purely to reach core's config-file I/O
(GetConfigValue/SetConfigValue/ListConfigValues/ResetConfigValue) and 3
credential-store touches (vnc.password.* get/set/delete, secret_backend's
store reset/name) from candy/plugin-settings. candy/plugin-settings'
provider.go already gets a real reverse-channel *sdk.Executor at
Invoke(OpRun) (same as candy/plugin-pod), so the whole config subsystem
now lives IN the plugin: file I/O calls sdk/kit directly (was already
portable, just relocated), credential touches dispatch verb:credential
via InvokeProvider — the same pattern candy/plugin-pod/enc_cmd.go
(previous slice) and candy/plugin-deploy-pod/lifecycle.go already prove.
- candy/plugin-settings/config.go (new, ported from
charly/runtime_config_values.go + charly/host_build_settings.go):
GetConfigValue/SetConfigValue/ResetConfigValue/ListConfigValues/
resolveSettingsGet, byte-identical logic, plus a plugin-local
credentialCall/credentialResolve/credentialSet/credentialDelete/
credentialName/credentialReset helper set (own small wire-shape copy,
the established cross-module convention — see enc_cmd.go's precedent).
- candy/plugin-settings/command.go: runSettingsCLI calls the ported
functions directly instead of hostSettings/HostBuild("settings").
- candy/plugin-settings/plugin.go: CliMain now refuses UNCONDITIONALLY
(not per-op) — out-of-process placement stays settings' unsupported/
untested placement, matching pre-cutover behavior exactly, even though
the non-credential ops are now technically pure-portable. A deliberate
scope boundary: loosening out-of-process placement is a separate
decision, not a side effect of this port.
- charly/runtime_config_values.go, charly/host_build_settings.go: deleted
wholesale — every caller moved.
- charly/credential_plugin.go: resetDefaultStore/resetDefaultCredentialStore
+ the credentialResetter interface + pluginCredentialStore.reset()
deleted — all became dead once runtime_config_values.go's SetConfigValue/
ResetConfigValue (their only real callers) moved. charly/credential_fake_test.go's
matching fakeCredentialStore.reset() stub removed too (R5 full chain).
- sdk/schema/settings.cue: deleted wholesale (the #SettingsRequest/
#SettingsEntry/#SettingsReply wire defs, now dead); `task cue:gen`
regenerated clean.
- Test coverage: the SetConfigValue/GetConfigValue/ResetConfigValue/
ListConfigValues-dependent tests from charly/runtime_config_test.go
ported verbatim to candy/plugin-settings/config_test.go (ctx=
context.Background(), exec=nil — none of the ported tests touch a
credential-backed key, so no InvokeProvider dispatch is reached,
mirroring the previous slice's enc_cmd_test.go precedent). The
remaining pure-kit.* tests (ResolveRuntime/SystemdUserAvailable/
DetectRunMode/...) stay in charly/runtime_config_test.go unchanged.
Verification: go build/vet clean for charly/, candy/plugin-settings/,
candy/plugin-status/, and sdk/; `go test ./candy/plugin-settings/...`
green (10/10); `go test ./charly/...` full suite green (171.1s, rerun
green again after the credential_plugin.go dead-code sweep); gofmt clean
on every touched file; R5 grep self-test clean (every deleted identifier
survives only in "ported from X" explanatory comments — the codebase's
established convention — plus one stale cross-reference in
candy/plugin-status/command.go's doc comment, fixed in the same change);
`task cue:gen` reproduces a clean, minimal 2-file sdk diff.
This is slice 2 of wave γ. Combined with slice 1 (a466fb9): charly core
net so far -650 LOC (enc.go/config_image.go/host_build_pod_config.go/
runtime_config_values.go/host_build_settings.go/credential_plugin.go
trimmed, zero net core additions), sdk net -160 LOC. Remaining in this
family: secrets.go, layer_secrets.go, config_secret_migration.go,
credential_plugin.go's remaining pluginCredentialStore surface (313 LOC —
still has live callers: ResolveCredential/DefaultCredentialStore used by
secrets.go/layer_secrets.go/config_secret_migration.go/
host_build_deploy_entity_resolve.go — capstone deletion not yet legal),
pod_lifecycle_resolve.go's start/stop enc plan-builders, and the ADE
check-coverage gap (no bed exercises `charly config mount/unmount/status/
passwd` or `charly settings` end-to-end) — none landed in this commit.
Assisted-by: Claude Code (Anthropic Claude Sonnet 4.5; analysed on a live system)
…gh the load-bundle seam
Wave γ DeployStateHost audit (operator directive, following the slice-1
review): candy/plugin-pod/enc_cmd.go's pluginEncMount/Unmount/Status/Passwd
called deploykit.EncPlanFor/EncStatus directly — both transitively reach
the placement-dependent bare deploykit.LoadBundleConfig() (silently
degrades to "no encrypted volumes" outside charly-core's own process,
per deploy_file.go's documented historical failure mode). Safe today
because command:config is compiled-in-only (CliMain refuses out-of-process
placement unconditionally), but that's a per-BUILD fact, not a guarantee —
the same reasoning candy/plugin-pod/remove_orchestration.go's
resolveSidecarNames fix already establishes for the identical bug class.
- Added loadPodBundleConfig(caller) — fetches the BundleConfig via the
EXISTING deploykit.LoadBundleConfigViaSeam ("pod-config-load-bundle"
seam) instead of leaving EncPlanFor/EncStatus to reach the bare call
themselves (R3, no new seam invented).
- pluginEncStatus/Mount/Unmount/Passwd now load dc via the seam first,
then call the new sdk#84ee126 EncStatusFromConfig/EncPlanForConfig
(seam-routable siblings — same repo, sdk PR).
- pluginEncPasswd's interactive triple-prompt gets a non-interactive
GOCRYPTFS_OLD_PASSWORD/GOCRYPTFS_NEW_PASSWORD env override (new
pluginAskPassword helper), mirroring deploykit.ResolveEncPassphrase's
existing GOCRYPTFS_PASSWORD "1. Test/CI override" precedent — needed so
an R10 check bed can exercise `charly config passwd` non-interactively
(systemd-ask-password genuinely needs a TTY; a live RDD spike confirmed
piping stdin does not work). Interactive use is unaffected.
- enc_cmd_test.go rewritten to exercise the REAL seam path: a fake
pb.ExecutorServiceClient (HostBuild + InvokeProvider) via
sdk.NewInProcExecutor, mirroring sdk/deploykit/
load_bundle_config_seam_test.go's established fixture convention,
replacing the DeployStateHost-registration fake the previous commit
used (that fake is now the WRONG mock — production no longer reaches
DeployStateHost at all from this file). Added
TestPluginEncStatus_RoutesThroughSeam and
TestPluginEncMount_NilExecutorErrors for the new seam + nil-guard paths.
Verification: go build/vet clean for candy/plugin-pod/ and sdk/;
go test ./candy/plugin-pod/... green (6/6 enc + existing tests);
go test ./charly/... full suite green (149.3s) — the CORE callers of
EncPlanFor/EncStatus (pod_lifecycle_resolve.go, unchanged) stay
byte-behavior-identical since sdk#84ee126 keeps them as thin wrappers.
NOT yet live-verified on a disposable bed: pushed the check-enc-pod ADE
extension for this to box/fedora, but hit a genuinely pre-existing,
much broader bug while running it — deploy-level `volume:` blocks
declared on a PROJECT-level entity (not just encrypted ones) are never
picked up by ANY deploy machinery, because every read path
(EncPlanFor/LoadEncryptedVolume, candy/plugin-deploy-pod's
resolvePodRuntimeImage via loadDeploy) resolves deploy volumes from the
per-host overlay (~/.config/charly/charly.yml) ONLY, and nothing seeds
that overlay from the project's own charly.yml declaration. Confirmed via
a live check-enc-pod run (7/32 steps failed, including the bed's
PRE-EXISTING enc-status-mounted step, unrelated to this commit) and a
manual `charly bundle add` reproduction showing zero bytes written to the
per-host overlay. This is a pre-existing, out-of-wave-γ-scope gap (core
deploy-volume resolution, not credential/enc/settings) — reported to the
operator/orchestrator for routing; this commit's own confidence tier
reflects "analysed on a live system" for the plugin-pod/sdk unit-test
surface, with the check-enc-pod bed extension itself held back
(uncommitted, box/fedora working tree) pending that fix.
Assisted-by: Claude Code (Anthropic Claude Sonnet 4.5; analysed on a live system)
…mount/tunnel plan-building
Wave gamma: relocates charly/pod_lifecycle_resolve.go's resolvePodEncEnsure/
resolvePodEncUnmount/resolvePodTunnel into candy/plugin-deploy-pod
(enc_tunnel_resolve.go) - the start/stop lifecycle family, disjoint from
the Setup family (config_setup.go) already ported by earlier waves.
Extends the ALREADY-LIVE InvokeProvider pattern lifecycle.go proves for
the enc/tunnel EXECUTION legs: resolve.go's 3 callers (resolvePodStart
Quadlet/StartDirect/StopPlan) now build their own plan locally instead of
round-tripping through 3 core HostBuild seams.
- candy/plugin-deploy-pod/enc_tunnel_resolve.go (new): resolvePodEncEnsurePlan/
EncUnmountPlan/TunnelPlan, direct ports using sdk#84ee126's
EncPlanForConfig/LoadEncryptedVolumeFromConfig (dc is now a plain
parameter the caller loads ONCE via the EXISTING "pod-config-load-deploy"
seam, never re-derived per-call) plus a local credential-RPC helper
(pluginCredentialAccess, the established per-package wire-copy
convention already used by candy/plugin-pod/enc_cmd.go and
candy/plugin-settings/config.go).
- candy/plugin-deploy-pod/resolve.go: resolvePodStartDirect now reuses
the dc it already loaded via resolvePodRuntimeImage (img.dc) instead of
a REDUNDANT second HostBuild round-trip the old seam-based code paid on
every direct-mode start - a net efficiency win, not just a relocation.
- charly/pod_lifecycle_resolve.go: deleted wholesale (100% dead - every
caller moved).
- charly/host_build_pod_config_seams.go: hostBuildPodConfigEncEnsurePlan/
EncUnmountPlan plus their consts/registrations deleted.
hostBuildPodConfigContainerTunnel STAYS - R1 catch mid-port:
candy/plugin-pod/remove_tunnel.go (a DIFFERENT plugin, the charly
remove teardown path) is a separate live caller of the SAME
"pod-config-container-tunnel" seam; "this seam has one caller I'm
porting FROM" is not the same claim as "this seam has only one caller"
- traced the full caller graph before deleting, caught it before it
shipped broken.
- charly/enc.go: header comment corrected (no longer claims
pod_lifecycle_resolve.go's enc-ensure plan-builder is "out of this
wave's scope" - it moved).
Verification: go build/vet clean across sdk/, charly/,
candy/plugin-pod/, candy/plugin-deploy-pod/. New unit tests
(enc_tunnel_resolve_test.go, 6 tests) cover the enc-unmount plan-building,
the enc-ensure short-circuit (real cipher-dir fixtures, both Initialized
and Mounted gate flags genuinely true, not faked around), the
zero-volumes path, and the no-running-container tunnel path - deliberately
NOT the credential-resolution branch with no env override, since
deploykit.AskPassword's production path (systemd-ask-password
--timeout=0) blocks INDEFINITELY without a real TTY; documented the
hazard in-file for future editors. All 4 module test suites green
(deploykit, plugin-pod, plugin-deploy-pod, full charly/... at 163.2s).
gofmt clean. R5 grep self-test clean.
WIP CHECKPOINT, not a landing claim: this is unit-tested only
("syntax check only" tier) - the live proof (charly start/stop
against a real encrypted-volume plus tunnel deploy) needs a disposable
bed with a working deploy-level volume, currently blocked by a
pre-existing, out-of-wave-gamma bug (deploy-level volume: blocks on
project-declared entities are never picked up by any deploy machinery -
traced and reported; routed to a dedicated fix teammate, deploy-vol-fix).
This branch does NOT land to main until that live proof is pasted.
Checkpointed now per the durable-WIP-commit discipline (zero-loss
handoffs) rather than risk losing unit-tested, reviewed work to a
session interruption.
Assisted-by: Claude Code (Anthropic Claude Sonnet 4.5; syntax check only - live R10 pending deploy-vol-fix merge)
…eat/layer1-coremin-integration # Conflicts: # sdk
…ter gamma's enc/config InvokeProvider port Assisted-by: Claude Code (Anthropic Claude Sonnet 5; analysed on a live system)
… to sdk/buildkit+kit
Part of the P8b build-engine core-minimization wave (Layer-1 mini-cutover).
Deletes charly/init_config.go, charly/layer_capabilities.go, and
charly/shell_profile.go (419 LOC) — their logic relocated to
sdk/buildkit/{init_config,capabilities}.go and sdk/kit/profile.go (this
sdk submodule bump), which have zero charly-core dependency (*Config/
*Generator/*UnifiedFile/providerRegistry) and are therefore genuinely
portable, unlike the rest of the P8b build-engine file set (see the
Layer-1 spike report: ~90% of that set is floor pending the K1 loader/
materialize envelope refactor).
Every call site repointed to buildkit.InitConfig / buildkit.
AggregateCandyCapabilities / buildkit.CheckRequiredCapabilities /
buildkit.CandyCapabilitiesError; deploykit's RemoveEnvdFile var now
calls kit.RemoveEnvdFile directly instead of charly-core's injected
seam. Two confirmed-dead symbols (FragmentContext, SystemEnableContext)
and one pure-indirection var (initRenderRelayTemplate, replaced by a
direct deploykit.InitRenderRelayTemplate call in its one test caller)
were deleted rather than moved, verified dead via a test-inclusive grep.
go build/vet/test: clean on both repos. golangci-lint: 0 issues on both.
R5 grep-clean: confirmed (build success + no bare-identifier references
remain outside field names/accesses and prose).
Assisted-by: Claude Code Anthropic Claude Sonnet 5 (syntax check only)
isHostNetworked duplicated kit.IsHostNetworked (sdk/kit/container_probe.go) byte-for-byte, left over from an earlier incomplete relocation; repoint check_venue.go's sole caller and delete the core copy. deployNestedLocalChildren/ waitForVmSshReady/waitForContainerReady in check_bed_run.go were 1-line pass-throughs to deploykit.* with zero core-only behavior and no plugin caller that needed a core-side name; deleted, with their 3 call sites (bundle_members.go, host_build_check_bed.go) repointed to deploykit.* directly. Assisted-by: Claude Code (Anthropic Claude Sonnet 5; analysed on a live system)
Part of the "every build-engine capability is a plugin" cutover (BUILD cone, mandate: candy/plugin-build + sdk/buildkit). Deletes charly/privileged_runner.go and candy/plugin-vm/vm_privileged_runner.go (both byte-for-byte duplicates of the privileged-container exec primitive, R3) in favor of the single sdk/buildkit copy landed in the companion sdk commit. charly/build.go's runPrivilegedBootstrap and candy/plugin-vm's bootc/bootstrap disk-build engines now call buildkit.RunPrivileged/buildkit.PrivilegedRun/buildkit.RenderBootstrapScript directly; the two remaining copyFileBytes call sites (charly/generate.go's bake-plugin staging, a plugin-secrets live test) repoint to the exported buildkit.CopyFileBytes. go build/vet: clean (charly, candy/plugin-vm, sdk/buildkit). go test -short ./charly/...: PASS (133s, box/fedora submodule initialized to unblock TestPluginInstallstepEnvelopeParity — a pre-existing fresh-worktree gap unrelated to this change). R5 grep-clean: no remaining bare RunPrivileged/PrivilegedRun/ renderBootstrapScript/copyFileBytes/readEngineRootful references outside the buildkit package. Assisted-by: Claude Code Anthropic Claude Sonnet 5 (analysed on a live system)
The plan-walk that discovers which images an iterate plan's steps spawn (dedup + sort over step venues) is pure and moves to candy/plugin-check/preflight_images.go. Only the two genuinely host-loader-coupled bits stay behind the "check-run"/"preflight" seam: the agent-provisioned filter (needs the loaded project's full bundle tree) and EnsureImagePresent (the shared build-engine helper). Net: -68 core LOC (check_image_preflight.go deleted), +~65 plugin LOC. Assisted-by: Claude Code Anthropic Claude Sonnet 5 (syntax check only)
…ttedApk Thins the core hostVerbResolver wrapper to the two host-only inputs (CandyDirs/CandyScanErr) the shared kit.ResolveCommittedApk needs. Bumps the sdk gitlink to the companion commit (sdk PR pending, branch feat/check-plugin-100-apk in the sdk submodule). Assisted-by: Claude Code Anthropic Claude Sonnet 5 (syntax check only)
Continuation of the BUILD-cone cutover (paired sdk commit 32f0c1d). Deletes normalizeBoxArgs, filterBox, resolvePodmanJobs + numCPU + podmanJobsCapFallback, hostPlatform, charlyBinaryUpToDate, bootstrapPackagesForBox, renderPacstrapExtraConf, and renderRuntimePacmanConf from charly/build.go — none of them were loader- or registry-coupled, so they had no architectural reason to stay in core (the "it takes *Config/*Generator" excuse never applied to these; they operate purely over buildkit.ResolvedBox / spec.Pacstrap / stdlib). Call sites in charly/build.go, charly/build_resolve_host.go, and their test files now call buildkit.NormalizeBoxArgs / deploykit.FilterBox / buildkit.ResolvePodmanJobs / buildkit.HostPlatform / buildkit.CharlyBinaryUpToDate / buildkit.BootstrapPackagesForBox / buildkit.RenderPacstrapExtraConf / buildkit.RenderRuntimePacmanConf directly. Test coverage for TestNormalizeBoxArgs and TestResolvePodmanJobs moved to sdk/buildkit/build_helpers_test.go alongside the relocated logic (same assertions, same table-driven cases). go build/vet: clean (charly, sdk/buildkit, sdk/deploykit, candy/plugin-vm). golangci-lint: 0 issues (charly, sdk/buildkit+ deploykit, candy/plugin-vm). go test -short ./charly/...: PASS (139s, full suite). Assisted-by: Claude Code Anthropic Claude Sonnet 5 (analysed on a live system)
Continuation of the BUILD-cone cutover (paired sdk commit 92851d3).
Deletes resolveStatus/candyStatus/statusSeverity/worstStatus +
Status{Working,Testing,Broken} from charly/generate.go — pure over
spec.CandyReader, no loader/registry coupling. generate.go's own
doc comment call site is gone (no in-file callers remained after the
retired Description.Tag derivation note); render_baked_metadata.go's
status/info-gathering block now calls
buildkit.StatusWorking/CandyStatus/WorstStatus/ResolveStatus.
go build/vet: clean. golangci-lint: 0 issues (charly, sdk/buildkit).
go test -short ./charly/...: PASS (133s).
Assisted-by: Claude Code Anthropic Claude Sonnet 5 (analysed on a live system)
checkrun.go/check_members.go/check_cmd.go call kit.StampCharlyBin / kit.NewRuntimeCheckVarResolver directly instead of hosting their own copies — the shared logic lives in sdk/kit (companion commit, feat/check-plugin-100-apk branch in the sdk submodule), reachable from both the check and deploy runtime call sites (R3). Assisted-by: Claude Code Anthropic Claude Sonnet 5 (syntax check only)
Continuation of the BUILD-cone cutover (paired sdk commit 2f39ed1, which extends spec.BuildResolveBox with the bootstrap descriptor fields this move rides). Deletes BuildCmd.runPrivilegedBootstrap (~110 LOC) from charly/build.go — the host build-prep seam (build_resolve_host.go) no longer runs the privileged container itself; it only resolves WHICH builder/distro def applies to a `from: builder:<name>` image (a charly.yml lookup that genuinely needs the live *Config/*BuilderConfig graph) and rides the minimal slice back on each spec.BuildResolveBox descriptor. candy/plugin-build/bootstrap.go now owns the actual privileged exec: bootstrapImages runs before the podman build loop in runBoxBuild, calling buildkit.RunPrivileged/RenderBootstrapScript/ BootstrapPackagesForBox/RenderPacstrapExtraConf/RenderRuntimePacmanConf — all already relocated to sdk/buildkit in prior commits of this cutover. Its own ensureBuilderImageBuilt auto-builds a missing builder image by recursing into runBoxBuild directly (in-process — the podman drive already lives in this candy, so no HostBuild/registry round-trip is needed the way the former host-side helper needed dispatchBoxBuild). charly-core's OWN ensureBuilderImageBuilt + CredentialStore-style dispatchBoxBuild path is UNCHANGED and stays — it's still the shared entry the VM-bootstrap path (host_build_vm_build.go) calls, out of this cutover's scope. go build/vet: clean (charly, sdk/buildkit+deploykit, candy/plugin-build). golangci-lint: 0 issues (charly, sdk/buildkit+deploykit, candy/plugin-build). go test -short ./charly/...: PASS (119s). TestGenReproducible: PASS. Assisted-by: Claude Code Anthropic Claude Sonnet 5 (analysed on a live system)
…dk head, already a descendant)
…+ CUE-derive externalizedDeploySubstrates Deploy-cone cutover 1, part 1/N: - resolveAndroidGoogleCreds moves out of charly/host_build_deploy_entity_resolve.go into candy/plugin-adb (credential_shim.go), reaching verb:credential directly via InvokeProvider instead of the host pre-resolving the google-play credentials behind the "deploy-entity-resolve" seam. Repoints sdk to the AndroidEntityResolution field-drop companion. - provider_deploy.go's externalizedDeploySubstrates (task #21): derive from deployTargetWords (itself CUE-derived from spec.ResourceKinds) via setFromSlice, instead of a hand-written map literal — the same un-gameable-self-test leak class resourceKindSet already avoids. Assisted-by: Claude Code Anthropic Claude Sonnet 5 (analysed on a live system) (cherry picked from commit a520351396052bce289e77b4a2ea59f72795aa42)
…clared trait, not word map Deploy-cone cutover 1, item 1: unified_targets.go's Start/Stop no longer derive "does this substrate need the Q1 resource-arbiter bracket" from whether a core-side lifecycleStartPlanHooks/ lifecycleStopPlanHooks map happens to have an entry for t.word — they read it off the substrate-plugin-DECLARED #DeployTraits. bracketed_lifecycle trait (stamped onto node.Descent by kit.StampDescent, P9), matching every other substrate-behaviour consult site in the deploy chain. candy/plugin-substrate declares bracketed_lifecycle:true for pod only (vm manages its own venue lifecycle + resource claim via `charly vm start`/`stop`). The registered opts-marshal closures (pod_lifecycle_dispatch.go) are unchanged — they're inherently CLI-invocation-context-bound (podStartOptsFromCtx reads a ctx value only `charly start`'s Kong Run() sets, unreachable from an out-of-process plugin) — but the map is now consulted only to FIND the closure once the trait says one should exist; a trait/map mismatch is a hard error instead of a silent no-op. Also fixes two stale doc-comment references to the deleted charly/arbiter_bracket.go (R1) — the Q1 bracket now lives in candy/plugin-bundle's runLifecycleBracket. Assisted-by: Claude Code Anthropic Claude Sonnet 5 (fully tested and validated) (cherry picked from commit 2b312acc2950c57d7d8667dc382b964a75c2d5f9)
… propagating #DeployTraits.bracketed_lifecycle trait
R10 (check-pod) caught a blocking regression from cutover-1 item 1 (bracketed_lifecycle trait):
the declared trait was dropped on the ProvidedCapability proto round-trip because both the sdk
encode (schema.go, fixed in the sdk leg) AND the charly decode (plugin_provider_common.go) copied
only the pre-existing DeployTraits fields, never the new BracketedLifecycle. So
deployTraitsFor("pod").BracketedLifecycle was always false, item 1's bracketedLifecycle() read a
false negative, hasPlan=false, the Start opts closure was skipped, and plugin-deploy-pod's start op
failed 'decode opts: unexpected end of JSON input'. Fix, completing item 1's seam properly: (1) the
charly decode carries BracketedLifecycle (sdk encode in the companion leg); (2) bracketedLifecycle()
derives the signal from the now-propagating DECLARED trait resolved by word from the provider
registry — NOT from lifecycleStartPlanHooks map presence (that map stays the host-side opts-marshaling
MECHANISM; the bracket signal is declared data, the boundary-law-correct source). No dead trait field,
no per-word map read for the signal. Verified: charly start check-pod exits 0 via the trait path.
Assisted-by: Claude Code (Anthropic Claude Opus 4.8; analysed on a live system)
…leged_runner.go from present-tense caller/importer comments
Cutover 1 deletes charly/pod_lifecycle_resolve.go and charly/privileged_runner.go (relocated to
candy/plugin-deploy-pod and candy/plugin-build). Four core comments named them as CURRENT
callers/importers ('every caller (…, pod_lifecycle_resolve.go) now calls', 'privileged_runner.go
now import', 'Both consumers — pod_lifecycle_resolve.go and config_image.go are…', 'its 2 callers
(cmd.go, pod_lifecycle_resolve.go) now call') — stale current-state claims after the deletion.
Reword to the accurate current caller/importer sets. Past-tense/provenance mentions (commands.go
'were still calling', enc.go 'former …'/'is DELETED') are accurate history and kept.
Assisted-by: Claude Code (Anthropic Claude Opus 4.8; analysed on a live system)
…y CHANGELOG B2 consumer leg: sdk PR #102 merged (squash 1bfa4b1, tagged v0.2026206.837); repoint the sdk gitlink from the feat branch to the merged sdk main commit and bump charly/go.mod's require to match. charly builds + go test ./... green against the merged sdk; the R10 roster (check-pod / check-k3s-vm / arch-pacstrap privileged-bootstrap, all green concurrently) is unaffected (the merged sdk's non-test code is identical to the validated branch). Assisted-by: Claude Code (Anthropic Claude Opus 4.8; fully tested and validated)
pr-validator — CHANGES REQUESTED ❌Change class: runtime (charly Go code + candy config) What I independently ran
The blocking finding — R1 + R5 (hard cutover) violated; the PR's own R5 self-test claim is falseThe PR body states: "R5 grep self-test: no present-tense reference to a deleted file/symbol remains (past-tense/provenance history kept)." This is not true for this PR's own tree. This cutover's commit But present-tense references to the now-deleted seam survive in the FINAL shipped tree, outside
This is precisely the class of incident CLAUDE.md's R1 ("documentation divergence is an incident... the fix is BLOCKING in the current cutover") and R5 ("the SAME commit deletes the old code path AND every reference... Corroboration this sweep was simply skipped, not attempted-and-missed: Compounding — item 1, description completenessThe PR's "Cones relocated" section names four cones (Build, Check, Deploy, Deploy-substrate, Credential/enc) and never mentions a fifth: Settings/Config ( Checklist
Comments consideredNone — the PR carries no comments. Cross-PR interactions considered
DecisionFAIL. This is a real, verified R1/R5 hard-cutover violation, not a stylistic nitpick: the PR's own required R5 self-test claim ("no present-tense reference to a deleted file/symbol remains") is demonstrably false for this exact tree, and a whole capability cone (Settings/Config) is relocated without being named in the PR's summary or R10 evidence. What the author must fix, in the same tree, on the same branch:
Assisted-by: Claude Code (Anthropic Claude Sonnet 5; analysed on a live system) |
…settings HostBuild seam' refs (pr-validator #188 r1) The #188 validator correctly caught an undisclosed 5th relocation cone and stale R5 refs my sweep missed (it scoped charly/+plugins/ .go only, missing charly.yml + candy/*/charly.yml): - Settings/Config cone: host_build_settings.go + runtime_config_values.go → candy/plugin-settings/ config.go (plugin OWNS its config I/O; the 'settings' HostBuild seam is RETIRED — config.go's own header is the accurate source of truth). Now disclosed in the CHANGELOG + a Settings cone section. - R5: candy/plugin-settings/charly.yml, root charly.yml's check-commands-local bed plan (comment + description + the settings-list check step), and charly/provider_command_test.go all described the RETIRED settings seam / deleted host_build_settings.go in present tense — updated to the shipped plugin-owned architecture (clean's separate 'retention' seam kept intact, not conflated). - R10: check-commands-local bed PASS (6 steps, fresh-rebuild, ok:true, 185s) proves charly settings list end-to-end via the plugin-owned config I/O. Assisted-by: Claude Code (Anthropic Claude Opus 4.8; fully tested and validated)
… plan-check to the shipped plugin-owned architecture Follow-up to 89abf39 (its candy/ edit was lost to an over-broad 'git checkout -- candy/' that discarded pollution AND this fix). candy/plugin-settings/charly.yml's own description block + the settings-module-present plan check still described the RETIRED 'settings' HostBuild seam / deleted charly/host_build_settings.go in present tense — updated to match config.go (the plugin OWNS its config I/O; seam retired; verb:credential via InvokeProvider). Assisted-by: Claude Code (Anthropic Claude Opus 4.8; analysed on a live system)
pr-validator — APPROVED ✅ (round 2)Change class: runtime (charly Go code + candy config); the round-2 delta itself is docs-only (charly.yml, plugin-settings/charly.yml, provider_command_test.go comment, CHANGELOG) Round-1 finding — independently re-verified as RESOLVEDRound 1 (comment #issuecomment-5077819755) found an R1/R5 violation: present-tense references to the deleted R5 grep self-test, re-run by me from scratch, repo-wide: Every live (non- Doc-accuracy cross-check against the actual shipped code ( Clean's "retention" seam was not disturbed: Disclosure: the PR body now names a "Settings/Config → Settings R10 evidence — verified on disk, not re-run (orchestrator-owned, per instructions)
6 steps, One nuance I chased down and resolved: this run's calver ( Re-confirmed (round 1 already passed these; spot-re-verified independently, not re-litigated)
Checklist
Comments considered
Cross-PR interactions considered
DecisionPASS. The round-1 R1/R5 violation is genuinely fixed, independently re-derived from the diff and the live tree (not taken on the PR's word): the grep self-test returns only provenance/retirement hits, the rewritten docs match the actual shipped Assisted-by: Claude Code (Anthropic Claude Sonnet 5; fully tested and validated) |
pr-validator round 2: PASS. Rename CHANGELOG placeholder to the merge-time stamp and re-stamp the H1 heading to match. Assisted-by: Claude Code (Anthropic Claude Sonnet 5; fully tested and validated)
…ent, and three stale figures B1 — command.go still described driftCmd as "the CI gate" and "(the docs:drift model)", the two claims this cutover measured false and removed everywhere else. It contradicted generate.go's own comment ten lines away, inside the same diff. The per-repo sweep found exactly one surviving site, in the superproject only — the one file no projection carries, which is why no downstream review met it. B3 — the entry said "Four plugins legs". Six carried this cutover's prose: #186, #187, #188, #190, #193, #194. The line was authored in the final commit, after all six had landed. Enumerating by `git log | grep '(#N)'` is unreliable here: #186, #187 and #190 have squash subjects that carry no PR-number suffix, so the count came from the merged-PR list instead. B4 — the reference index still called status-absence on a known head "a false negative" while the section it indexes now says it "proves nothing". Those are different claims: one asserts the thing is real but unseen, the other that the observation is uninformative. B6 — the tag invariant placed 2026.215.1207 both in the untagged set ("at or before") and inside the tagged 67-for-67 run. It is untagged, and is the latest untagged entry, so the run opens above it. Assisted-by: Claude Code Anthropic Claude Opus 5 (analysed on a live system)
Cutover 1 — plugins-for-everything, part 1: build / check / deploy / credential cone capability out of core
The first cutover of the "plugins-for-everything, 100%" program. Every cone's UNBLOCKED capability (the code that needs no loader-keystone refactor to relocate) moves from
charly/core into its owning plugin candy, importing only the sdk. Consumes the merged sdk contract leg (sdk PR #102); this PR'ssdkgitlink points at the merged sdk commit (B2 producer-first).Net core non-test reduction: −2,612 LOC (55 files, +330/−2942; 11
charly/files deleted).Cones relocated
candy/plugin-build: privileged builder-bootstrap (privileged_runner.go/RunPrivileged→sdk/buildkit),InitConfig/capability-aggregation/envd-removal/7 pure helpers →sdk/buildkit+sdk/kit,FilterBox→sdk/deploykit.candy/plugin-check: image-preflight discovery, container-network probe,resolveCheckApk→sdk/kit.ResolveCommittedApk;CHARLY_BINstamping + runtime check-var resolution →sdk/kit.candy/plugin-substrate/plugin-deploy-pod/plugin-adb:#DeployTraits.bracketed_lifecycle(SDD — the Q1-arbiter-bracket signal is now the DECLARED trait resolved by word, notlifecycleStartPlanHooksmap presence);externalizedDeploySubstratesCUE-derived fromspec.ResourceKinds(task feat(spec)!: adopt CUE-sourced buildctx keystones + wire-type CUE mandate (P2/S1) #21); android google-play creds resolved peer-to-peer inplugin-adbviaInvokeProvider(verb:credential).candy/plugin-deploy-pod: pod start/stop enc-ensure/enc-unmount/tunnel plan-building ported overInvokeProvider; deadcredentialAwaiterinterface deleted.candy/plugin-settings: the runtime-config subsystem (GetConfigValue/SetConfigValue/ListConfigValues/ResetConfigValue/resolveSettingsGet) ports fromcharly/runtime_config_values.go+charly/host_build_settings.gointocandy/plugin-settings/config.go(purekit.LoadRuntimeConfig/SaveRuntimeConfigI/O; the 3 credential-store touches viaverb:credentialInvokeProvider). The "settings" HostBuild seam is RETIRED — the plugin owns its config I/O. Stale "settings seam" descriptions inplugin-settings/charly.yml, the rootcharly.ymlbed plan, andprovider_command_test.goupdated to the shipped architecture (R5).The regression this PR cleared (R1)
The
check-podbed caught a blocking regression: the newbracketed_lifecycletrait was silently dropped on theProvidedCapabilityproto round-trip because both the sdk encode (schema.go, fixed in #102) and the charly decode (plugin_provider_common.go) copied only the pre-existingDeployTraitsfields. SodeployTraitsFor("pod").BracketedLifecyclewas always false →hasPlan=false→ empty Start opts →plugin-deploy-pod start: decode opts: unexpected end of JSON input. Fixed by carrying the field through encode+decode and deriving the bracket signal from the now-propagating declared trait (the boundary-law-correct source; the per-word hook map stays purely the opts-marshaling mechanism). New unit testTestPluginDeployTarget_BracketedLifecyclekeys on the word → registry-resolved trait.Verification (R10) — the concurrent bed roster across all cones
check-podbed PASS (13 steps, fresh-rebuild) — build (image-build), check (check-image/check-live/feature), deploy-pod bracket (start/stop — the regression path), credential/enc (pod-start enc-ensure). Zero charly warnings.check-k3s-vmbed PASS (8 steps, 326s) — deploy-vm + k8s cone (the shared deploy-dispatch change now resolvesbracketedLifecyclefor vm viadeployTraitsFor→ false, unchanged behavior confirmed live).check-commands-localbed PASS (6 steps, 185s, fresh-rebuild) — the Settings/Config cone:charly settings listexits 0 and lists the resolved runtime-config keys, proving the plugin-owned config I/O end-to-end after the seam retirement.arch-pacstrapprivileged-bootstrap box build SUCCESS — the build cone's relocatedRunPrivileged/privileged builder-bootstrap (candy/plugin-build), whichcheck-pod's normal image build never exercises; builtarch-pacstrap-builder+arch-pacstrapbase.go test ./...(charly) green; sdk standalone battery green (see feat(check,box)!: check-config seam death + inspect/list -> plugin-box off the resolved-project envelope (Collection A) #102).go vetclean;gofmt -lclean on every changed file.deploy:localpath is unchanged by this cutover (bracketedLifecycle(local)=false, helpers substrate-agnostic) so a host-local bed cannot fail on the change (over-broad); the deploy cone is proven across pod + vm. Android cred relocation is proven by build +go test+ the established peer-InvokeProviderpattern (identical toplugin-vm'sverb:arbiter/gpu/egress);check-android-emulator-podcannot exercise the google-play cred path (the emulator installs local apks only) and is independently pre-blocked atdeploy-deviceby an unrelated PRE-EXISTINGspec.InstallPlaninterface-decode bug (identical onmain; tracked separately) — not a regression of this cutover.Assisted-by: Claude Code (Anthropic Claude Opus 4.8; fully tested and validated)