Skip to content

fix(plugin): the idle guard's daemon discovery resolves its roots through the ONE resolver - #1121

Merged
github-actions[bot] merged 2 commits into
mainfrom
feat/storeroot-core
Nov 11, 2026
Merged

github-actions[bot] merged 2 commits into
mainfrom
feat/storeroot-core

Conversation

@aitrawog

@aitrawog aitrawog commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Summary

charly core resolves its daemon roots through the org's ONE resolver, which now lives where core
is allowed to reach it.

charlyDaemonPids — the idle guard's discovery of charly-owned DETACHED daemons — composed
$XDG_CACHE_HOME/charly and $XDG_RUNTIME_DIR/charly by hand. Two consequences, both measured:

  • it ignored CHARLY_CACHE_DIR, so on a relocated install it could not see the buildkitd its own
    idle guard exists to follow, and would kill a running install as WEDGED (opencharly/charly#1119);
  • it duplicated the root computation that sdk/storekit owned, which core may not import.

It now asks spec/storeroot — the contract surface core is permitted to import — for the cache and
runtime roots, and nothing else changes: the scan of /proc, the argv match, the self-pid
exclusion, the seam, and the "a daemon is shared, so summing it is the correct trade" reasoning are
untouched.

TestImportPurity_HostImportsOnlySpecAndVettedThirdParty passes AS WRITTEN. No exception was
added, no residual-SDK row was declared, and charly/import_purity_test.go is byte-identical to
origin/main:

$ git diff --stat origin/main -- charly/import_purity_test.go
(empty)
$ sha256sum charly/import_purity_test.go
6d724c7b83962c10768c1040815abb2790dbd794f06fc81b5ebd956c62bb4864
$ git show origin/main:charly/import_purity_test.go | sha256sum
6d724c7b83962c10768c1040815abb2790dbd794f06fc81b5ebd956c62bb4864  -

The gate is also proved LIVE in both directions (§2), because a gate nobody can trip proves nothing.

One deliberate behaviour change, stated rather than discovered later. The runtime root now comes
from the resolver, so with no XDG_RUNTIME_DIR (a container, a cron job) it becomes the STATE root
— the resolver's documented fallback — where the hand-built code simply dropped the runtime root.
That can only WIDEN the daemon set the guard follows: a path that did not match before still does
not, and a daemon whose argv names the state root is now visible. It cannot cause a false kill (more
visible daemons means more evidence of progress, never less).

The pins move with the code, and one of them is not optional. Bumping spec to a tag carrying
spec/storeroot crosses a signature change: schemaparams.Generate lost its third parameter
between spec v0.2026313.453 and origin/main, and this repo's plugin-candy pin still called
the three-argument form — so a spec-only bump fails to BUILD, in a dependency:

$ # with spec bumped and plugin-candy left at v0.2026281.948
$ go build ./...
# github.com/opencharly/plugin-candy/candy/plugin-candy
…/[email protected]/params.go:176:40: too many arguments in call to paramsPipeline
	have (string, string, string)
	want (string, string)

plugin-candy v0.2026313.1445 already carries the two-argument call, so it is bumped here with
spec. sdk is NOT bumped by this PR: nothing in this diff imports it, and the plugins that do
adopt the re-export when their own pins advance.

Files in this diff:

file what it is
charly/plugin_activity.go charlyDaemonPids resolves the two roots through spec/storeroot
charly/plugin_activity_test.go the discovery's arms, incl. one that fails without the change
charly/plugin_served_provenance_test.go the comment naming where the cache root is resolved
charly/go.mod spec → v0.2026315.2118, plugin-candy → v0.2026313.1445
charly/go.sum the hashes those bumps add
tools/generate-packages/go.mod the shared spec pin, adopted
tools/generate-packages/go.sum its tidy
tools/golden-cloudinit/go.mod the shared spec pin, adopted
tools/golden-cloudinit/go.sum its tidy
tools/golden-compile/go.mod the shared spec pin, adopted
tools/golden-compile/go.sum its tidy

git diff --stat origin/main...HEAD:

 charly/go.mod                           |  4 ++--
 charly/go.sum                           |  6 +++++
 charly/plugin_activity.go               | 20 ++++++++++++-----
 charly/plugin_activity_test.go          | 39 ++++++++++++++++++++++++++++-----
 charly/plugin_served_provenance_test.go |  3 ++-
 tools/generate-packages/go.mod          |  2 +-
 tools/generate-packages/go.sum          |  4 ++--
 tools/golden-cloudinit/go.mod           |  2 +-
 tools/golden-cloudinit/go.sum           |  4 ++--
 tools/golden-compile/go.mod             |  2 +-
 tools/golden-compile/go.sum             |  4 ++--
 11 files changed, 67 insertions(+), 23 deletions(-)

This head is

944d640069e076a6acefd6ad9165cf24b0d8f8ff

How tested

Every command below was run against this head (944d640069e076a6acefd6ad9165cf24b0d8f8ff) and pasted from its capture file.

1. The gate, unedited, green — and provably able to fail

$ cd .worktrees/cache-root-resolver/charly/charly
$ go test ./ -run 'TestImportPurity_HostImportsOnlySpecAndVettedThirdParty|TestResidualSDKImports_DeclaredAndStillLive|TestNoAliasForms_ZeroPackageLevelReexports' -count=1 -v
=== RUN   TestImportPurity_HostImportsOnlySpecAndVettedThirdParty
--- PASS: TestImportPurity_HostImportsOnlySpecAndVettedThirdParty (0.01s)
=== RUN   TestResidualSDKImports_DeclaredAndStillLive
--- PASS: TestResidualSDKImports_DeclaredAndStillLive (0.00s)
=== RUN   TestNoAliasForms_ZeroPackageLevelReexports
--- PASS: TestNoAliasForms_ZeroPackageLevelReexports (0.02s)
PASS
ok  	github.com/opencharly/charly/charly	2.019s

The counterfactual is the whole point of this campaign, so it is measured rather than argued: with
the NAIVE fix in the same spot — import "github.com/opencharly/sdk/storekit" — the same gate
fails, with exactly the message the tracking issue pastes:

$ # the naive fix in the same spot: the import points at the sdk kit instead of spec
$ python3 - <<'PY'   # rewrite "github.com/opencharly/spec/storeroot" -> "github.com/opencharly/sdk/storekit"
$ go test ./ -run 'TestImportPurity_HostImportsOnlySpecAndVettedThirdParty' -count=1
--- FAIL: TestImportPurity_HostImportsOnlySpecAndVettedThirdParty (0.01s)
    import_purity_test.go:222: IMPORT-PURITY gate: 1 UNDECLARED github.com/opencharly/sdk import(s) in charly/ core — a residual call site must be declared in residualSDKImportSites with a named exit:
        plugin_activity.go:13: forbidden import "github.com/opencharly/sdk/storekit" — the sdk mechanism kits (and the sdk root plugin-authoring package) are for PLUGINS, never the host; charly/ core imports spec/* + proto only
--- FAIL: TestImportPurity_HostImportsOnlySpecAndVettedThirdParty (0.01s)
    import_purity_test.go:222: IMPORT-PURITY gate: 1 UNDECLARED github.com/opencharly/sdk import(s) in charly/ core — a residual call site must be declared in residualSDKImportSites with a named exit:
        plugin_activity.go:13: forbidden import "github.com/opencharly/sdk/storekit" — the sdk mechanism kits (and the sdk root plugin-authoring package) are for PLUGINS, never the host; charly/ core imports spec/* + proto only
    import_purity_test.go:241: IMPORT-PURITY debt (tracked, with named exits): 3 residual sdk import(s):
        plugin_build_testhelper_test.go:23: forbidden import "github.com/opencharly/sdk/buildcache" — the sdk mechanism kits (and the sdk root plugin-authoring package) are for PLUGINS, never the host; charly/ core imports spec/* + proto only
        plugin_dispatch_reverse.go:11: forbidden import "github.com/opencharly/sdk/buildcache" — the sdk mechanism kits (and the sdk root plugin-authoring package) are for PLUGINS, never the host; charly/ core imports spec/* + proto only
        plugin_loader.go:18: forbidden import "github.com/opencharly/sdk/buildcache" — the sdk mechanism kits (and the sdk root plugin-authoring package) are for PLUGINS, never the host; charly/ core imports spec/* + proto only
FAIL
$ cp <the saved original> plugin_activity.go && sha256sum plugin_activity.go
c6bf5d2b5fd69201e81bf8d3f6043bbde80a9ed0a627f2921b9ccf9818897edd   → source RESTORED BYTE-IDENTICAL

Both runs use the SAME gate file (hash above), so the difference is the import, not the rule.

2. The coverage fails without the change

TestCharlyDaemonPids_FollowsTheCacheDirOverride starts a real process whose argv names a path
under a CHARLY_CACHE_DIR-relocated root and requires the discovery to find it, with the other
candidate roots pinned to unrelated temp dirs. Against the PRE-change implementation (restored from
origin/main into the worktree, byte-identical restore verified by hash):

$ sha256sum plugin_activity.go            # this head's file
c6bf5d2b5fd69201e81bf8d3f6043bbde80a9ed0a627f2921b9ccf9818897edd
$ git show origin/main:charly/plugin_activity.go > plugin_activity.go     # the PRE-change implementation
$ go test ./ -run 'TestCharlyDaemonPids' -count=1 -v
=== RUN   TestCharlyDaemonPids_FindsProcessesUnderTheCharlyCacheRoot
--- PASS: TestCharlyDaemonPids_FindsProcessesUnderTheCharlyCacheRoot (0.00s)
=== RUN   TestCharlyDaemonPids_FollowsTheCacheDirOverride
    plugin_activity_test.go:644: charlyDaemonPids did not find a process whose argv names /home/atrawog/.cache/go-tmp/TestCharlyDaemonPids_FollowsTheCacheDirOverride559409788/001/relocated-store/watchdog-probe-daemon
--- FAIL: TestCharlyDaemonPids_FollowsTheCacheDirOverride (2.00s)
FAIL	github.com/opencharly/charly/charly	3.757s
$ cp <the saved original> plugin_activity.go && sha256sum plugin_activity.go
c6bf5d2b5fd69201e81bf8d3f6043bbde80a9ed0a627f2921b9ccf9818897edd   → RESTORED BYTE-IDENTICAL
$ go test ./ -run 'TestCharlyDaemonPids' -count=1
ok  	github.com/opencharly/charly/charly	16.215s

The pre-change arm is an assertion (charlyDaemonPids did not find a process whose argv names …),
not a build error, and the same test passes on this head.

3. The repo's own gate, on the committed tree

$ go build ./...; echo "build rc=$?"                      # the repo's own committed go.work, as CI resolves it
build rc=0
$ go vet ./...; echo "vet rc=$?"
vet rc=0
$ gofmt -l .                                            # (no output)
$ go test ./... -count=1                                # the repo's declared gate, on the COMMITTED tree
ok  	github.com/opencharly/charly/charly	279.827s
ok  	github.com/opencharly/charly/charly/internal/pluginsgen	121.317s
test rc=0
$ TMPDIR=/home/atrawog/.cache/charly-gate-lint/tmp GOTOOLCHAIN=go1.26.8 ~/go/bin/golangci-lint run ./...; echo "lint rc=$?"
0 issues.
lint rc=0

3b. Every in-repo module, not just the core one — and the task that keeps their pins shared

This repo is a MULTI-MODULE tree: charly/go.mod plus five tools/* modules, with ONE shared
spec/sdk pin across the modules that import the contract. tools/gomod-canonical's
TestContractPinsMatchShared guards that, and it was RED on the previous head because only the core
module was bumped. The repo's own control — charly task mods-tidy — is what aligns them, and it
reports its own two steps:

$ ./bin/charly task mods-tidy; echo "rc=$?"
task mods-tidy: 2 step(s), 0 failed, 0 skipped
  [pass] run — adopt the shared pins and tidy every lockstep module
      exit=0
  [pass] check — every lockstep module now carries the shared pins
      exit=0
rc=0
$ for d in tools/*/; do [ -f "$d/go.mod" ] || continue; printf "%-28s " "$d"; (cd "$d" && GOWORK=off go test ./... -count=1 >/dev/null 2>&1 && echo ok || echo FAIL); done
tools/generate-packages/     ok
tools/golden-cloudinit/      ok
tools/golden-compile/        ok
tools/gomod-canonical/       ok          <- the lockstep guard itself
tools/ledger-validate/       ok

4. The worktree-local binary (R9)

$ bash scripts/bootstrap-charly.sh
bootstrap-charly: regenerating compiled-in plugin wiring
bootstrap-charly: building bin/charly
check-generated-clean: NOTICE — charly/plugins_refs_generated.go differs because it was indexed from a source this checkout does not pin
check-generated-clean:   (a corpus plugin's default branch, or a --dev-plugin local checkout); restoring the tracked file.
bootstrap-charly: built ./bin/charly (2026.315.2131)      # rc=0
$ ./bin/charly version
2026.315.2131
$ git status --short                                    # (no output — the build left no derived drift)
$ timeout 180 ./bin/charly box list                    # a real plugin dispatch → the activity clock
charly: fetching git metadata for 183 repo(s) (first run — may take a moment)...
charly: git metadata cached (183 repo(s)).
plugin github.com/opencharly/plugin-example-kind/candy/plugin-example-kind: served from /home/atrawog/.cache/charly/plugin-build/views/plugin-example-kind-660763c18b405ea9 (build sha256:099881a3230929873b12066828fc6cff3b1a6c4a493e9bd0eb48ab9129816486); source /home/atrawog/.cache/charly/repos/github.com/opencharly/[email protected]/candy/plugin-example-kind
plugin github.com/opencharly/plugin-example-structkind/candy/plugin-example-structkind: served from /home/atrawog/.cache/charly/plugin-build/views/plugin-example-structkind-f39364ecc01e5411 (build sha256:86ea1981b89c4b773a6f04a3ae8b717a61bb76a7e170db4c95a5251436c01f56); source /home/atrawog/.cache/charly/repos/github.com/opencharly/[email protected]/candy/plugin-example-structkind
rc=0

charly box list is a real plugin dispatch — it exercises the plugin transport and the activity
clock that calls the changed function, on this host, with this binary. CHARLY_CACHE_DIR was NOT
set for it, so the default resolution is what ran.

5. Attribution evidence (A3)

The footer's harness, provider and full model name are each corroborated by an artifact the
authoring session wrote, not asserted:

$ dsh --version
0.2.1-rc.2

$ env | grep -E '^DSH_(PROFILE|SESSION_ID)='
DSH_PROFILE=web
DSH_SESSION_ID=85d64ba8-b11b-44ae-91dd-f6be77ffe8ee

$ grep -o '"\(provider\|model\)": "[^"]*"' \
    /home/atrawog/.dsh/storages/session_projcache/sessions/85d64ba8-b11b-44ae-91dd-f6be77ffe8ee.json \
    | sort | uniq -c
      1 "model": "deepseek-v4.1-flash"
      1 "provider": "ollama-cloud"

That is this session's own record — the same DSH_SESSION_ID named above — so the trailer's
DeepSeek Harness (dsh --version), ollama-cloud (provider) and deepseek-v4.1-flash (full
model name) are the runtime's exact names, cross-checked against the evidence rather than restated.

Rulebook compliance

  • R0 — skills first. /charly-internals:git-workflow, /charly-internals:go,
    /charly-internals:strict-policy and /charly-internals:go-quality loaded before the first tool
    action; charly/AGENTS.md read from origin/main before the first edit, along with spec's and
    sdk's (the two producer legs).

  • R1 — RCA every anomaly, then fix it or file it. Three fired. (a) The build failed in
    plugin-candy after the spec bump: RCA — schemaparams.Generate lost its third parameter and
    this repo's plugin-candy pin predates that; root fix — bump plugin-candy in the same commit
    (measured against the version that already carries the two-argument call), rather than pinning
    spec back. (b) plugin_activity.go kept a now-unused path/filepath import; root fix — drop
    it (the compiler caught it, which is the point of building before pushing). (c) A prose claim on
    this change's own sibling surface — plugin_served_provenance_test.go's comment named
    storekit.CacheDir as where the cache root is resolved — is now false for the host, so the
    comment names the resolver and its re-export; that is a claim-keyed fix on a file this change
    makes stale, not a drive-by.

  • R2 — no duplication. This change DELETES the hand-built pair; the two roots now come from the
    one resolver. The predicates that composed them are gone, calibrated in both directions:

    $ grep -n 'os\.UserCacheDir\|os\.Getenv("XDG_RUNTIME_DIR")\|filepath\.Join(cache, "charly")\|filepath\.Join(rt, "charly")' \
          charly/plugin_activity.go charly/plugin_activity_test.go
    (no output, rc=1)
    $ git grep -n 'os\.UserCacheDir' origin/main -- charly/plugin_activity.go charly/plugin_activity_test.go
    origin/main:charly/plugin_activity.go:780:	if cache, err := os.UserCacheDir(); err == nil {
    origin/main:charly/plugin_activity_test.go:617:	cache, err := os.UserCacheDir()
    

    Nothing is copied from spec/storeroot — it is imported.

  • R3 — no workarounds. No sleep, retry, magic number, suppression or shim. The runtime→state
    fallback is inherited from the resolver, not re-implemented here.

  • R4 — product before prose. The code is fixed first; the one comment touched describes the new
    behaviour, and the resolver is reached with the binary alone (no checkout, no extra tool).

  • R5 — hard cutover, legacy deleted. The hand-built expression is gone, not kept beside the new
    call — no dual path, no fallback to os.UserCacheDir, and the test's premise now comes from the
    same resolver instead of re-deriving the path. The identifier-keyed sweep, with the predicate
    calibrated against origin/main (where it MUST match, and does — the two hits quoted under R2),
    is empty on this tree. The one comment that named the sdk package as the resolver
    (plugin_served_provenance_test.go) is updated here, in the same commit.

  • R6 — preserve user work; Git safety. git status read before the first edit and after every
    step; the session worktree is feat/storeroot-core off fresh origin/main
    (e7336c6daa7033f9e18b64a7858b8dd1c3d0511a); no reset, no checkout of foreign work, no force-push, no hook bypass, no
    direct push to main.

  • R7 — prove behaviour, not compilation. §1 proves the gate in both directions; §2 proves the
    new coverage fails without the change (assertion, restored byte-identically); §3 runs the repo's
    full suite on the committed tree; §4 runs the changed path in a real binary.

  • R8 — live or skip, never fake. The daemon-discovery arms spawn REAL processes and read the
    real /proc — no mock, no fake root set in the arms that prove the change (the seam exists for
    the OTHER arms, which need isolation from a developer host's live daemons). No credential- or
    network-bound service is involved, so nothing is skipped or simulated.

  • R9 — binary equals source. §4 builds the worktree-local CalVer-stamped binary and prints
    charly version, which matches the commit's CalVer; the binary is the one that ran the dispatch.
    No new runtime OS dependency is added, so packaging: needs nothing.

  • R10 — fresh disposable proof. The gate that owns this change in THIS repo is go test ./...
    plus go vet ./... and the R9 build (§3, §4), all on the committed tree, zero warnings, lint
    clean under the CI toolchain. No disposable: true bed is claimed here: this change's runtime
    path is the idle guard's daemon discovery, which the arms in §2 exercise against real processes
    and /proc on this host, and the assembled-bed behaviour of the guard itself is unchanged by
    moving WHERE its two root strings come from.

Change classification

Core behaviour fix, API-neutral. No exported surface changes (charly core is a package main),
no command, flag or config key is added or removed, no wire shape moves. One behaviour changes, in
the direction the tracking issue asks for: daemon discovery follows CHARLY_CACHE_DIR, and the
runtime root inherits the resolver's documented state-root fallback when there is no
XDG_RUNTIME_DIR. spec moves to v0.2026315.2118 and plugin-candy to v0.2026313.1445 —
the second is forced by the first (a signature change in schemaparams.Generate), and neither
changes any authored document.

Breaking change + rollback: nothing breaks for a consumer of this repo. charly publishes a
binary, not a library; the binary's commands, flags and outputs are unchanged, and the two pins
move FORWARD (no consumer is asked to move anything). The one observable difference is that a
daemon under a relocated cache is now found instead of ignored — which is the fix. Rollback is one
inverse commit: reverting it restores the hand-built pair AND both pin lines, returning the module
graph to spec v0.2026313.453 / plugin-candy v0.2026281.948; there is no data migration, and the
roots resolve to the same directories either way.

Filed issues

Agent: cache-root-resolver
Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (fully tested and validated)

…ough the ONE resolver

charlyDaemonPids composed $XDG_CACHE_HOME/charly and $XDG_RUNTIME_DIR/charly by
hand, so it ignored CHARLY_CACHE_DIR — on a relocated install it could not see the
detached buildkitd its own idle guard exists to follow, and would kill a running
install as WEDGED (charly#1119). The two roots now come from spec/storeroot, the
contract surface core is permitted to import, so the import-purity gate passes AS
WRITTEN: charly/import_purity_test.go is byte-identical to origin/main, with no
exception and no residual-SDK row.

The runtime root inherits the resolver's documented fallback to the state root when
there is no XDG_RUNTIME_DIR, where the hand-built code dropped it entirely — that
can only widen the daemon set the guard follows, never narrow it.

Pins move with the code: spec to v0.2026315.2118 (which carries spec/storeroot) and plugin-candy to
v0.2026313.1445, forced because schemaparams.Generate lost its third
parameter and the older plugin-candy pin still called the three-argument form — a
spec-only bump fails to build in that dependency.

TestCharlyDaemonPids_FollowsTheCacheDirOverride is the arm that fails without the
change: against origin/main's implementation it reports that the discovery did not
find a process under the relocated root.

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

Copy link
Copy Markdown
Contributor

Review — BLOCK

Head SHA: 0c546cd90969412e7bb6b769ae0a339e99c22ff5 (branch: feat/storeroot-core)

Change class: code/config (core Go fix + dependency-pin bumps in charly/go.mod/go.sum).

No comments on the thread to disposition (0 comments).

Blocks

  1. A3 — attribution not corroborated by the pasted A3 evidence. The footer claims
    *Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (fully tested and validated)*,
    but §5 ("Attribution evidence (A3)") pastes only:
    $ dsh --version
    0.2.1-rc.2
    $ env | grep -E '^DSH_(PROFILE|SESSION_ID)='
    DSH_PROFILE=web
    DSH_SESSION_ID=85d64ba8-b11b-44ae-91dd-f6be77ffe8ee
    
    That corroborates the harness (dsh = DeepSeek Harness) and gives a session id, but it
    contains no provider and no full-model identity. A3 requires the harness, provider, and
    full model name to be cross-checked against the authoring runtime evidence in the body. The
    footer's ollama-cloud/deepseek-v4.1-flash therefore cannot be cross-checked — it is asserted,
    not proven. Paste the actual model identity the session ran (e.g. the harness's model/status
    output for DSH_SESSION_ID=85d64ba8-…) so the provider+model can be corroborated, or correct the
    footer to the model actually evidenced. (The fully tested and validated tier itself is fine —
    §2 runs the changed charlyDaemonPids against real processes//proc and §4 runs the freshly
    built binary — the gap is the model/provider attribution, not the tier.)

Verdict: BLOCK


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

View action run

@aitrawog

Copy link
Copy Markdown
Contributor Author

Round 1 RCA — A3 attribution evidence; body-only, the diff did not move.

The finding. The footer names DeepSeek Harness ollama-cloud/deepseek-v4.1-flash, and my §5
fence corroborated only the HARNESS (dsh --version) plus the session id. The provider and the full
model name were asserted by the trailer and evidenced nowhere, so nothing in the body could
cross-check them.

Missed control — and it is a copied-and-not-re-derived control. The fence I pasted is the one I
had seen in a recently merged PR in this org (opencharly/spec#302), where it was accepted; I treated
that as the shape A3 wants rather than reading A3's own test ("the attribution tier is justified by
the pasted proof, and the harness and model names match the runtime"). A copied control is not a
verified control: the earlier PR passed on the validator's reading of ITS body, not on the shape
being sufficient for every future body in every repo. The control that would have caught it is
mechanical and cheap: before pushing, for EACH of the three names the footer carries — harness,
provider, model — point at one pasted line that contains it. Harness was there; provider and model
were not, and a three-name checklist would have said so in one pass.

Fix. §5 now pastes the authoring session's OWN record, from the file named by the same
DSH_SESSION_ID the fence already carried:

$ grep -o '"\(provider\|model\)": "[^"]*"' \
    /home/atrawog/.dsh/storages/session_projcache/sessions/85d64ba8-b11b-44ae-91dd-f6be77ffe8ee.json | sort | uniq -c
      1 "model": "deepseek-v4.1-flash"
      1 "provider": "ollama-cloud"

So the trailer's three names are each corroborated by evidence rather than restated. The tier is
unchanged and the block already accepted it: §2 runs the changed charlyDaemonPids against real
processes and /proc, and §4 runs freshly built binary. No code, no go.mod, no test moved: the
head stays 0c546cd90969412e7bb6b769ae0a339e99c22ff5, and the corrected body is re-read on the same
SHA by a REST re-run of the failed run.

I am also carrying this forward: the two umbrella legs still to come (the DESIGN.md record and any
pin leg) will use the three-name fence, not the two-line one.

Agent: cache-root-resolver

Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)

@github-actions

Copy link
Copy Markdown
Contributor

Review — PASS

Head SHA: 0c546cd90969412e7bb6b769ae0a339e99c22ff5 (branch: feat/storeroot-core)

Security screen: PASS
Checklist: All applicable rules PASS or NA.

Comment dispositions:

  • Comment 6807699076 (@github-actions[bot]) — stale-superseded: the A3 finding (provider/model uncorroborated) does not reproduce against the CURRENT body, whose §5 now pastes the session record showing "provider": "ollama-cloud" and "model": "deepseek-v4.1-flash" keyed to the same DSH_SESSION_ID. Harness (dsh --version), provider and model are each now corroborated.
  • Comment 6807802989 (@aitrawog) — verified: Round-1 RCA names the missed control ("a copied control is not a verified control" + a three-name checklist), and the claimed §5 fix is present in the current body; no code/pin moved, consistent with the unchanged head SHA.

Non-blocking notes:

  • No disposable: true bed is claimed; the body argues the changed path is proven by the in-process integration test (§2, real spawned processes + real /proc, fails without the change) plus a fresh binary dispatch (§4). I cannot re-run these, but the pasted output is internally consistent (real t.TempDir path, byte-identical restore hashes, go test/vet/gofmt/lint all clean) and the change is a narrow root-computation fix, not a runner/deploy change. Accepted as adequate; flag only as a rulebook-clarity gap in the R10 change-class matrix for core path-fixes.
  • The body's Agent: footer is not in the italicized *Agent: … ses_…* form, but the identity footer is coordination metadata and never a finding.

Verdict: PASS


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

View action run

@aitrawog

Copy link
Copy Markdown
Contributor Author

CI RCA — go: FAILURE on 0c546cd9, fixed here; the verdict itself was PASS and the red sibling is
what blocked arming.

The failure. tools/gomod-canonical's TestContractPinsMatchShared:

--- FAIL: TestContractPinsMatchShared (0.00s)
    gomod_canonical_test.go:128: ../../tools/generate-packages/go.mod: requires spec v0.2026313.453, but the shared spec pin is v0.2026315.2118 — run `charly task mods-tidy`
    gomod_canonical_test.go:128: ../../tools/golden-cloudinit/go.mod: requires spec v0.2026313.453, but the shared spec pin is v0.2026315.2118 — run `charly task mods-tidy`
    gomod_canonical_test.go:128: ../../tools/golden-compile/go.mod: requires spec v0.2026313.453, but the shared spec pin is v0.2026315.2118 — run `charly task mods-tidy`
FAIL	github.com/opencharly/charly/tools/gomod-canonical

Mechanism. This repo is a MULTI-MODULE tree: charly/go.mod plus five tools/* modules, and the
spec/sdk pins are a shared invariant across them because the tool modules import the same
contract. I bumped the core module and left the three tool modules that carry a spec require at the
old tag.

Missed control — and it is a scope error in what I called "the gate". I ran
go test ./... from charly/, saw two packages pass, and treated that as the repo's declared gate.
It is the gate for ONE module. The repo's own control for exactly this defect is a task verb with a
check: step — charly task mods-tidy — which exists because the pins are shared, and whose
description says so ("Adopt the shared sdk/spec pins in every in-repo module that carries them, then
tidy"). I read the charly.yml task surface for other reasons and did not run this one; the
mechanical fix is that a go.mod change in this repo runs charly task mods-tidy BEFORE the module
test sweep, and the sweep is per-module (every */go.mod), not ./... from one directory.

Root fix, applied. charly task mods-tidy → rc=0, its own steps [pass] run, [pass] check; it
aligned and tidied three modules and the diff is tools/{generate-packages,golden-cloudinit,golden-compile}/{go.mod,go.sum}. Then every in-repo module, tested individually:

tools/gomod-canonical/       ok     <- the lockstep guard itself
tools/generate-packages/     ok
tools/golden-cloudinit/      ok
tools/golden-compile/        ok
tools/ledger-validate/       ok

Why the PR is not armed despite validate / validate: SUCCESS. The validator PASSED the diff;
the go sibling check was red, so the arming step was skipped — the documented mechanism (a red
sibling makes the validator's own head-check step fail and validate / arm never arms). Nothing
about the verdict was wrong; the tree was.

Agent: cache-root-resolver

Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)

The core module's spec pin moved to v0.2026315.2118 (spec/storeroot), and this repo keeps
ONE spec/sdk pin across charly/go.mod and the tools/* modules that import the contract. `tools/gomod-canonical`'s TestContractPinsMatchShared fails until they
agree, which is why CI's `go` job was red on the previous head while the validator
itself passed.

`charly task mods-tidy` aligned and tidied the three modules that carry a spec
require (generate-packages, golden-cloudinit, golden-compile); its own check step
passes, and every in-repo module's tests pass individually afterwards.

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

Copy link
Copy Markdown
Contributor

Review — BLOCK

Head SHA: 944d640069e076a6acefd6ad9165cf24b0d8f8ff (branch: feat/storeroot-core)
Change class: code/config (core Go fix + dependency-pin bumps across the core and three tools/* modules).
Security screen: PASS — no secrets/exfiltration, no weakened guardrail, no injected instruction; the diff does exactly what the description says (hand-built root pair → spec/storeroot, plus the forced plugin-candy/spec pin moves and their tools/* lockstep adoption).
Placement: placement: CORRECT — core consumes the contract-surface resolver (spec/storeroot), no capability moved into core, no new sdk-kit import, no alias-file growth, net removal of the duplicated root composition.

Blocks

  1. A1 / R1 — the body's pasted git diff --stat does not describe the head it is presented for. Under the Summary the body prints
    git diff --stat origin/main...HEAD → 5 files changed, 58 insertions(+), 14 deletions(-),
    immediately followed by "This head is 944d640…". The CURRENT diff for that head has 11 files: the stat omits the six tools/{generate-packages,golden-cloudinit,golden-compile}/{go.mod,go.sum} files that commit 944d640 adds and that the body's own file table and §3b ("adopt the shared spec pin …") describe. The body therefore contradicts itself and pastes evidence from the previous commit. Re-paste the stat for 944d640… (or delete the stale block) so the pasted evidence matches the head; everything else in the body is consistent.

Comment dispositions

  • 6807699076 (@github-actions[bot], BLOCK, A3) — stale-superseded: §5 now pastes the session record ("provider": "ollama-cloud", "model": "deepseek-v4.1-flash") keyed to the same DSH_SESSION_ID, so harness+provider+model are each corroborated. Finding does not reproduce.
  • 6807802989 (@aitrawog, Round-1 RCA) — verified-non-blocking: the claimed §5 fix is present; the RCA names the missed control (three-name checklist; "a copied control is not a verified control").
  • 6807884840 (@github-actions[bot], PASS at 0c546cd) — stale-superseded: it reviews a prior head; not authoritative for this one.
  • 6808087265 (@aitrawog, CI RCA) — verified-non-blocking: the three tools/* modules it says were left at the old spec tag are now bumped in the CURRENT diff, and the RCA names the missed control (scope error: go test ./... from charly/ is one module's gate; the repo control is charly task mods-tidy).

Accepted, non-blocking

  • R10 / A2: no disposable: true bed is claimed, but the changed function's new branch is proven by TestCharlyDaemonPids_FollowsTheCacheDirOverride against real spawned processes/real /proc (fails without the change, restored byte-identically) plus a fresh bin/charly dispatch in §4; this is an in-process root-resolution fix, not a runner/deploy change, so the absence of a bed is acceptable — a rulebook-clarity gap for core path-fixes, not a defect here.
  • A3 tier: fully tested and validated is not inflated — the changed call path executed live (real processes in §2, fresh binary in §4).
  • The Agent: line is not in the italicized ses_… form; coordination metadata, never a finding.

Verdict: BLOCK


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

View action run

@aitrawog

Copy link
Copy Markdown
Contributor Author

Round 2 RCA — the pasted git diff --stat described the PREVIOUS head; body-only, code untouched.

The finding. After the pin-alignment commit (944d640) the body still pasted a
5 files changed, 58 insertions(+), 14 deletions(-) stat while its own file table listed eleven files
and §3b described the three tools/* modules that commit added. Two claims in one body disagreed.

Missed control — the body is a DERIVED artefact and I edited it with a regex that silently matched
the wrong span.
I updated the body for the new head with a scripted substitution keyed on the
literal 4 files changed — but the pasted block said 5 files changed, so that substitution matched
nothing and the stale fence survived; I then verified only that the FILE TABLE had eleven rows and
never re-read the STAT fence, which is the one artefact whose content changed with the commit. Worse,
the follow-up repair regex matched from an earlier fence to the stale stat fence and would have
deleted a section of the body — caught only because the replaced span was printed.

The control, and it is mechanical: every commit that changes the tree invalidates the body's
pasted numbers, so after re-finalising a body the stat fence is RE-DERIVED from
git diff --stat origin/main...HEAD on the head being pushed and the pasted text is compared to the
command's output character for character
— never asserted from an earlier edit. The rulebook says
this in one line ("EVERY CONTENT COMMIT INVALIDATES A MEASURED BODY"); what I lacked was the
per-fence check, so a body could carry a table for eleven files beside a stat for five.

Fix. The stat fence is replaced by the command's own output for 944d640:

 charly/go.mod                           |  4 ++--
 charly/go.sum                           |  6 +++++
 charly/plugin_activity.go               | 20 ++++++++++++-----
 charly/plugin_activity_test.go          | 39 ++++++++++++++++++++++++++++-----
 charly/plugin_served_provenance_test.go |  3 ++-
 tools/generate-packages/go.mod          |  2 +-
 tools/generate-packages/go.sum          |  4 ++--
 tools/golden-cloudinit/go.mod           |  2 +-
 tools/golden-cloudinit/go.sum           |  4 ++--
 tools/golden-compile/go.mod             |  2 +-
 tools/golden-compile/go.sum             |  4 ++--
 11 files changed, 67 insertions(+), 23 deletions(-)

Cross-checked against the body's file table: the same eleven paths, the same counts. No code, no
go.mod, no test moved — the head stays 944d640069e076a6acefd6ad9165cf24b0d8f8ff, and the
corrected body is re-read on that SHA by a REST re-run of the failed run.

Agent: cache-root-resolver

Assisted-by: DeepSeek Harness ollama-cloud/deepseek-v4.1-flash (analysed on a live system)

@github-actions

Copy link
Copy Markdown
Contributor

Review — PASS

Head SHA: 944d640069e076a6acefd6ad9165cf24b0d8f8ff (branch: feat/storeroot-core)

Security screen: PASS — hand-built root pair replaced by spec/storeroot; no secrets, no exfiltration, no weakened guardrail, no injected directive; the diff does exactly what the summary says (plus the documented, forced pin moves).
Checklist: All applicable rules PASS or NA. Placement CORRECT — core consumes the contract-surface resolver, no capability moved inward, no sdk-kit import, no alias growth, net deletion of the duplicated root composition.

Comment dispositions:

  • 6807699076 (@github-actions[bot], BLOCK A3) — stale-superseded: current §5 pastes the session record ("provider": "ollama-cloud", "model": "deepseek-v4.1-flash") keyed to the same DSH_SESSION_ID, so harness+provider+model are each corroborated. Does not reproduce.
  • 6807802989 (@aitrawog, Round-1 RCA) — verified-non-blocking: §5 fix present; RCA names the missed control ("a copied control is not a verified control" + three-name checklist).
  • 6807884840 (@github-actions[bot], PASS at 0c546cd) — stale-superseded: reviews a prior head; not authoritative.
  • 6808087265 (@aitrawog, CI RCA) — verified-non-blocking: the three tools/* modules are bumped in the CURRENT diff; RCA names the missed control (scope error: go test ./... from charly/ is one module's gate; the repo control is charly task mods-tidy).
  • 6808188812 (@github-actions[bot], BLOCK stale stat at 944d640) — stale-superseded: the CURRENT body's git diff --stat reads 11 files changed, 67 insertions(+), 23 deletions(-), which I re-derived against the diff (67/23, 11 files) and it matches. Does not reproduce.
  • 6808324344 (@aitrawog, Round-2 RCA) — verified-non-blocking: stat fence replaced with the command output; RCA names the missed control (per-fence re-derivation).

Non-blocking notes: No disposable: true bed is claimed, but the changed path executes live (real spawned processes + real /proc in §2, fresh bin/charly dispatch in §4) and the new test fails without the change — accepted; a rulebook-clarity gap for core path-fixes, not a defect. The Agent: line is not in the italicized ses_… form — coordination metadata, never a finding.

Verdict: PASS


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

View action run

@github-actions
github-actions Bot enabled auto-merge (squash) November 11, 2026 22:18
@github-actions
github-actions Bot merged commit a860393 into main Nov 11, 2026
7 of 8 checks passed
charly-auto-merge Bot added a commit that referenced this pull request Nov 11, 2026
aitrawog pushed a commit that referenced this pull request Nov 13, 2026
173 commits behind; both touched files conflicted. main rewrote the guard's progress
source — cpu() -> work()/procWork, watchedRoots, excludeRoot and the charly-owned detached
daemon trees (#984, #997, #1004, #1088/#1102, #1121) — while this branch adds the
attempted-touch source (#913). Resolved by re-basing the attempt source onto main's
structure BY HAND rather than merging text:

  - pluginActivity.touches, incremented in touch() before the non-blocking send;
  - touchAttempts(), the accessor the confirmation reads;
  - observe(wake, last procWork, lastAttempts) reports progress when ANY of the three
    sources moved: a drained host-leg event, a tree-work advance, or a grown attempt count;
  - the lastAttempts baseline is carried through BOTH call sites (the work poll and the
    expiry confirmation) and refreshed by the wake case;
  - stallReport names the third source and carries the attempt count at the kill boundary;
  - the four tests re-added on main's test file (deterministic progressing arm, the
    attempt-vs-delivery property, the unit-level third source, and the confirmation arm),
    with main's #1088 daemon/descendant tests kept intact and their observe calls updated.

Verified on THIS tree: gofmt clean; go build ./... and go vet ./... rc=0; the focused
guard tests 15/15 PASS; the full module suite go test ./... -> ok 414.387s and
ok internal/pluginsgen 142.184s, rc=0, zero failures.

*Agent: pr-charly*

*Assisted-by: DeepSeek Harness deepseek-v4.1-flash (analysed on a live system)*
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