Repository navigation
Description
Category
category:delivery
Type
type:fix
Remedy / files the remedy will touch
the loader's defaults projection: spec #LoadedProject (+ its materialize) and charly/host_build_loader_floor.go's MaterializeLoadedProject merge — the project's defaults: block must survive the walk->materialize round trip
Cited design decision or org-rulebook rule (or none)
none
Classification
Blocking — it blocks the filer's own progress, so the filer claims it at filing and fixes it.
Evidence (verified: commands with output, file:line, measurements)
Reproduced 2026-11-27 with charly built from the pin bump (spec v0.2026331.1221,
sdk v0.2026331.1440, plugin-build v0.2026331.1456), against a mini project that authors:
defaults:
buildkit:
max_parallelism: 2
reserved_space: "50GB"
max_used_space: "60GB"
min_free_space: "7GB"
$ charly -C mini box validate
charly box validate: OK — checked 2 boxes, 6 distros, 7 builders; 0 warnings, 0 errors
$ charly -C mini box build testreuse # exit 0
$ grep -E "max-parallelism|reservedSpace|maxUsedSpace|minFreeSpace" \
"$XDG_CACHE_HOME/charly/buildkitd/buildkitd.toml"
max-parallelism = 4 <- NOT the authored 2
reservedSpace = "100GB" <- NOT the authored 50GB
maxUsedSpace = "100GB"
minFreeSpace = "10GB"
So cfg.Defaults.Buildkit is nil at resolve (plugin-build resolve.go: Buildkit: def.Buildkit).
SPEC IS NOT THE FAULT — a plain decode populates it:
$ go test ./spec/ -run TestZZDefaultsBuildkit -v
PROBE buildkit=&{MaxParallelism:2 ReservedSpace:50GB MaxUsedSpace:60GB MinFreeSpace:7GB}
The drop is in the loader chain: spec.LoadedProject (the walk envelope) has NO Defaults
field (spec/cue_types_gen.go: type LoadedProject struct carries EmbeddedDefaultsDigest
only), and charly/host_build_loader_floor.go materializes
merged := &spec.UnifiedFile{} from that envelope via
loaderkit.MaterializeLoadedProject, so merged.Defaults stays zero and
uf.Defaults.Buildkit is nil plugin-side.
Consequence: the authored defaults.buildkit surface is INERT. The 100 GB GC default still
applies (it is sdk-side), so the cache fix ships; only the AUTHORING of daemon settings is lost.
Mechanism
the loader materializes a fresh spec.UnifiedFile from spec.LoadedProject, which has no Defaults field, so merged.Defaults is zero and every authored defaults.* key the materialize step does not separately re-apply (buildkit) is lost before the plugin resolves
Missed control
the authored shape was validated by the #NodeDoc gate and pinned by a plugin unit test on a hand-built BoxConfig, so neither the loader round trip nor an end-to-end authored project was exercised; the surface was declared live on that basis
Blast radius
the whole authored defaults.buildkit surface (GC budget, worker knobs, gcpolicy, extra) is silently ignored while the shape validates and the build succeeds — invisible to the operator
Root fix
carry the project defaults through the walk envelope (or re-read them plugin-side) and assert them in a test that authors the block in a project file and checks the resolved reply's Buildkit
Spike (its result, or none with the reason)
none: the observation is the instrument (authored 50/60/7GB vs the written 100GB/4 daemon config, plus the YAML-decode control); the remedy is a loader-carried field
Agent: jolly-comet-ses_de3fa473bffeFiBo62whHxDPE5 · OpenCode session ses_de3fa473bffeFiBo62whHxDPE5
Assisted-by: OpenCode DeepSeek V4.1 Flash (analysed on a live system)
Activity
aitrawog commentedon Nov 27, 2026
CLAIM
Filed as blocking: it blocks this session's own progress, so this session claims it at filing and fixes it.
Agent:
jolly-comet-ses_de3fa473bffeFiBo62whHxDPE5· OpenCode sessionses_de3fa473bffeFiBo62whHxDPE5Assisted-by: OpenCode DeepSeek V4.1 Flash (analysed on a live system)
aitrawog commentedon Nov 27, 2026
CLAIM
Claiming: I filed this while landing the buildkit wave (#1292) and it invalidates a claim I had made, so it is mine to fix.
The authored
defaults.buildkitsurface is INERT until the loader carries the project defaults through the walk envelope. The pin bump for the wave is opening with exactly that scope stated: the pins deliver the sdk-side 100 GB GC default and plugin-build's ref reuse (both proven live), and the authored block becomes live when this issue lands.Fix site, from the evidence in the issue:
spec.LoadedProjecthas noDefaultsfield andcharly/host_build_loader_floor.gomaterializes a freshspec.UnifiedFilefrom it, somerged.Defaultsis zero. Producer-first: the carrying field is spec-side (plus its materialize), then the charly loader leg, then a bump.Agent:
jolly-comet-ses_de3fa473bffeFiBo62whHxDPE5· OpenCode sessionses_de3fa473bffeFiBo62whHxDPE5Assisted-by: OpenCode DeepSeek V4.1 Flash (analysed on a live system)
docs(merge): mark the defaults field list as hand-maintained, with it…
fix(merge): carry defaults.buildkit through the unified merge (#448)
chore(deps): adopt spec v0.2026331.1553 (defaults.buildkit survives t…
aitrawog commentedon Nov 27, 2026
RESOLVED — fixed by opencharly/spec#448 (merged, tag
v0.2026331.1553) and proven end to end on the consumer.mergeBoxConfignow carriesdefaults.buildkitthrough the walk→materialize merge (it was missing from the per-field list, so the block validated and then vanished).Consumer proof — a project authoring
max_parallelism: 2 / reserved_space: 50GB / max_used_space: 60GB / min_free_space: 7GB, built with a binary carrying the fix:Before the fix (same project, same command) the drive wrote
max-parallelism = 4and the sdkdefaults
100GB/100GB/10GB, becausemergeBoxConfigdid not carryDefaultValues.Buildkitthrough the walk→materialize merge.
Before the fix the same project wrote
max-parallelism = 4and the sdk defaults100GB/100GB/10GB. The consumer pin lands in #1307.chore(deps): adopt sdk v0.2026331.1440, spec v0.2026331.1553, plugin-…