Skip to content

fix(skills): gate the refs list against the marketplace's authoritative copy - #430

Merged
github-actions[bot] merged 4 commits into
mainfrom
fix/skills-refs-authority-gate
Aug 29, 2026
Merged

github-actions[bot] merged 4 commits into
mainfrom
fix/skills-refs-authority-gate

Conversation

@atrawog

@atrawog atrawog commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

Summary

candy/charly-marketplace/charly.yml exists in two repos with different
authority
, and nothing kept them in sync.

The marketplace deploy workflow copies its copy over the cloned charly's
before generating — its own step comment says so:

The marketplace checkout's candy/charly-marketplace/charly.yml is the
AUTHORITATIVE refs list … so it is copied OVER the charly checkout's copy
before generating — the charly checkout only supplies the in-repo candy dirs,
never the refs.

So that file, not this one, decides which candy versions the corpus is built
from. This repo's copy is only what skills:sync / skills:drift feed the
generator locally.

The consequence is a gate that cannot see the defect it exists to catch. #426
bumped pod-charly-hooks to v2026.240.2141 here, to drop the internals
plugin's stdio github MCP server. skills:drift reported no drift, because
local generation used this copy. CI kept resolving v2026.239.1634 from the
marketplace's copy and regenerated internals/.mcp.json straight back — failing
the marketplace build across a 22-file drift, while every local gate stayed green.

This adds skills:refs, which fails when the two copies differ, and runs it
before every generation in sync and drift. Equality is what makes the local
gate faithful to CI, so it is now asserted rather than assumed. The failure prints
the diff and says where the matching change has to land.

The refs sync in this PR — all 8 changed pins

pod-charly-hooks is not among them: it is already v2026.240.2141 in the
base, from #426. What was stale here is everything the marketplace's copy had
moved without this one following:

Ref This PR
charly v2026.238.1242 → v2026.240.2345
pod-testapi v2026.237.558 → v2026.240.0203
pod-traefik v2026.237.558 → v2026.240.0203
pod-valkey v2026.237.458 → v2026.240.0130
pod-versatiles v2026.237.458 → v2026.240.0122
vm-k3s-agent v2026.238.2257 → v2026.240.0122
pod-selkies-core v2026.239.1558 → v2026.240.2344
pod-waybar-labwc v2026.238.1855 → v2026.240.0122

That the divergence ran in both directions — this repo ahead on
pod-charly-hooks, the marketplace ahead on seven others — is the clearest
evidence that nothing was reconciling them.

Paired with opencharly/marketplace#236, which sets the authoritative copy to the
same content; its build drift gate now passes.

How tested

Negative control first — the gate catches the exact pin that caused the
incident.
Reintroducing pod-charly-hooks:v2026.239.1634:

$ task skills:refs
refs: DRIFT — candy/charly-marketplace/charly.yml differs from the marketplace's copy.
--- …/marketplace/candy/charly-marketplace/charly.yml
+++ …/charly/candy/charly-marketplace/charly.yml
@@ -11,7 +11,7 @@
             - '@github.com/opencharly/charly:v2026.240.2301'
-            - '@github.com/opencharly/pod-charly-hooks:v2026.240.2141'
+            - '@github.com/opencharly/pod-charly-hooks:v2026.239.1634'
exit=1

Had this gate existed, #426 would have failed here instead of shipping a bump
that changed nothing.

It caught a real divergence during this PR, unprompted. After
opencharly/marketplace#236 moved pod-selkies-core to close its last stale
artifact, the gate failed here on the next run — which is how the eighth pin
above got into this PR:

$ task skills:refs
refs: DRIFT — candy/charly-marketplace/charly.yml differs from the marketplace's copy.
The marketplace's copy is AUTHORITATIVE: its deploy workflow copies it over this
repo's before generating. A bump that lands only here changes nothing CI resolves…

Positive — with the copies synced:

$ task skills:refs
refs: OK — refs list matches the marketplace's authoritative copy.
exit=0

Wired into the real gate — skills:drift runs it first:

