Skip to content

fix(charly): re-pin sdk to the config-stack overlay fix + sweep the stale test comments - #631

Merged
github-actions[bot] merged 1 commit into
mainfrom
fix/sdk-repin-config-stack-sweep
Sep 22, 2026
Merged

github-actions[bot] merged 1 commit into
mainfrom
fix/sdk-repin-config-stack-sweep

Conversation

@aitrawog

Copy link
Copy Markdown
Contributor

Summary of changes

Re-pins github.com/opencharly/sdk to v0.2026265.2104 (the merged fix from opencharly/sdk#270) and sweeps the three test comments that documented the OLD three-layer config stack.

Why the pin bump. opencharly/sdk#270 removed spec.DefaultDeployConfigPath() from loaderkit/config_stack.go's stack. Before it, the per-host deploy overlay (~/.config/charly/charly.yml) was raw-merged as a project DOCUMENT layer, injecting a deploy-level member's top-level persisted copy next to the member its owner still declares nested — which FoldMembers rejects (peer name "..." collides with an existing deploy/bed/peer entry). Every member-bearing bed failed at steps=1.

The sweep (#630). With the pin advanced, three test comments asserting the old "sdk v0.2026250.702+ LoadUnified merges system → user → in-dir" behavior are now false, and the per-test t.Setenv("XDG_CONFIG_HOME", t.TempDir()) they justified is no longer needed — TestMain already sets XDG_CONFIG_HOME package-wide, and the per-test isolation existed ONLY to shield against the user-layer merge that is now gone. Swept:

  • charly/layers_test.go — removed the stale comment + t.Setenv.
  • charly/plugin_bootstrap_test.go — removed the stale comment + t.Setenv.
  • charly/unified_test.go — removed the stale comment + t.Setenv.

Concrete edits:

  • charly/go.mod — github.com/opencharly/sdk v0.2026260.1434 → v0.2026265.2104.
  • charly/go.sum — the sdk + spec checksums (tidy also advances github.com/opencharly/spec to v0.2026262.957, the version the bumped sdk requires).
  • the three test files above.

Change class

charly-or-sdk Go (charly core: dependency pin + stale-comment sweep in tests).

Closes / relates to: closes #630; relates to opencharly/sdk#270 (the merged fix this re-pins). opencharly/spec#142 (deletes the dead sibling merge.MergeConfigStack) is an independent companion — no ordering dependency (dead code).

Breaking change + rollback: no public surface changes — a dependency pin bump plus comment/test-isolation removal. Rollback: revert this commit (the pin returns to v0.2026260.1434).

How R10-tested — exact gate, commands, and pasted output

  • The gate for this change class: charly check run <bed> for the touched code path — the config-stack change is exercised by member-bearing beds; check-preempt-live-pod is the bed that regressed (steps=1) and must pass on the re-pinned tree.
  • Eval beds run — the EXACT bed + result:
    • check-preempt-live-pod | pod | ok | 22 steps | ~430s (opencharly/plugin-preempt)
    • Ran on charly version = 2026.249.2125, built from this branch (GOWORK=off go build -buildvcs=false -ldflags "-X main.BuildCalVer=2026.249.2125"), calver .check/check-preempt-live-pod/2026.265.2114/.
  • Fresh rebuild: the binary was rebuilt from this branch with the bumped pin; charly version = 2026.249.2125. The bed ran steps=22 at zero un-allowlisted warnings (one allowlisted dev-worktree-binary-notice per step).
  • Did the CHANGED code path execute live? Yes — the bumped dependency's readConfigStack is on the load path of every charly subprocess; the member builds (image-build-preempt-holder/-taker) now PASS and the full bed runs to verdict. The sweep itself is test-only; the full charly package ran green with it (below).
  • Concurrency (shared-state changes only): N/A — this change is a dependency pin + test-comment removal; it is not the loader/discover walk, ledger, podman store, arbiter, or a build lock.

Evidence — put each item in the block whose label names it.

1. Fresh-rebuild gate output (charly version + the gate run, at zero warnings):

$ /tmp/opencode/charly-sdk-repin-630/bin/charly version
2026.249.2125

$ charly check run check-preempt-live-pod
charly check run check-preempt-live-pod: [image-build-preempt-holder] PASS after 11.353s
charly check run check-preempt-live-pod: [image-build-preempt-taker] PASS after 11.849s
...
charly check run check-preempt-live-pod: PASS (steps=22) — repo override active
# 22 PASS-after steps, 0 FAIL

2. Each changed code path executing (the lines proving the changed branch ran, not that it built):

# The bumped sdk's config-stack fix is live in this binary (the pre-fix collision is gone):
charly check run check-preempt-live-pod: [image-build-preempt-holder] PASS after 11.353s   # was FAIL steps=1 pre-fix
charly check run check-preempt-live-pod: PASS (steps=22)

# The sweep is proven by the full charly package running GREEN with the isolation lines removed:
$ GOWORK=off go build ./...                  # exit 0
$ GOWORK=off go vet .                        # exit 0
$ GOWORK=off go test -count=1 .              # ok github.com/opencharly/charly/charly 252.777s
$ gofmt -l .                                 # empty

# R5 grep self-test — the stale claim is gone from charly live code (raw):
$ cd <this branch> && git grep -n "system → user → in-dir" -- . ; echo "exit=$?"
exit=1
$ git grep -n "USER config-stack layer" -- . ; echo "exit=$?"
exit=1
$ git grep -n "MergeConfigStack" -- . ; echo "exit=$?"
exit=1

3. Docs-only evidence: N/A — code change class (dependency pin + test edits).

Attribution tier

fully tested and validated. The re-pinned binary was rebuilt from this branch and the regressed bed (check-preempt-live-pod) executed live to PASS (steps=22); the swept tests ran green in the full charly package (go test -count=1 . = ok, 252.777s) at zero warnings, and the sweep removed the isolation those tests no longer need.

Harness rulebook compliance — state HOW each is satisfied (or N/A — <reason>)

  • R0 skills: loaded go (charly Go module, task build:binary, R9 freshness), git-workflow, root-cause-analyzer, strict-policy.
  • R1 RCA + zero warnings: the sweep is the R1 disposition of the stale claims surfaced by fix(loaderkit): the per-host deploy overlay is not a config-stack layer sdk#270 — established by grep (not assumed) and filed as sweep the stale config-stack test comments in the sdk re-pin PR #630 before the pin advanced. Build/vet/bed at zero un-allowlisted warnings.
  • R2 no out-of-scope: the stale-comment sweep could not ride sdk#270 (a different repo) and could not land before the pin advanced (the comments were still TRUE pre-fix); it is the immediate companion, tracked by sweep the stale config-stack test comments in the sdk re-pin PR #630 and landed here in the same change as the pin bump that made it necessary.
  • R3 no duplication: the per-test t.Setenv("XDG_CONFIG_HOME", …) duplicated TestMain's package-wide override; removing it deletes the redundant per-test copy now that its only rationale is gone.
  • R4 no workaround: no sleep/retry/magic-number; the pin is bumped to a merged tag (not a hand-pin of a PR branch) and the stale claim is removed rather than reworded.
  • R5 hard cutover + grep: raw git grep in block 2 — the stale system → user → in-dir / USER config-stack layer claims have ZERO hits in charly live code, and MergeConfigStack has ZERO hits (exit 1 each). No transitional/dual-mode path.
  • R6 git safety: fresh worktree off origin/main (this session's own), git status inspected before staging; commit on fix/ branch, PR-only, no force-push.
  • R7 runtime gate: the end-to-end bed gate ran on the re-pinned tree; the sweep is proven by the full package test with the isolation removed.
  • R8 artifact invariants: N/A — no generation/label change.
  • R9 binary == source + deps: binary rebuilt from this branch with the bumped pin; charly version = 2026.249.2125; no new runtime OS deps introduced by this change.
  • R10 disposable + coverage: proven on a disposable: true bed (check-preempt-live-pod, 22 steps) on a fresh rebuild at zero un-allowlisted warnings. The sweep's coverage is the full charly package (which would fail if the removed isolation were still needed).
  • RDD / ADE / SDD: RDD — the "isolation is now unnecessary" claim was bed/test-proven (full package green without it), not assumed. ADE — N/A (no candy). SDD — N/A (no schema/.cue edit).
  • Hard cutover: ONE atomic commit (52a1ce8b); pin bump + sweep together, no Phase-2.
  • Kernel/plugin boundary law: N/A — a dependency pin + test edits; no core/plugin placement change.
  • Disposable-only autonomy: N/A — no autonomous destroy/rebuild of a non-disposable target.
  • Clean architecture + Go gates: gofmt -l . empty; go vet . clean; go test ./... (full package go test -count=1 . = ok, 252.777s); go build ./... exit 0.
  • CHANGELOG: N/A — charly's CHANGELOG/ is written from the PR body by the merge workflow (existing entries are dated CalVer files authored at merge). No file staged.

Assisted-by: opencode ollama-cloud/deepseek-v4.1-flash (fully tested and validated)

…tale test comments

Bumps github.com/opencharly/sdk to v0.2026265.2104 (the merged fix from
opencharly/sdk#270: the per-host deploy overlay is no longer raw-merged as a
config-stack PROJECT layer) and sweeps the three test comments that documented
the OLD three-layer merge.

opencharly/sdk#270 removed `spec.DefaultDeployConfigPath()` from
loaderkit/config_stack.go's stack. Before it, a per-host deploy overlay was
raw-merged as a project document layer, injecting a deploy-level member's
top-level persisted copy next to the member its owner still declares nested —
which FoldMembers rejects (`peer name "..." collides with an existing
deploy/bed/peer entry`). Every member-bearing bed failed at steps=1.

With the pin advanced, three test comments asserting the OLD behavior are now
false, and the per-test `t.Setenv("XDG_CONFIG_HOME", t.TempDir())` they justified
is no longer needed (TestMain already sets XDG_CONFIG_HOME package-wide; the
per-test isolation existed ONLY to shield against the user-layer merge, which is
gone). Swept (#630):
- charly/layers_test.go
- charly/plugin_bootstrap_test.go
- charly/unified_test.go

`go mod tidy` also advances github.com/opencharly/spec to v0.2026262.957 (the
version the bumped sdk requires).

R10 (live, charly rebuilt against the bumped pin):
- check-preempt-live-pod: PASS (steps=22)
- full charly package: go test -count=1 . = ok (252.777s); go build ./... exit 0;
  go vet . exit 0; gofmt -l . empty

Assisted-by: opencode ollama-cloud/deepseek-v4.1-flash (fully tested and validated)
@github-actions

Copy link
Copy Markdown
Contributor

Review — PASS

Head SHA: 52a1ce8ba33167a05d4d65188b6af6d441138e0d (branch: fix/sdk-repin-config-stack-sweep)

Change class: charly core Go — dependency re-pin (go.mod/go.sum) + stale test-comment/t.Setenv sweep; diff matches the body file-for-file and line-for-line.
Security screen: PASS — no secrets/exfiltration, no guardrail weakening, no scope mismatch; the pin advances to a merged tag and the only code change is deletion of redundant test-isolation lines.
Checklist: All applicable rules PASS or NA (A1 body complete + correct Assisted-by footer; A2 bed gate matches the loader-affected class; A3 fully tested and validated supported by the live bed + package run; R1–R10 evidenced with pasted grep/bed/test output; ADE/SDD/R8 N/A; placement unchanged). Comment thread is empty.

Verdict: PASS


ollama-cloud/deepseek-v4.1-flash — action-review.

View action run

@github-actions
github-actions Bot enabled auto-merge (squash) September 22, 2026 21:28
@github-actions
github-actions Bot merged commit 6d8dd5c into main Sep 22, 2026
1 of 2 checks passed
charly-auto-merge Bot added a commit that referenced this pull request Sep 22, 2026
github-actions Bot pushed a commit to opencharly/plugin-deploy-vm that referenced this pull request Sep 23, 2026
… overlay fix (#21)

* fix: re-pin sdk so the in-plugin project load honors the config-stack overlay fix

Bump github.com/opencharly/sdk v0.2026253.1947 -> v0.2026265.2104 (and the spec
require it carries) so this plugin's OWN project self-load stops raw-merging the
per-host deploy overlay as a config-stack PROJECT layer.

WHY. This plugin is an out-of-process deploy:vm substrate: it self-loads the
project (loaderkit.LoadUnifiedViaExecutor, lifecycle.go) to resolve the VM entity
for PrepareVenue. Under the pin above, that load used the pre-fix config stack:
it raw-merged ~/.config/charly/charly.yml (a DeployConfig — per-host RUNTIME
state) as a project document layer. For a member-bearing bed that injects a
deploy-level member's TOP-LEVEL persisted copy next to the member its owner still
declares nested, and FoldMembers rejects it:

  peer name "preempt-vm-taker" (declared under deploy "check-preempt-vm-live")
  collides with an existing deploy/bed/peer entry

Observed live on check-preempt-vm-live (distro-fedora AND the relocated
plugin-preempt copy), failing at bring-up-members (steps=9). charly core and the
compiled-in plugins got this fix via opencharly/sdk#270 + the charly re-pin
(opencharly/charly#631); an OUT-OF-PROCESS plugin vendors its OWN loaderkit, so
each must re-pin in its own repo. This is that re-pin for plugin-deploy-vm.

R10 (live): check-preempt-vm-live re-run against a charly binary whose
CHARLY_REPO_OVERRIDE points this repo at the bumped tree:
- bring-up-members: FAIL (steps=9) before -> PASS after
- bed verdict: PASS (steps=20), 0 FAIL; the VM-venue arbiter assertions
  preemptor-vm-lease-recorded + preemptor-vm-stopped-the-holder both PASS,
  proving the pluginHolderStop/pluginHolderStart addr.Vm!="" dispatch live.
- go build ./... exit 0; go vet ./... exit 0; go test ./... ok

Assisted-by: opencode ollama-cloud/deepseek-v4.1-flash (fully tested and validated)

* docs: re-freeze the PR body against the final head

---------

Co-authored-by: Andreas Trawoeger <[email protected]>
@aitrawog
aitrawog deleted the fix/sdk-repin-config-stack-sweep branch September 25, 2026 19:06
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.

sweep the stale config-stack test comments in the sdk re-pin PR

1 participant