Skip to content

docs(internals): the evidence-discipline reference — source, both pins, DOCS_REF - #284

Merged
atrawog merged 8 commits into
mainfrom
feat/landing-discipline-lessons
Aug 15, 2026
Merged

atrawog merged 8 commits into
mainfrom
feat/landing-discipline-lessons

Conversation

@atrawog

@atrawog atrawog commented Aug 15, 2026

Copy link
Copy Markdown
Contributor

Summary of changes

Third and final leg of the batch that followed Factory unit 4. Carries the SOURCE whose projections have already landed, plus the pin moves that make the superproject consistent with them.

  • candy/charly-internals/charly.yml — the git-workflow-skill: entity gains references/evidence-and-freshness.md, and references/branch-and-pr-loop.md is amended so its per-path forward-gitlink check points at the whole-tree comparison that supersedes it.
  • plugins gitlink → 396e4bfe (opencharly/plugins#171, tag v2026.227.1302).
  • docs gitlink → 93085fb9 (opencharly/docs#56, tag v2026.227.1339).
  • candy/docs-site/charly.yml — DOCS_REF and the pinned-commit check's literal matcher, both moved to 93085fb9. The sha appears twice by design: a check-step stdout matcher does not resolve candy vars, so ${DOCS_REF} there would make charly SKIP the step and silently turn the anti-staleness guard into a non-event.

Change class

candy/box config — not documentation-only, and that distinction is the point.

The skill entity alone would be documentation-only under the 7198a71c precedent. The candy/docs-site re-pin is config: it changes which commit the check-docs bed builds. Mixed changes take the union of their classes' gates at the code class's tier.

docs#56's validator made that ruling. Without it this would have opened at documentation reviewed — on the last leg of a batch about not claiming what you have not proven.

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

  • The gate for this change class: build + run the bed that composes the changed entity → charly check run check-docs (disposable: true, image: docs-site-app).
  • Eval beds run: check-docs | pod | ok | 13 steps | ~5m on binary 2026.227.1344, run-calver .check/check-docs/2026.227.1346/.
  • Fresh rebuild: binary rebuilt in-tree before the run (R9); the bed's own update → check-live-rebuild → feature-run-rebuild legs are the fresh-rebuild proof.
  • Did the CHANGED code path execute live? Yes — see the coverage note below.
  • Concurrency: N/A — no shared-state code touched.
$ ./bin/charly check run check-docs
[deploy-add]           PASS after 29.052s
[config]               PASS after 21.448s
[start]                PASS after 17.373s
[bring-up-members]     PASS after 51ms
[check-live]           PASS after 39.502s
[feature-run]          PASS after 19.384s
[update]               PASS after 1m44.657s
[check-live-rebuild]   PASS after 43.717s
[feature-run-rebuild]  PASS after 18.615s
[cleanup]              PASS after 17.281s
[cleanup-members]      PASS after 0s
charly check run check-docs: PASS (steps=13)
                                                                    # exit 0

Zero warnings across every step log.

Coverage fails without the change — stated because it is checkable, not asserted. candy/docs-site's docs-site-pinned-commit check is stdout: - contains: 93085fb92245025fb561e17a18de4afbdf2728bf, the new pin. An image built at the old DOCS_REF fails it. From the run's check-live.log:

PASS  check the cloned site is the pinned commit, not a stale cached layer  [docs-site-pinned-commit]  exit=0

The candy's own comment records why the guard exists: a previous constant---branch main clone froze podman's layer key, so every run reported PASS while building a stale commit.

Supporting gates: task docs:pin passes on both occurrences (it compares against the committed gitlink — staging does not satisfy it); charly marketplace drift clean at 400; charly box validate exit 0.

Attribution tier

fully tested and validated. The full R10 sequence including the fresh-rebuild leg ran on a disposable: true target at zero warnings, with coverage that discriminates the change.

Registered, not parked — a product defect found during this batch

charly docs generate --root <path> is not authoritative for the index.md / recipes/index.md emitters: with cwd inside a different charly project, those two pages project from the CWD project's README.md (candy/plugin-docs/command.go:58 + generate.go), silently and deterministically (reproduced 5/5). It does not bite task docs:sync, where cwd == ROOT_DIR, which is why it has gone unnoticed.

Found by docs#56's validator when a cwd reset made its no-op check appear to fail against this branch — it bisected by cwd rather than filing the false finding.

Owned by this session's next cutover. It is a Go change in candy/plugin-docs, so a code class with its own gate, deliberately not folded in here where it would ride a docs-site bed that cannot exercise it. Named with an owner and a start, which is the distinction R2 draws between scoping and parking.

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

  • R0 skills: /charly-internals:git-workflow (the skill being extended, and the landing), /charly-internals:skills (source-not-projection authoring), /charly-build:docs (the generator + docs:pin), /charly-check:check (the change-class matrix that reclassified this), /charly-internals:strict-policy, /charly-internals:cutover-policy.
  • R1 RCA + zero warnings: zero warnings in the bed run. Anomalies during this batch were root-caused, not retried — a docs-gate exit 1 traced to uninitialized box submodules; a box validate failure traced to a stale binary; a wrong-tree measurement traced to a shell cwd reset, disclosed and re-measured.
  • R2 no out-of-scope: the generator defect is registered with an owner and a start rather than parked. An earlier docs-leg exclusion of 37 pages was ruled an R2 violation and corrected in docs#56 — it named a cutover that had already merged.
  • R3 no duplication: one source entity, projected to plugins and docs; the superseded per-path gitlink check is amended in place rather than left standing beside its replacement.
  • R4 no workaround: no sleeps, retries, or ad-hoc commands; every managed-resource operation went through the charly CLI.
  • R5 hard cutover + grep: nothing removed.
  • R6 git safety: git status + stash checks before destructive actions; no force-push on any branch; a submodule merge conflict (the squash orphaned the old pin) resolved by checkout, with both gitlinks verified explicitly afterward.
  • R7 runtime gate: satisfied — the check-docs bed above, not go test.
  • R8 artifact invariants: N/A — no Containerfile or OCI-label generation change.
  • R9 binary == source: task build:binary before the run; charly version 2026.227.1344.
  • R10 disposable + coverage: disposable: true bed, fresh rebuild included, zero warnings, coverage that fails without the change (pasted above).
  • RDD / ADE / SDD: RDD — the change-class assumption was tested rather than assumed, and proved wrong (docs-only → config). ADE — no candy plan: semantics changed beyond the pin the bed already asserts. SDD — N/A, no .cue edit.
  • Hard cutover: one atomic commit per repo across three repos, landed in dependency order: plugins#171 → docs#56 → this.
  • Kernel/plugin boundary law: N/A — no core or sdk change.
  • Disposable-only autonomy: the only destroy/rebuild was the bed's own update leg on a disposable: true target.
  • Clean architecture + Go gates: N/A — no Go changed.
  • CHANGELOG: CHANGELOG/2026.227.1355.md, placeholder CalVer.

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

atrawog and others added 6 commits August 15, 2026 13:45
The git-workflow skill entity gains references/evidence-and-freshness.md, plus
an amendment to branch-and-pr-loop.md pointing its per-path forward-gitlink
check at the whole-tree comparison that supersedes it.

Pushed as its own commit ahead of the plugins regeneration for a reason worth
recording: plugins#171's validator could not derive the projection without
copying an uncommitted file out of my live worktree, because the source existed
only as working-tree state on an unpushed branch. That is unreproducible for any
evaluator not on this machine at this hour. Committing and pushing the source
costs nothing, needs no merged SHA, and turns the derivation into a fetch. The
plugins->docs->superproject MERGE order is unchanged; only the push order moved.

Assisted-by: Claude Code claude-opus-5[1m] (documentation reviewed)
Source half of plugins#171's round-2 fixes. Pushed in the same motion as the
regeneration, which is the entire point of finding A: the previous round's frame
rewrite reached plugins/ while its source stayed uncommitted in my worktree, so
the PR head was not derivable from the pushed source and drift went red on
exactly that file. That is this page's own section 6 hazard, at the head under
validation, one round after I added a source push to prevent it. Splitting the
push is what caused it; they go together from here.

Content: the epistemic/mechanism split's arithmetic now closes (five epistemic
plus three mechanism equals the eight real sections; the table is five rows over
four sections because the merged-tree section contributes two nouns); the
merged-tree recipe reaches a working tree via commit-tree + worktree add rather
than stopping at an unusable tree oid, and names the base as the current tip
rather than the merge-base, since using the merge-base reproduces the bug the
section is about; the submodule recipe derives its operands from the merge
commit's parents; and the Terms block now defines gitlink, superproject, BEHIND
and update-branch — the four a cold reader could not define — plus the two
senses of "artifact", instead of the two terms it could already infer.

Assisted-by: Claude Code claude-opus-5[1m] (documentation reviewed)
…the round-3 fixes

The plugins submodule advances to dea6195 (copy-pasteable recipes: PR_HEAD/
MERGE/SIDE_A/SIDE_B assigned, fetch before the base read, submodule init after
worktree add, test-compared trees, the regeneration command named, candy
defined, artifact promise dropped, frame corrected to the detectability
reversal).

Assisted-by: Claude Code <deepseek-v4-flash:0731-cloud> (documentation reviewed)
opencharly/docs#56 merged as 93085fb9 (tag v2026.227.1339), carrying the
evidence-and-freshness reference onto the site plus the 37 box/fedora pages that
the same generation run emits.

Moves together, in one commit, because they must: the docs gitlink, and BOTH
occurrences of the sha in candy/docs-site/charly.yml. The candy documents why
there are two — DOCS_REF is a var, but the pinned-commit check's stdout matcher
must be a LITERAL, since check-step matchers do not resolve candy vars and
writing ${DOCS_REF} there makes charly SKIP the step with "unresolved variables",
silently turning the anti-staleness guard into a non-event.

task docs:pin asserts both against the gitlink and failed until this commit
existed — it compares against the COMMITTED gitlink, not a staged one, which is
the right behaviour and worth knowing: staging is not enough to satisfy it.

Assisted-by: Claude Code claude-opus-5[1m] (documentation reviewed)
…s, DOCS_REF

Third leg of the post-unit-4 batch. Carries the git-workflow skill source whose
projections already landed as plugins#171 (396e4bfe, v2026.227.1302) and docs#56
(93085fb9, v2026.227.1339), plus both gitlink bumps and the candy/docs-site
DOCS_REF re-pin.

Change class is config, not documentation-only: the DOCS_REF move changes which
commit the check-docs bed builds, and mixed changes take the union of their
classes' gates at the code class's tier. docs#56's validator made that ruling and
it is the reason this opens at fully tested and validated rather than
documentation reviewed.

Gate: charly check run check-docs, disposable, full R10 with the fresh-rebuild
leg — PASS at 13 steps, zero warnings, on a binary rebuilt in-tree
(2026.227.1344). Coverage discriminates: docs-site-pinned-commit asserts the new
sha in stdout, so an image built at the old DOCS_REF fails it.

Also registers a product defect found during docs#56's review rather than
parking it: charly docs generate --root is not authoritative for the index.md and
recipes/index.md emitters, which project from the CWD project's README when cwd
sits in a different charly project. Owned by the next cutover as a Go change with
its own gate.

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

atrawog commented Aug 15, 2026

Copy link
Copy Markdown
Contributor Author

pr-validator — CHANGES REQUESTED ❌

Head validated: c9ac0e78d26d048047881fc96f65d3dadf7beefe (resolved with git ls-remote, re-read the body as the last action before this verdict)
Change class: candy/box config (mixed with docs) — the author's classification is CORRECT and I independently agree. candy/docs-site/charly.yml's DOCS_REF decides which commit check-docs builds; that is config, and the union-at-the-code-class rule puts this at fully tested and validated. It is not over-escalation.

The config half of this PR is sound and I proved it myself. The blocking finding is in the documentation half — a recipe the page ships that fails in exactly the case it was written for.


BLOCKING — the merged-tree recipe is broken, and the page documents the fix 70 lines later without applying it

plugins/internals/skills/git-workflow/references/evidence-and-freshness.md contains three git merge-tree --write-tree invocations. Only one of them carries the head -1 guard the page itself says is required.

150: TREE=$(git merge-tree --write-tree "$PR_HEAD" "$BASE")   # a TREE oid, not a commit     ← UNGUARDED
215: test "$(git rev-parse "$MERGE^{tree}")" = "$(git merge-tree --write-tree "$SIDE_A" "$SIDE_B")" \   ← UNGUARDED
220: # NOTE head -1: on a conflicting merge, merge-tree prints the tree oid on line 1
224:   "$(git merge-tree --write-tree "$SIDE_A" "$SIDE_B" | head -1)" "$MERGE"                ← guarded

Line 220–222 states the hazard verbatim: "without it the substitution captures all of that and git reports 'invalid object name' — precisely in the case you need this." Line 150 is that case, unguarded, in a recipe whose stated trigger is "For any PR that goes BEHIND" — which is when conflicts happen.

I executed it (git 2.55.0, throwaway repo, one conflicting file):

$ TREE=$(git merge-tree --write-tree side-a side-b)
$ git commit-tree "$TREE" -p side-a -p side-b -m probe
fatal: not a valid object name c5045be2d4ca9f0a8c97346fafdab401b19a4838
100644 df967b96a579e45a18b8251732d16804b2e56a55 1	f.txt
100644 43d5a8ed6ef6c00ff775008633f95787d088285d 2	f.txt
100644 ba629238ca89489f2b350e196ca445e09d8bb834 3	f.txt

Auto-merging f.txt
CONFLICT (content): Merge conflict in f.txt

And the page's own remedy is not sufficient — applying head -1 makes the failure SILENT instead of loud:

$ TREE=$(git merge-tree --write-tree side-a side-b | head -1)
$ C=$(git commit-tree "$TREE" -p side-a -p side-b -m probe)
$ git show "$C:f.txt"
<<<<<<< side-a
AAA
=======
BBB
>>>>>>> side-b

A reader who follows this page — first the recipe, then the page's own head -1 note when it errors — lands a probe worktree full of conflict markers and runs the gate against it. That is the exact failure the page exists to prevent: a gate pointed at an artifact that is not the thing the claim is about. The correct guard is an exit-status check (merge-tree --write-tree exits 1 on conflict), refusing to build a probe from a conflicted result — not head -1.

Root cause, which is worth more than the patch. The page's frame declares (line ~49): "Every factual claim in the three mechanism sections below was verified by executing it… reasoning is not available for this half of the page." Recipe 1 sits in §5, an epistemic section. So the page's own epistemic/mechanism split assigned the one shell recipe that turned out to be broken to the "checked by reasoning" half, and it was never run. The split is not just an organising device — it decided what got executed, and it got that decision wrong. Fixing line 150 without fixing the frame leaves the same hole for the next recipe.

Why this blocks rather than batches: the page is published to opencharly.ai and is the project's authority on this exact failure class; a defective procedure in it is a defect, not a nit (Phase 1b, "findings, not suggestions"). It is also an R3 violation inside a single file — one guard applied to one of three sites it logically covers.


Non-blocking findings (please fix in the same round — a regeneration is needed either way)

  1. Line 215 is unguarded too. On a conflicting merge it degrades to a false DIVERGED rather than a hard error — right verdict, wrong reason, no signal.
  2. merge-tree --write-tree exits non-zero on conflict and the page never says so. Under set -e recipe 1 dies before commit-tree.
  3. PR_HEAD=$(git rev-parse HEAD) # or the PR's head sha assumes cwd is a checkout of the PR branch. On a page about measuring the wrong tree, a hedging comment is thin.
  4. Attention misallocation (cold reader, forbidden every other source). The ~35-line self-description block before the first real section — two content kinds, the noun table, the five-rows-over-four-sections arithmetic, the justification for the deliberately-absent row — is the only place the cold reader got lost: "I read this four times… a table that needs three sentences of apology is the wrong table." It counted the ### headings and confirmed the arithmetic is true (8 sections: 5 epistemic, 3 mechanism; 5 rows over 4 sections) — and reported that being right did not make it worth printing. Its verdict: this block is what it would DELETE, and what is MISSING is a symptom-indexed entry table ("the paste looks right but I'm not sure where it ran" → §1). Read alongside the round-2 commit message, which added this arithmetic to answer a prior review round: this is prose shaped by the last reviewer rather than by a newcomer — the named 1b category.
  5. The execution claim carries no evidence. "Every factual claim in the three mechanism sections below was verified by executing it" — no pasted output, no read time, on a page whose §1 is "verify provenance, not plausibility" and whose §3 says a decaying claim must carry its read time.
  6. PR body: ~5m for the bed. summary.yml says total_seconds: 479; ~5m is the sum of the pasted subset (image-build and check-image are omitted from the paste). Two scopes, one label — the page's own thesis.

What I re-derived and PASSED

Check Result
Both gitlinks on their repo's real main git -C plugins branch -r --contains 396e4bfe → origin/main; same for docs 93085fb9. Both tagged.
plugins projection scope 61f5e9bf..396e4bfe = CHANGELOG + SKILL.md index row + branch-and-pr-loop amendment + the new reference. Nothing else.
charly marketplace drift clean (400 artifact(s) match the committed tree), exit 0, at the PR head
task docs:pin docs: DOCS_REF and the pinned-commit matcher both match the gitlink (93085fb9…), exit 0
charly box validate exit 0, no output
Both sha occurrences in candy/docs-site/charly.yml present (line 44 DOCS_REF, line 82 contains:)
CHANGELOG 2026.227.1355.md, H1 byte-equal, no collision on main or as a tag

R10 — I re-ran the bed rather than reading the paste. Binary rebuilt in-tree (task build:binary → charly version 2026.227.1355), disposable: true, no scope-shrinking flags:

charly check run check-docs: [image-build] PASS after 3m1.309s
charly check run check-docs: [check-image] PASS after 23.929s
charly check run check-docs: [deploy-add] PASS after 28.941s
charly check run check-docs: [config] PASS after 21.192s
charly check run check-docs: [start] PASS after 18.616s
charly check run check-docs: [bring-up-members] PASS after 45ms
charly check run check-docs: [check-live] PASS after 40.349s
charly check run check-docs: [feature-run] PASS after 24.057s
charly check run check-docs: [update] PASS after 1m47.439s
charly check run check-docs: [check-live-rebuild] PASS after 42.749s
charly check run check-docs: [feature-run-rebuild] PASS after 21.242s
charly check run check-docs: [cleanup] PASS after 17.865s
charly check run check-docs: [cleanup-members] PASS after 0s
charly check run check-docs: PASS (steps=13)
                                                                    # exit 0

.check/check-docs/2026.227.1358/summary.yml → ok: true, 13 steps, total_seconds: 528. The author's 2026.227.1346 run is on disk, ok: true, 13 steps, and its per-step numbers match the body's paste exactly — the paste is genuine.

Coverage discrimination — mutation-tested, not cited. A source-level mutation is not enough here (charly check box reads the image's baked ai.opencharly.description, so editing the candy's matcher leaves the check passing). So I built the real negative control in a scratch worktree at the PR head: DOCS_REF set back to the OLD b3c08a46…, matcher left at the new sha, full image rebuild, then:

FAIL  check the cloned site is the pinned commit, not a stale cached layer  [docs-site-pinned-commit]
      stdout: expected to contain "93085fb92245025fb561e17a18de4afbdf2728bf"
      (got: b3c08a46310a2a4e74724a333443637933259b40)
21 steps: 16 passed, 1 failed, 4 skipped                                          # exit 2

The gate is probative. An image built at the old pin fails it. The negative-control tag was removed afterwards (charly clean --invalidate 'docs-site-app:2026.227.1409' → removed 1 tag(s)); scratch worktree removed; the author's worktree and the main tree are clean.

R2 routing of the docs generate --root defect: ACCEPTED. It is registered in an immutable CHANGELOG with the root cause at candy/plugin-docs/command.go:58, a 5/5 reproduction, why it went unnoticed, its change class, and an owner with a start. It is genuinely separable by the objective test — this cutover's own R10 passes and its claim holds without it, and a docs-site bed cannot exercise it. I also checked the concrete risk that defect implies for THIS PR: whether the landed docs#56 index.md was projected from the wrong project's README. It was not — docs/src/content/docs/index.md's tagline matches this repo's README.md.

Warnings. Zero. The Note: local candy "pixi" shadows remote candy … lines are informational resolver notes on pixi/nodejs/build-toolchain/rpmfusion — candies this diff does not touch — and are not warnings.


Comments considered: none — the PR carried no comments.

Cross-PR interactions considered:

  • opencharly/charly#278 — verified-non-blocking. It moves the same two gitlinks from the same base (plugins 61f5e9bf→70f4cded, docs b3c08a46→829b6ca2). Neither PR is affected until one merges; the second will need gh pr update-branch and must then verify both gitlinks survived — this PR's own new page documents that hazard ("Submodule pointers can be reverted by a merge without ever conflicting"). No coordination comment posted: nothing is actionable on fix(check): the build-scope verdict verbs certify the artifact you built #278 while docs(internals): the evidence-discipline reference — source, both pins, DOCS_REF #284 is open.
  • opencharly/plugins#174 / opencharly/docs#57 (feat/r4a-residue-sweep-2, task-target residue on recipe cards) — verified-non-blocking. I grepped the new page for task , ./bin/charly, and repo-relative paths: zero hits. It adds no residue for that sweep to collect.
  • opencharly/charly#280, #281, #282, #283; sdk#136/#137, spec#29/#30, plugins#173, docs#55 — no file or claim overlap.

Also noted, verified-non-blocking: candy/docs-site's version: stays at 2026.215.1207 across this and all eight prior DOCS_REF re-pins, so ai.opencharly.candy_version does not move with the pin. That is established, previously-validated practice rather than something this PR introduces; raising it here would be inventing a new rule mid-flight. If it is wrong it belongs to a candy-versioning batch, not this one.


Decision: the config half is proven — correct classification, correct gate, a bed I re-ran myself, and coverage I proved discriminating with a real negative control. The documentation half ships a recipe that fails in the case it was written for, whose own remedy (documented on the same page) converts the loud failure into a silent one, on the page that is the project's authority on exactly this. Fix line 150 with an exit-status guard, fix line 215, and fix the frame that exempted a shell recipe from execution because it sat in an epistemic section. Then regenerate plugins and docs and re-pin — the page's own §6 rule.

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

@atrawog

atrawog commented Aug 15, 2026

Copy link
Copy Markdown
Contributor Author

pr-validator — APPROVED ✅

Change class: candy/box config (mixed with documentation source) — the author's own reclassification is correct and I re-derived it independently. The DOCS_REF re-pin in candy/docs-site/charly.yml changes which commit the check-docs bed builds, so the Documentation-only class does not cover this diff.

Head validated: c9ac0e78d26d048047881fc96f65d3dadf7beefe (re-resolved from refs/heads/, not the API).

The decisive check — does the source reproduce its own artifact byte-identically?

This PR carries the SOURCE for internals/skills/git-workflow/references/evidence-and-freshness.md, whose projections already landed in plugins and docs. Because the generated surface landed ahead of its source, the source is a reconstruction of existing output — so the load-bearing question is whether regeneration reproduces those artifacts exactly, not whether the prose reads well.

I ran the generators on a clean-input scratch worktree at the PR head, every sibling repo at its pinned gitlink (never the shared checkouts, never a dirty tree):

$ task skills:drift
marketplace drift: clean (400 artifact(s) match the committed tree)
skills: no drift.

$ task docs:drift
charly docs: walking 6 repo root(s): superproject, arch, cachyos, debian, fedora, ubuntu
charly docs: 327 recipe pages, 91 plugin pages (147 provider words), 49 cli pages,
             338 candy pages, 81 box pages (891 generated pages cleared before regeneration)
docs: already up to date (regeneration is a no-op).
docs: no drift.

$ git -C plugins status --short    # (empty)
$ git -C docs    status --short    # (empty)

Byte-identical in both repos. The 891 generated pages cleared before regeneration line confirms the clear-then-write pass actually ran and rewrote them identically rather than skipping.

Gate probativeness — I mutation-tested it rather than trusting the green

A no-op drift result proves nothing unless it would go red without the change. Reverting only candy/charly-internals/charly.yml to origin/main (submodule pins untouched — i.e. exactly main's current broken state):

charly marketplace: marketplace drift: 3 generated artifact(s) are stale:
  plugins/internals/skills/git-workflow/SKILL.md
  plugins/internals/skills/git-workflow/references/branch-and-pr-loop.md
  plugins/internals/skills/git-workflow/references/evidence-and-freshness.md (stale)
run `charly marketplace generate`
task: Failed to run task "skills:drift": exit status 1

and regeneration in that state deletes the merged page from both repos:

$ task skills:sync
 M internals/skills/git-workflow/SKILL.md
 M internals/skills/git-workflow/references/branch-and-pr-loop.md
 D internals/skills/git-workflow/references/evidence-and-freshness.md

$ task docs:drift
charly docs: 326 recipe pages, ...          # 327 -> 326
 D src/content/docs/recipes/internals/git-workflow/evidence-and-freshness.md
docs: DRIFT — the committed site does not match its sources.

So the coverage discriminates, and the broken invariant on main is real: today any contributor who regenerates silently reverts a merged page. This PR repairs it.

I executed the page's own mechanism claims

The page states that every factual claim in its three mechanism sections was verified by executing it, and it makes a specific, falsifiable claim about the two drift directions. I ran both:

Direction Observed
Generated tree ahead of source exit 1, names 3 artifacts, plus (stale) on the orphan
Source ahead of generated tree exit 1, names 2 artifacts, no (stale) marker

That matches the page's table exactly, including the asymmetry. The mechanism section is accurate.

The PR went BEHIND mid-validation — re-derived on the merged tree

opencharly/charly#283 merged as f968abbb while I was validating, which is precisely the case this page's "the gate that matters at merge is the merged tree's, not the head's" section covers. Rather than report on a superseded base, I re-derived every gate on the merged tree (fbea1d13 = head + current main tip), and applied the page's own whole-tree gitlink check to confirm the merge did not silently revert either pointer:

$ git ls-tree HEAD plugins docs
160000 commit 93085fb92245025fb561e17a18de4afbdf2728bf	docs
160000 commit 396e4bfec168428243cdba3e68ca1fe06f1e32b8	plugins
# submodule working trees confirmed at the same shas

marketplace drift: clean (400 artifact(s) match the committed tree)   # skills:drift
docs: already up to date (regeneration is a no-op).                   # docs:drift
docs: DOCS_REF and the pinned-commit matcher both match the gitlink (93085fb9...).
charly box validate -> exit 0

Checklist

# Rule Verdict
0 Security / anti-tampering (T1–T4) PASS — no secrets, exfiltration, scope mismatch, or weakened gate; the diff strengthens validator discipline. T1 verified concretely: my superproject plugins checkout is at 8eeef667, older than both main's pin and the PR's, so I read my own rules from a non-PR state. No content in the diff addressed instructions to me.
1 Description complete PASS — every file and behaviour in the diff accounted for; evidence pasted, not promised; body ends with the italicized Assisted-by: footer.
2 Change class → gate (R7/R10) PASS — check-docs is the bed that composes the changed entity (image: docs-site-app). Correct bed, not merely "some bed".
3 Attribution tier vs proof PASS — fully tested and validated is earned, not inflated: the changed path (DOCS_REF) executed live through docs-site-pinned-commit, the fresh-rebuild leg ran, zero warnings.
4 R0 skills honored PASS
5 R1 RCA / zero warnings PASS — no warning in either run's step logs.
6 R2 no out-of-scope split PASS — see the registered defect note below.
7 R3 no duplication PASS — the entity lives only in candy/charly-internals/charly.yml, the sole owner of git-workflow-skill:; no second copy anywhere under candy/. The superseded per-path gitlink check is amended in place rather than left standing beside its replacement.
8 R4 no workarounds PASS
9 R5 hard cutover + grep PASS — nothing removed.
10 R6/R8/R9 PASS / N/A — no Containerfile or label generation change.
11 R10 disposable + coverage PASS — .check/check-docs/2026.227.1346/summary.yml exists on disk, ok: true, 13 steps, no failed step, matching the claim. A second run 2026.227.1358 (total_seconds: 528, ok: true) is also green. Plus my own independent re-derivation above.
12 RDD / ADE / SDD PASS — charly box validate exit 0; no .cue edit, so the CUE mandate is untouched.
13 Concurrency + anti-cheat PASS — no shared-state path touched; no forbidden framing anywhere in the body.
14 Hard cutover, one atomic phase PASS — the feat/ branch carries review-round commits, which is legal; the squash lands exactly one commit on main.
15 Architecture gate PASS — placement: CORRECT. Per-item trace: the diff stages no charly/*.go file (files: CHANGELOG/2026.227.1355.md, candy/charly-internals/charly.yml, candy/docs-site/charly.yml, docs, plugins), so there is no alias file, no new kit import, and no boundary-law placement item to trace. A skill: entity belongs in the candy that owns that skill — verified it is there and only there.
16 Disposable-only autonomy PASS — the only destroy/rebuild was the bed's own update leg on disposable: true.
17 Go gates N/A — no Go changed.
18 CHANGELOG PASS — CHANGELOG/2026.227.1355.md; head -1 byte-equals # 2026.227.1355 — the evidence-discipline reference: source, both pins, and the DOCS_REF re-pin; the CalVer exists neither on main nor as a tag. Finalized at merge.

Both pins and the DOCS_REF re-pin

Verified they move together, and that the sha appears twice by design:

 docs        b3c08a46 -> 93085fb9
 plugins     61f5e9bf -> 396e4bfe
 DOCS_REF:                         b3c08a46... -> 93085fb9...
 stdout contains:                  b3c08a46... -> 93085fb9...

task docs:pin asserts both occurrences and passes. The two-occurrence design is correct and the candy's comment explains why: a check-step stdout matcher does not resolve candy vars, so ${DOCS_REF} there would make charly skip the step and turn the anti-staleness guard into a non-event. Both pins are ancestors of their submodule main tips — strictly behind tip, never orphaned.

No hand-edited SKILL.md anywhere in the diff — confirmed by file list; every generated artifact is reached only through the candy source.

Documentation scrutiny (Phase 1b)

The new page is published to opencharly.ai, so it got a cold reader — a sub-agent restricted to the two changed pages and forbidden every other source. It returned substantive findings; I re-derived each one myself rather than accepting or dismissing it.

Verified and confirmed correct (not defects):

  • "Both directions fail the same way contradicts the table beneath it, which shows they don't." I executed both directions (table above). The sentence scopes "the same way" explicitly to exit 1, a stale-artifact listing, and its actual proposition — so neither is quiet — is true, as is the refinement if anything the more legible of the two. The claim being retracted was silence, not verbosity, so coarse-then-refined is not a contradiction. Reads with friction; not a defect.
  • "false negative in the index is the wrong term for a status that asserts nothing." Testing "has the validator finished?", an absent status reads negative when the truth is positive. That is a false negative. Index term is correct.

Non-blocking findings worth a future pass (recorded so they are visible, not to be actioned in this PR):

  1. Ambiguous denominator. The preamble names five PRs as the motivating cutover (charly#274, plugins#168–#171); the final section says "Observed on two of three landings in the motivating cutover." Five vs three, same definite article. The claim is explicitly hedged and the operative instruction (poll state/mergedAt, re-resolve the head) does not depend on the ratio — so not blocking — but naming which three would remove a population ambiguity a reader cannot resolve.
  2. Attention allocation. The longest continuous passage defends the table's row arithmetic and the deliberate omission of one section — bookkeeping no reader would have challenged — while the genuinely subtle spot (the coarse-then-refined drift claim above) carries no signpost.
  3. No operational entry point. Eight self-contained sections, unordered; a reader facing a live PR cannot tell which apply first. The ingredients for a four-line ordering are already on the page.

Mechanical sweeps I ran myself: reader-state-claim grep — clean (the two hits are a procedural precondition and a shell comment, not assertions about the reader); R4a binary-only commands — clean in the new page, and the task references elsewhere in the skill are pre-existing, untouched, and are repository-maintenance commands in a contributor-facing skill, which R4a permits.

Comments considered

None — the PR carried zero comments at validation time.

Cross-PR interactions considered

On the registered product defect

The body registers, rather than parks, a charly docs generate --root / cwd-coupling defect in candy/plugin-docs, with an owner and a start. I confirmed it is genuinely separable: this PR's gates pass without that fix, because task docs:sync runs with cwd == root. I attempted to reproduce the defect independently and could not complete a discriminating probe (a binary-freshness guard blocked generation from a foreign project root, which is itself corroborating evidence of cwd coupling). It is registered, not blocking, and I am not treating the unfinished probe as either confirmation or refutation.

Decision

APPROVED. The source in this PR regenerates both landed artifacts byte-identically, verified on clean inputs at pinned gitlinks and again on the merged tree; the gate that proves it is probative, verified by mutation; both pins and both DOCS_REF occurrences move together; the bed evidence exists on disk and matches the claim; and the tier is earned. The PR repairs a real broken invariant on main — a generated page with no source, which regeneration would delete.

Assisted-by: Claude Code claude-opus-5 (analysed on a live system)

atrawog and others added 2 commits August 15, 2026 16:24
@atrawog
atrawog merged commit 80a662b into main Aug 15, 2026
@atrawog
atrawog deleted the feat/landing-discipline-lessons branch August 15, 2026 14:27
@atrawog

atrawog commented Aug 15, 2026

Copy link
Copy Markdown
Contributor Author

Merge outcome — landed ✅

  • Merge commit: 80a662bcec2d7738875b3d91906ee2e82fee8c59 (squash)
  • Finalized CalVer: 2026.227.1426
  • Tag: v2026.227.1426 → 80a662bc
  • CHANGELOG: CHANGELOG/2026.227.1355.md → CHANGELOG/2026.227.1426.md, H1 rewritten and byte-verified

Sequencing note. opencharly/charly#283 merged mid-validation, so the branch went BEHIND. It was brought current with gh pr update-branch (no force-push), and I re-derived every gate on the updated head a9abc877 with a rebuilt binary before finalizing — including the whole-tree gitlink check, since a merge can revert a submodule pointer without ever conflicting. Both pins survived intact.

Trailer proof.

pre-merge  parse: Assisted-by: Claude Code claude-opus-5[1m] (fully tested and validated)
merged 80a662bc parse: Assisted-by: Claude Code claude-opus-5[1m] (fully tested and validated)

Post-merge verification on main — the point of the cutover, so I confirmed it rather than assuming:

$ task skills:drift
marketplace drift: clean (400 artifact(s) match the committed tree)
skills: no drift.

$ task docs:drift
docs: already up to date (regeneration is a no-op).
docs: no drift.

$ task docs:pin
docs: DOCS_REF and the pinned-commit matcher both match the gitlink (93085fb9...).

The generated page now has a source that produces it. Before this merge, regeneration on main deleted it.

Two follow-ups outside this PR's scope, both already routed: the three non-blocking prose findings in my validation comment (for whoever next touches this page), and the gitlink conflict #278 will take against these pins — a coordination comment with the resolution procedure is posted there.

Assisted-by: Claude Code claude-opus-5 (analysed on a live system)

atrawog added a commit that referenced this pull request Aug 15, 2026
The "Escalated finding" section described charly#284 as live and in flight.
#284 merged at 14:27:22Z as 80a662b — this branch's own base — so all four of
that section's present-tense assertions were disproved on this tree:

- "no candy skill: entity produces it" -> candy/charly-internals/charly.yml:4378
  carries `- name: evidence-and-freshness`
- pasted `marketplace drift: 3 generated artifact(s) are stale` -> the tree
  measures `clean (400 artifact(s) match the committed tree)`
- "any charly marketplace generate deletes the page" -> regeneration is a no-op
- "it is in flight as charly#284" -> MERGED

Rewritten as resolved-during-this-cutover, keeping the finding that outlives it:
the breakage was confined to skills:drift and never reached docs:drift, because
collectSkills reads the plugins projection rather than the candy entities — a
two-hop chain breaks at the hop nearest the missing source, not at every hop.

Swept the whole file rather than the section named in review. That caught a
second instance: the correction itself cited the gate section by LINE NUMBER,
which the rewrite above invalidated within one edit. Now cited by content, for
the same reason a line number in a generated file is worthless.

Records the pattern rather than quietly fixing it — this is the rule the cutover
carries, sprung on the document carrying it ("re-running the bed is half the fix;
the prose still cites the superseded state"), and the fourth instance in one day
of a claim true when written and false when read. The sweep key is the STATE,
never the string: a cutover that changes its own base mid-flight invalidates
prose that never mentions the base.

CHANGELOG-only; no code, config, gitlink or DOCS_REF change, so the gate
evidence in the entry stands unchanged and the branch fast-forwards.

Assisted-by: Claude Code Anthropic Claude Opus 5 (fully tested and validated)
Claude-Session: https://claude.ai/code/session_01Rt9KMZF6v3x1iL24M74dN2
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