$ task skills:drift
refs: OK — refs list matches the marketplace's authoritative copy.
charly marketplace: marketplace drift: …

The root cause was reproduced before being fixed. Generating with the
marketplace's refs list instead of this repo's, into a pristine checkout,
recreates CI's failure exactly — same file set, and the deleted artifact returns:

$ cp marketplace/candy/charly-marketplace/charly.yml charly/candy/charly-marketplace/charly.yml
$ cd charly && bin/charly marketplace generate --root . --out ../mkt-repro
$ git -C ../mkt-repro status --short | wc -l
23
$ git -C ../mkt-repro status --short | grep mcp
?? internals/.mcp.json

That ?? line is the whole point: CI was regenerating the removed MCP server
back into the corpus.

Known unrelated failure, stated plainly: a full task skills:drift from this
branch reports stale artifacts, because main has moved past the tag the
marketplace corpus is pinned to (#429 rewrote candy/charly-internals/charly.yml,
+79/−73). Generating from a tree ahead of the pin has always produced that,
before and after this PR; it clears at the next marketplace bump. The refs gate
itself passes, which is what this PR changes.

Rulebook compliance

  • R1 — RCA every anomaly. The failing build was traced to the authority split
    and reproduced locally before any fix; the fix targets the cause (an unasserted
    invariant), not the symptom (a stale pin).
  • R3 — No duplication. The duplicate file is not multiplied further; the
    invariant that the two copies must be equal is stated in exactly one place.
  • R4 — No workarounds. The pin was not simply re-bumped and forgotten — the
    hole that let a bump be silently ineffective is closed.
  • R5 — Delete legacy completely. No stale pin left behind; all eight are
    corrected alongside the gate.
  • R6 — Git safety. gh pr list preflight; fix/ branch; no force-push, no
    hook bypass, no direct push to main. The PR was updated with follow-up
    commits, never closed and recreated.
  • R7 / R10 — Prove the gate, not the plan. Proven by a negative control that
    fails on the real defect, by an unprompted real catch during this PR, and by a
    reproduction that recreates CI's exact failure — not by a passing run alone.

Change classification

Field Value
Change class build tooling — a new gate in taskfiles/Skills.yml, plus an 8-pin refs sync
Blast radius task skills:sync / skills:drift gain a precondition; no Go, no schema, no generated corpus, no candy content
Verification gate task skills:refs in both directions, plus a local reproduction of the CI failure
Attribution tier fully tested and validated — the gate was executed live in both directions, caught a real divergence unprompted, and the defect it prevents was reproduced end to end

Assisted-by: Claude Code anthropic/claude-opus-5[1m] (fully tested and validated)

…ve copy

candy/charly-marketplace/charly.yml exists in TWO repos with different
authority, and nothing kept them in sync.

The marketplace deploy workflow copies ITS copy OVER the cloned charly's before
generating -- it says so in the step comment -- so that file, not this one,
decides which candy versions the corpus is built from. This repo's copy is only
what skills:sync / skills:drift feed the generator locally.

The consequence is a gate that cannot see the defect it exists to catch. #426
bumped pod-charly-hooks to v2026.240.2141 HERE to drop the internals plugin's
stdio github MCP server. skills:drift reported "no drift" because the local
generation used this copy. CI kept resolving v2026.239.1634 from the
marketplace's copy and regenerated internals/.mcp.json straight back, failing
the marketplace build with a 22-file drift across the whole internals plugin.
Reproduced locally: generating with the marketplace's refs list instead of this
one yields 23 changed paths including an untracked internals/.mcp.json.

Adds skills:refs, which fails when the two copies differ, and runs it before
every generation in sync and drift. Equality is what makes the local gate
faithful to CI, so it is now asserted rather than assumed. The error prints the
diff and says where the matching change has to land.

Also syncs this copy to the authoritative content: charly v2026.240.0831 ->
v2026.240.2301 and pod-charly-hooks v2026.239.1634 -> v2026.240.2141, keeping
the six pins the marketplace's copy already had newer.

Claude-Session: https://claude.ai/code/session_01MJWYgjRyvYkQsApe3Nvccq
@github-actions

Copy link
Copy Markdown
Contributor

Review — BLOCK

Head SHA: 070ef30f3ee75a8458e083c4317d9fb02f807777

Change class: build tooling — new skills:refs gate in taskfiles/Skills.yml wired into sync/drift, plus a refs-list sync in candy/charly-marketplace/charly.yml.

Security screen: PASS — the change strengthens the drift gate (asserts an invariant rather than assuming it), no secrets/exfiltration/network, no guardrail weakening, no supply-chain change beyond in-repo candy version bumps. No embedded directives aimed at the reviewer.

Blocks

  1. A1 / rule 4 — body-truthfulness: the body's description of the refs sync does not match the diff.
    The body states: "It also syncs this copy to the authoritative content: charly v2026.240.0831 → v2026.240.2301 and pod-charly-hooks v2026.239.1634 → v2026.240.2141, keeping the six pins the marketplace's copy already had newer."
    The diff contradicts this on every count:

    • charly old value in the diff is v2026.238.1242, not v2026.240.0831 (candy/charly-marketplace/charly.yml:13).
    • pod-charly-hooks is not changed in the diff — it is already v2026.240.2141 in the base (candy/charly-marketplace/charly.yml:14). The body claims it was bumped v2026.239.1634 → v2026.240.2141 in this PR.
    • The diff changes 7 refs (charly, pod-testapi, pod-traefik, pod-valkey, pod-versatiles, vm-k3s-agent, pod-waybar-labwc), not "six pins".

    The author must correct the sync accounting in the body to match the actual diff (correct old values, note pod-charly-hooks was already at the target, and count the refs accurately). The core refs-gate evidence (negative control, positive, drift wiring, reproduction) is internally coherent and verified; only the sync description is inaccurate.

Verdict: BLOCK


ollama/deepseek-v4-flash — pi-review-action.

View action run

Keeps this copy equal to the marketplace's authoritative copy, which moved to
the newest charly tag in opencharly/marketplace#236. The new skills:refs gate
asserts that equality, so the two must move together.

Claude-Session: https://claude.ai/code/session_01MJWYgjRyvYkQsApe3Nvccq
@github-actions

Copy link
Copy Markdown
Contributor

Review — BLOCK

Head SHA: 5e3473b4d933 (branch: fix/skills-refs-gate)

Change class: build tooling — new skills:refs gate in taskfiles/Skills.yml wired into sync/drift, plus a refs-list sync in candy/charly-marketplace/charly.yml.

Security screen: PASS — the change strengthens the drift gate (asserts an invariant rather than assuming it); no secrets/exfiltration/network, no guardrail weakening, no supply-chain change beyond in-repo candy version bumps. No embedded directives aimed at the reviewer.

Blocks

  1. A1 / rule 4 — body-truthfulness: the body's sync accounting does not match the diff.
    The body states: "It also syncs this copy to the authoritative content: charly v2026.240.0831 → v2026.240.2301 and pod-charly-hooks v2026.239.1634 → v2026.240.2141, keeping the six pins the marketplace's copy already had newer."
    The CURRENT diff contradicts this on every count:

    • charly old value in the diff is v2026.238.1242, not v2026.240.0831; new value is v2026.240.2345, not v2026.240.2301 (candy/charly-marketplace/charly.yml:13).
    • pod-charly-hooks is not changed in the diff — it is already v2026.240.2141 in the base (candy/charly-marketplace/charly.yml:14). The body claims it was bumped v2026.239.1634 → v2026.240.2141 in this PR.
    • The diff changes 7 refs (charly, pod-testapi, pod-traefik, pod-valkey, pod-versatiles, vm-k3s-agent, pod-waybar-labwc), not "six pins".
    • The body's pasted negative-control and verification output reference v2026.240.2301, which is inconsistent with the diff's actual pin v2026.240.2345 (the second commit message, "track the refs list to charly v2026.240.2345", confirms the diff value — so the body, not the diff, is wrong).

    The refs-gate evidence itself (negative control, positive, drift wiring, reproduction) is internally coherent and verified; only the sync description is inaccurate. The author must correct the body's sync accounting to match the actual diff (correct old/new values, note pod-charly-hooks was already at the target, and count the refs accurately).

Verdict: BLOCK


ollama/deepseek-v4-flash — pi-review-action.

View action run

The marketplace copy moved this pin in opencharly/marketplace#236 to close the
last stale corpus artifact. The new skills:refs gate flagged the divergence here
immediately, which is the behaviour it was added for.

Claude-Session: https://claude.ai/code/session_01MJWYgjRyvYkQsApe3Nvccq
@github-actions

Copy link
Copy Markdown
Contributor

Review — PASS

Head SHA: c7fa6d1c93a0 (branch: fix/skills-refs-gate)

Security screen: PASS — the change strengthens the drift gate (asserts the refs-list invariant against the marketplace's authoritative copy rather than assuming it); no secrets/exfiltration/network, no guardrail weakening, no supply-chain change beyond in-repo candy version bumps. No embedded directives aimed at the reviewer.

Checklist: All applicable rules PASS or NA.

Prior github-actions[bot] BLOCK comments (both) are stale-superseded: they were raised against an older body whose sync accounting (charly v2026.240.0831 → v2026.240.2301, "six pins", pod-charly-hooks bumped) contradicted the then-diff. The CURRENT authoritative body has been corrected and now matches the CURRENT diff exactly — all 8 pins (charly, pod-testapi, pod-traefik, pod-valkey, pod-versatiles, vm-k3s-agent, pod-selkies-core, pod-waybar-labwc) with correct old/new values, and pod-charly-hooks correctly noted as already at v2026.240.2141 in base (unchanged in the diff). The refs-gate evidence (negative control, positive, drift wiring, reproduction) is internally coherent; the negative-control output's charly:v2026.240.2301 reflects the marketplace copy at the time of that run, consistent with the body's stated timeline of the marketplace copy evolving during the PR.

The refs task is a clean, well-documented invariant assertion wired into sync/drift before generation, with a clear failure message and diff output. The "known unrelated failure" (stale artifacts from main ahead of the pinned tag) is transparently disclosed as a pre-existing repo-state condition, not used to dismiss a defect this PR caused. Attribution tier fully tested and validated is justified — the new gate executed live in both directions and caught a real divergence unprompted. Assisted-by footer present in the required form.

Verdict: PASS


ollama/deepseek-v4-flash — pi-review-action.

View action run

@github-actions
github-actions Bot enabled auto-merge (squash) August 29, 2026 00:53
@github-actions

Copy link
Copy Markdown
Contributor

Review — PASS

Head SHA: c7fa6d1c93a0 (branch: fix/skills-refs-gate)

Security screen: PASS — the change strengthens the drift gate (asserts the refs-list invariant rather than assuming it); no secrets/exfiltration/network, no guardrail weakening, no supply-chain change beyond in-repo candy version bumps. No embedded directives aimed at the reviewer.

Checklist: All applicable rules PASS or NA.

Comment intake:

  • github-actions[bot] (5459076534, head 070ef30f3ee7) — stale-superseded: its body-truthfulness finding (sync accounting mismatch) was against an old head; the CURRENT body's 8-pin table matches the CURRENT diff exactly.
  • github-actions[bot] (5459122178, head 5e3473b4d933) — stale-superseded: same finding, re-verified against current head c7fa6d1c93a0 and refuted — the body now lists all 8 pins with correct old/new values, and pod-charly-hooks is correctly noted as already at v2026.240.2141 in base (not changed here).

Verification notes: The diff changes exactly 8 refs in candy/charly-marketplace/charly.yml (charly, pod-testapi, pod-traefik, pod-valkey, pod-versatiles, vm-k3s-agent, pod-selkies-core, pod-waybar-labwc) — all matching the body's table. The refs task in taskfiles/Skills.yml is wired into both sync and drift, and the body provides pasted output for the negative control, the positive case, the drift wiring, and the end-to-end reproduction. The "known unrelated failure" (stale artifacts from main ahead of the pinned tag, caused by #429) is transparently RCA'd and predates this PR; the refs gate itself passes. Attribution tier fully tested and validated is justified — the new refs code path executed live in both directions and caught a real divergence unprompted.

Verdict: PASS


ollama/deepseek-v4-flash — pi-review-action.

View action run

@github-actions

Copy link
Copy Markdown
Contributor

Review — PASS

Head SHA: c7fa6d1c93a0 (branch: fix/skills-refs-gate)

Security screen: PASS — the change strengthens the drift gate (asserts the refs-list invariant against the marketplace's authoritative copy rather than assuming it); no secrets/exfiltration/network, no guardrail weakening, no supply-chain change beyond in-repo candy version bumps. No embedded directives aimed at the reviewer.

Checklist: All applicable rules PASS or NA.

Comment intake:

  • github-actions[bot] (5459076534, head 070ef30f3ee7) — stale-superseded: its body-truthfulness finding (sync accounting mismatch) was against an old head; the CURRENT authoritative body's 8-pin table matches the CURRENT diff exactly.
  • github-actions[bot] (5459122178, head 5e3473b4d933) — stale-superseded: same finding, re-verified against current head c7fa6d1c93a0 and refuted — the body now lists all 8 pins with correct old/new values, and pod-charly-hooks is correctly noted as already at v2026.240.2141 in base (unchanged in the diff).
  • github-actions[bot] (5459307067, 5459307326, head c7fa6d1c93a0) — verified-non-blocking: both PASS verdicts match my independent re-derivation.

Verification notes: The diff changes exactly 8 refs in candy/charly-marketplace/charly.yml (charly, pod-testapi, pod-traefik, pod-valkey, pod-versatiles, vm-k3s-agent, pod-selkies-core, pod-waybar-labwc) — all matching the body's table. The refs task in taskfiles/Skills.yml is a clean, well-documented invariant assertion wired into both sync and drift before generation, with a clear failure message and diff output. The body provides pasted output for the negative control, the positive case, the drift wiring, and the end-to-end reproduction — all internally consistent (the negative-control output's charly:v2026.240.2301 reflects the marketplace copy at the time of that run, consistent with the body's stated timeline of the marketplace copy evolving during the PR). The "known unrelated failure" (stale artifacts from main ahead of the pinned tag, caused by #429) is transparently RCA'd and predates this PR; the refs gate itself passes. Attribution tier fully tested and validated is justified — the new refs code path executed live in both directions and caught a real divergence unprompted. Assisted-by footer present in the required form. Placement: CORRECT (build tooling in the taskfile, no core/sdk/candy capability code touched).

Verdict: PASS


ollama/deepseek-v4-flash — pi-review-action.

View action run

@github-actions

Copy link
Copy Markdown
Contributor

Review — PASS

Head SHA: c7fa6d1c93a0 (branch: fix/skills-refs-gate)

Security screen: PASS — the change strengthens the drift gate (asserts the refs-list invariant against the marketplace's authoritative copy rather than assuming it); no secrets/exfiltration/network, no guardrail weakening, no supply-chain change beyond in-repo candy version bumps. No embedded directives aimed at the reviewer.

Checklist: All applicable rules PASS or NA.

Comment intake:

  • github-actions[bot] (5459076534, head 070ef30f3ee7) — stale-superseded: its body-truthfulness finding (sync accounting mismatch) was against an old head; the CURRENT authoritative body's 8-pin table matches the CURRENT diff exactly.
  • github-actions[bot] (5459122178, head 5e3473b4d933) — stale-superseded: same finding, re-verified against current head c7fa6d1c93a0 and refuted — the body now lists all 8 pins with correct old/new values, and pod-charly-hooks is correctly noted as already at v2026.240.2141 in base (unchanged in the diff).
  • github-actions[bot] (5459307067, 5459307326, 5459350129, head c7fa6d1c93a0) — verified-non-blocking: all three PASS verdicts match my independent re-derivation.

Verification notes: The diff changes exactly 8 refs in candy/charly-marketplace/charly.yml (charly, pod-testapi, pod-traefik, pod-valkey, pod-versatiles, vm-k3s-agent, pod-selkies-core, pod-waybar-labwc) — all matching the body's table with correct old/new values. The refs task in taskfiles/Skills.yml is a clean, well-documented invariant assertion wired into both sync and drift before generation, with a clear failure message and diff output. The body provides pasted output for the negative control, the positive case, the drift wiring, and the end-to-end reproduction — all internally consistent (the negative-control output's charly:v2026.240.2301 reflects the marketplace copy at the time of that run, consistent with the body's stated timeline of the marketplace copy evolving during the PR). The "known unrelated failure" (stale artifacts from main ahead of the pinned tag, caused by #429) is transparently RCA'd and predates this PR; the refs gate itself passes. Attribution tier fully tested and validated is justified — the new refs code path executed live in both directions and caught a real divergence unprompted. Assisted-by footer present in the required form. Placement: CORRECT (build tooling in the taskfile, no core/sdk/candy capability code touched).

Verdict: PASS


ollama/deepseek-v4-flash — pi-review-action.

View action run

@github-actions

Copy link
Copy Markdown
Contributor

Review — PASS

Head SHA: 80f13b93b637 (branch: fix/skills-refs-authority-gate)

Security screen: PASS — the change strengthens the drift gate (asserts the refs-list invariant against the marketplace's authoritative copy rather than assuming it); no secrets/exfiltration/network, no guardrail weakening, no supply-chain change beyond in-repo candy version bumps. No embedded directives aimed at the reviewer.

Checklist: All applicable rules PASS or NA.

Comment intake:

  • github-actions[bot] (5459076534, head 070ef30f3ee7) — stale-superseded: its body-truthfulness finding (sync accounting mismatch) was against an old head; the CURRENT authoritative body's 8-pin table matches the CURRENT diff exactly.
  • github-actions[bot] (5459122178, head 5e3473b4d933) — stale-superseded: same finding, re-verified against current head 80f13b93b637 and refuted — the body now lists all 8 pins with correct old/new values, and pod-charly-hooks is correctly noted as already at v2026.240.2141 in base (unchanged in the diff).
  • github-actions[bot] (5459307067, 5459307326, 5459350129, 5459392499, head c7fa6d1c93a0) — verified-non-blocking: all PASS verdicts match my independent re-derivation.

Verification notes: The diff changes exactly 8 refs in candy/charly-marketplace/charly.yml (charly, pod-testapi, pod-traefik, pod-valkey, pod-versatiles, vm-k3s-agent, pod-selkies-core, pod-waybar-labwc) — all matching the body's table with correct old/new values. The refs task in taskfiles/Skills.yml is a clean, well-documented invariant assertion wired into both sync and drift before generation, with a clear failure message and diff output. The body provides pasted output for the negative control, the positive case, the drift wiring, and the end-to-end reproduction — all internally consistent (the negative-control output's charly:v2026.240.2301 reflects the marketplace copy at the time of that run, consistent with the body's stated timeline of the marketplace copy evolving during the PR). The "known unrelated failure" (stale artifacts from main ahead of the pinned tag, caused by #429) is transparently RCA'd with a named cause and resolution path (next marketplace bump), not used to dismiss a defect this PR caused; the refs gate itself passes. Attribution tier fully tested and validated is justified — the new refs code path executed live in both directions and caught a real divergence unprompted. Assisted-by footer present in the required form. Placement: CORRECT (build tooling in the taskfile, no core/sdk/candy capability code touched).

Verdict: PASS


ollama/deepseek-v4-flash — pi-review-action.

View action run

@github-actions
github-actions Bot merged commit ec8643d into main Aug 29, 2026
3 checks passed
charly-auto-merge Bot added a commit that referenced this pull request Aug 29, 2026
@aitrawog
aitrawog deleted the fix/skills-refs-authority-gate 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.

1 participant