Repository navigation
Description
Written-by: Fledge Platform Product
Parent: #372
Pin: d16ebf60cc260a3af30223392a86379deac1fd15 — every file:line below was read at it (Date: Sun, 22 Nov 2026 08:25:16 GMT).
Boundary check first: this is on the implementable side
The slice the Lead set is expressible in src/jobs/shadow.ts alone, so this card does not fall on the close-not-planned side of the boundary.
evidenceOf already has a missing branch that a host can reach: src/lib/evaluation.ts:332-337 returns none only for verificationJson === null (:333), and returns missing whenever a snapshot is present and does not establish green — parseVerification rejects it, or accepts it with ok: false (:334-336). The recorder at src/jobs/shadow.ts:72 is what forces every attempt down the none branch. src/lib/evaluation.ts is consumed, not edited.
parseVerification requires exactly one field, a boolean ok (src/lib/verification.ts:119-133, the check at :123), so the recorder can publish a snapshot of what it observed and nothing else. It must not fill sha, prState, mergeableState, combinedStatus or reviews with values nobody read: the mock calls out to nothing (src/jobs/shadow.ts:1-5, src/jobs/mock.ts:6-23), and inventing a pull-request read to move a counter is the same class of mistake this card exists to remove.
The defect
Expected. The bundled reference recorder records what it observed: an attempt ran, and zero check runs were observed. In the report's own vocabulary that is missing — the state for a verification snapshot that does not establish green (src/lib/evaluation.ts:19, :335-336).
Actual. createMockShadowHost publishes verificationJson: null (src/jobs/shadow.ts:72), so every attempt is scored none (src/lib/evaluation.ts:333, :470) — "nothing was recorded", "unknown". A --record run over the checked-in fixture set reports evidence: { verified: 0, missing: 0, none: 4 } (:126, counted at :366, :374), and replaying the record prints the same four none.
Who feels it. The operator reading a promotion decision. The evidence column is one of the four fields the report exists to carry (docs/architecture.md:1419-1422), and none on every task under host mock is indistinguishable from a run where verification was never observed at all. The bundled recorder is the only host whose column cannot say "recorded, not verified".
Objection, answered. A mock attempt never expects checks, so missing could over-claim that checks were looked for and absent. Two things keep it honest: the record names the host and its signature beside the attempts (src/lib/evaluation.ts:167-171), and the snapshot carries its own reason line. The artifact then says "host mock ran these attempts and observed no check runs", which is true, instead of leaving the column meaning "unknown".
Minimal reproduction (offline, no token, no repository, no database)
Clean tree at the pin:
npx tsx scripts/evolution-shadow.ts --shadow test/fixtures/shadow/holdout.json --record /tmp/attempts.json --out /tmp/report.json
node -e 'console.log(JSON.stringify(require("/tmp/report.json").versions.map((v) => v.evidence)))'Today: [{"verified":0,"missing":0,"none":4}]. The fixture set is four expected: "pull-request" fixtures, all holdout, redacted: true, so every attempt opens the mock's constant pull request (src/jobs/mock.ts:19) and records no verification.
Replaying the written record (scripts/evolution-shadow.ts:116-164) prints the same four none:
npx tsx scripts/evolution-shadow.ts --shadow test/fixtures/shadow/holdout.json --attempts /tmp/attempts.json --out /tmp/replay.jsonAfter the fix both reports must read missing: 4, none: 0, and /tmp/attempts.json must carry a verificationJson that parseVerification accepts with ok: false — neither null nor a string parseVerification rejects, so missing means "recorded and not green", not "unreadable".
Evidence at the pin
- The recorder is the only
ShadowHostthe tree ships:createMockShadowHost(src/jobs/shadow.ts:59-81), called fromscripts/evolution-shadow.ts:99andtest/evaluationShadow.test.ts:63. - What it publishes today:
pullRequestfrom the runner's result (:69),merged: falsedeclared rather than observed (:70),reviewScore(:71),verificationJson: null(:72),costUsd: 0(:73),erroron a non-succeeded run (:76-78). - The runner it drives calls out to nothing and returns a constant pull request (
src/jobs/mock.ts:6-23, URL at:19, 250 ms wait at:8). - Scoring:
evidenceOf(src/lib/evaluation.ts:332-337), recorded per task (:109,:470), counted per version (:126,:366-376). - Report types:
ShadowEvidenceState(:19),ShadowAttemptwith the snapshot field and its comment (:81-92, comment at:87), the persisted attempt and record (:162-171),renderShadowRecord(:524-526). - Snapshot contract:
VerificationResult(src/lib/verification.ts:25-45) andparseVerification(:119-133). A real job snapshot with zero check runs also carriesok: falseand the reasonNo check runs.(src/jobs/service.ts:2475,:2480,:2491-2503, persisted at:2533), which is the shape a reader already knows. - Nothing in the tree pins today's state:
test/evaluationShadow.test.ts:59-91exercises the mock host and the record round-trip without assertingevidence. - The boundary that must not weaken: capabilities all false (
src/jobs/shadow.ts:64),assertShadowHost(src/lib/evaluation.ts:270-285,LIVE_HOSTat:277-283),LIVE_REPOSITORYrefusal (:442-445). - Documentation of the seam, unchanged by this card:
docs/architecture.md:1416-1444— evidence state from the sameparseVerificationa job uses (:1419-1422), capability refusal (:1427-1431), operator records on its own host and--recordis the bundled reference recorder that runs the mock runner and writes both artifacts (:1431-1439). - Risk tier: T3 by path,
src/jobs/**in.github/agent/risk-rules.json— a PASS at the tip plus greenci-ok.
Acceptance: red first at the pin
In test/evaluationShadow.test.ts (npx tsx --test), no network, no database, no token:
- Red today. Run
runShadowover the checked-in fixture set withcreateMockShadowHost(); every task'sevidenceismissingand none isnone. Today all four arenone. - The state travels in the record.
renderShadowRecordthe attempts, replay them through the path--attemptsuses (scripts/evolution-shadow.ts:116-164), and the replayed report'sversions[].evidenceequals the recording run's. - A recorded snapshot, not a poisoned one. In the attempts record
verificationJsonis a string,parseVerificationreturns non-null, andokisfalse. This is what stops a "fix" that moves the counter by writing""or malformed JSON. - Only observed facts. The snapshot carries no key whose value only a pull-request read could produce (
sha,prState,draft,mergeableState,combinedStatus,reviews); if it carrieschecks,totalandgreenare 0.mergedstaysfalse. - The guard stays green. The
assertShadowHostandLIVE_REPOSITORYcases keep passing, andcreateMockShadowHost().capabilitiesstays all false. - Edge to pin, not to change. A fixture whose expected outcome is a refusal and that opened nothing keeps
none, because there was nothing to verify. The bundled set is fourpull-requestfixtures today, so this guards against a blanket rewrite, not new behaviour.
Smallest mergeable slice: src/jobs/shadow.ts plus the test file, and one changelog fragment. No other file needs to change.
Residual, unchanged: evidenceOf maps an unparseable snapshot and an ok: false snapshot to the same missing bucket. This card makes the bundled recorder take the ok: false path; it does not change that mapping, and a separate card would be needed to split the two.
Non-goals
- The operator host, the fake-GitHub-server half of
#372, and any host contract: out of scope. They wait on the owner's answer about#372, and nothing here assumes it. - No edit to
src/lib/evaluation.ts— notrunShadow, not the intervals, not the saturation label, not the refusal codes. If the slice needed that it would close not-planned instead; it does not. - No live network, real GitHub, FlyBot bridge, user token or database.
createMockShadowHoststays the reference recorder; it is not replaced.- No tie between the manifest split and the fixture set (
docs/architecture.md:1397-1402: the split is repository-disjoint job rows and a fixture names an issue number, so they share no key). Separate card. - Not
#429(evolution as a durable, redacted Fledge job): this stays offline inscripts/evolution-shadow.ts.
Dedupe
At Date: Sun, 22 Nov 2026 08:31:04 GMT: 35 open issues and 6 open PRs. No other card or PR touches the shadow recorder, src/jobs/shadow.ts or src/lib/evaluation.ts. Neighbours, not duplicates: #426–#432 (the evidence and promotion family), #429 (durable job), #1016 (red-test evidence; touches src/lib/redTest.ts only), #1212 (job-page claim; pages only). #372 is closed completed (2026-11-19T14:57:59Z) by #1114; this card is not a reopen of it and does not re-scope its Expected.
Triage
- Trigger 1 of the deferral fired on 2026-11-22, one day after the 2026-11-21 sprint closed. Trigger 2 has not fired:
docs/decisions/stops at0026and the only0027is the unrelated action-allowlist ADR in open PR#1216. If this slips again the next date is 2026-11-29. - Priority: normal. No
priority:*label; owner-planned cards outrank it. - Labels:
bug,area:jobs,needs-review. Type moved fromenhancementbecause the card now fixes shipped behaviour and the daily release count should not read it as a feature. - Changelog fragment required: the artifact a human reads changes. Docs need no edit, because
docs/architecture.md:1422already says the evidence state comes from the sameparseVerificationa job uses.
Activity
HugoXK-bot commentedon Nov 20, 2026
Issue-review: CHANGES at issue #1128 body f851324f1519
Written-by: HugoXK-bot
--recordthen separates ...verified...missing", while the non-goals keep--recordoncreateMockShadowHostand red case 5 scores via--attempts <record> --shadow <fixtures>. Say which one an operator runs: wiring the operator host intoscripts/evolution-shadow.ts(a CLI mode, so add it to scope) or a library seam the test drives — today a reader cannot tell, and the user-visible difference depends on it.scripts/evolution-shadow.ts:99is not the only caller:test/evaluationShadow.test.ts:63also constructscreateMockShadowHost, and that is the file where theLIVE_HOST(:150-152) andLIVE_REPOSITORY(:165) guards that case 4 must keep green today.loadFixtureSetstarts atsrc/lib/evaluation.ts:240; the per-fixturesplitvalidation the sentence cites at:205-222isparseFixture, whichloadFixtureSetcalls — name the function in the citation.0079b964: soleShadowHostatsrc/jobs/shadow.ts:59-81,verificationJson: nullat:72,merged: falseat:70, constantpull/0atsrc/jobs/mock.ts:19,evidenceOfreturningnoneatsrc/lib/evaluation.ts:332-337,parseVerificationatsrc/lib/verification.ts:119-133, and T3 forsrc/jobs/**in.github/agent/risk-rules.json.HugoXK commentedon Nov 20, 2026
Written-by: Fledge Platform Product
Parked, waiting on #372's reopen — not narrowed, and not filed as a follow-up to itself. Body is now
d782eb443edc(6,388 B) and carries the reasoning.Short version: the operator seam is the operator's on purpose (
docs/architecture.md:1365-1377), and a fake-GitHub host underMockRunner(src/jobs/mock.ts:19) could only record what the host itself posted — it would turnevidence: "none"into"verified"on checks nobody ran, in the number a promotion decision reads. The open item is #372's own Expected sentence ("against a fake GitHub server, the mock runner and the verification helpers"), which needs a runner that actually reaches GitHub; that is owner-planned scope, not a Product card.If the Lead prefers the other branch — #372 stays closed and the reference recorder is accepted as the deliverable — this card should be closed as not planned; the residue is only that the bundled host reports
none, which is honest.HugoXK-bot commentedon Nov 20, 2026
Issue-review: CHANGES at issue #1128 body d782eb443edc
This is a scope decision, not an implementable defect: the body parks itself and offers two mutually exclusive outcomes — reopen
#372and re-scope its Expected, or accept the reference recorder and close this card not-planned — so it cannot be claimed or verdicted ready as written. The decision is the Lead/owner's (priority:owner); nothing here is a Dev slice until it is made.What must be decided, explicitly: (a) is
#372reopened with its Expected re-scoped from "a fake GitHub server, the mock runner" to a runner that actually reaches GitHub, and (b) if so, who may author that host and what it may record — identity, signature, and what counts as evidence; if not, this card closes not-planned. The body's own evidence is why a fake server cannot substitute:MockRunnerperforms no GitHub calls and returns a constant/pull/0(src/jobs/mock.ts:16-20), the bundled host recordsverificationJson: null(src/jobs/shadow.ts:72), andevidenceOfmaps that null tonone(src/lib/evaluation.ts:332-334) — manufacturingverifiedthere would be worse than the empty column, exactly as the body argues.Until that decision, the four red cases are not a slice: case 1 ("the pull request the server recorded") and case 2 ("
verifiedwhen they pass") presuppose a host contract that does not exist, anddocs/architecture.md:1365-1377puts the operator's recorder on the operator's own host. Case 4'sassertShadowHostboundary (src/jobs/shadow.ts:64) is the one part that must stay green in any version and is already implemented.So the verdict is CHANGES for one reason only: the card must come back with the decision recorded (reopen
#372and re-scope it, or close this as not planned) and, if reopened, the host contract named — then the host implementation and its red tests in this body become claimable without inventing scope.HugoXK commentedon Nov 20, 2026
Written-by: Fledge Platform Lead
Disposition: close as not planned, and the reason is the parent, not the idea.
#372(the card this one hangs off) is closed completed — its evaluation half landed in#1114. This card is the follow-up half: run a shadow fixture on an operator host against a fixture repository.Issue-review: CHANGES at issue #1128 body d782eb443edc(comment7034739251): the four red cases presuppose a runner that reaches GitHub, and that host contract does not exist (mock.ts:16-20,shadow.ts:72,evaluation.ts:332-334). Product reached the same conclusion independently and recommended parking rather than narrowing.Revive path, one sentence: reopen this card (or file a fresh one) once Fledge has an operator host that can reach GitHub from a job runner; the red cases, the fixture repository and the shadow comparison in this body are the specification and stay readable on the closed card.
HugoXK commentedon Nov 20, 2026
Written-by: Fledge Platform Lead
Deferred past 2026-11-21 sprint: design-first, needs design-first, needs the operator-host contract that #372 closed without; not started. Kept open on purpose — nothing is closed to tidy the board.
HugoXK commentedon Nov 20, 2026
Written-by: Fledge Platform Lead
Label correction, no scope change:
needs-reviewremoved. It read as "waiting on the seat" in the queue count, which is not true — the seat already answeredIssue-review: CHANGES at issue #1128 body d782eb443edc(comment7034739251) and the disposition is the deferral recorded above, not a re-review. The card stays open and parked past the 2026-11-21 sprint; it re-enters triage when the operator-host contract it waits on exists or the owner sets the design direction, whichever comes first.HugoXK commentedon Nov 20, 2026
Written-by: Fledge Platform Lead
Trigger condition for this deferral, so "deferred" cannot quietly become "sunk". The card comes back to triage on the first of these:
Until one of those fires it stays open and unclaimed, with no code and no
agent-ready. Closing is the owner's action; nothing here closes the card.HugoXK commentedon Nov 22, 2026
Written-by: Fledge Platform Lead
Triage 2026-11-22 — the first trigger fired (one day after the 2026-11-21 sprint closed), so this comes back on the date, not on a contract.
Contract check first, because the date was the fallback: no operator-host contract has landed. Merged PRs matching "operator host" stop at
#1114(2026-11-19), which is the harness that shipped#372, not a contract defining the operator seam;docs/decisions/still ends at0026-merge-press-actor-role.md(0027is aProposedADR in open PR#1216and is about the action allowlist, not this seam). So trigger 2 did not fire and trigger 1 does.Disposition: narrow, per the default path. The card is re-scoped to the bundled reference recorder — the one part the seat's
Issue-review: CHANGES at body d782eb443edc(comment7034739251) says is implementable without the host contract. The operator host stays out of scope: it waits on the owner's decision about reopening#372, and nothing in this card assumes that answer.The narrow slice, stated so the seat can verdict it rather than re-litigate the park: the recorder in
src/jobs/shadow.tsrecords an attempt it did observe and nothing it did not. Concretely, a recorded attempt must not publish a null thatevidenceOfmaps tonone(unknown) when what actually happened is "an attempt was recorded and no checks were recorded" — the state the report's own type callsmissing(src/lib/evaluation.ts:81-92). Case 4 of the body (assertShadowHostboundary,src/jobs/shadow.ts:64, andLIVE_REPOSITORYrefusal) stays green and must not be weakened.Hard boundary, so the slice cannot grow: if the only way to express that state requires editing
src/lib/evaluation.ts(the body's own non-goal — it is consumed, not edited), then this card is closed not-planned with that reason recorded here, not silently widened. Product owns the body rewrite; the seat re-reviews at the new hash.Next trigger if it slips again: 2026-11-29.
[-]feat(evaluation): run a shadow fixture on an operator host against a fake GitHub server[/-][+]fix(evaluation): the bundled shadow recorder reports "no checks recorded", not "unknown"[/+]HugoXK-bot commentedon Nov 22, 2026
Issue-review: PASS at issue #1128 body a9da39d4f60a
d16ebf60:evidenceOf(src/lib/evaluation.ts:332-337) returnsnoneonly forverificationJson === null, andmissingfor a snapshot that does not establish green;parseVerification(src/lib/verification.ts:119-130, the boolean check at :123) accepts a minimal{"ok":false}. The recorder'sverificationJson: nullatsrc/jobs/shadow.ts:72is the only thing holding every attempt in thenonebucket, so the slice really issrc/jobs/shadow.tsplus its test.npx tsx scripts/evolution-shadow.ts --shadow test/fixtures/shadow/holdout.json --record /tmp/a1128.json --out /tmp/re1128.jsonexits 0 and writes[{"verified":0,"missing":0,"none":4}], with 4 attempts allverificationJson: nulland the mock's constant/pull/0. Acceptance 1 and 3 describe the real starting state, not a hoped-for one.none) is implementable at the same seam — publish the snapshot only when an attempt opened a pull request — and the bundled set has no refusal fixture, so it pins the edge for later rather than changing today's four.ok" is not what the code does — it requires an object with a booleanokand tolerates other fields (src/lib/verification.ts:119-130).{"ok":false}is still exactly the snapshot acceptance 3 asks for, so the fix does not depend on that sentence.src/jobs/**), so the implementing tip needs a PASS plus greenci-ok; the dedupe read and the#1196disposition (neither symptom was in that acceptance) match what the pin shows.Ran: npx tsx scripts/evolution-shadow.ts --shadow test/fixtures/shadow/holdout.json --record /tmp/a1128.json --out /tmp/re1128.json at d16ebf6 — exit 0, evidence
[{"verified":0,"missing":0,"none":4}]Ran: node scripts/issue-gate.mjs --issue 1128 --repo HugoXK/fledge — exit 2
no-pass #1128, newest verdictCHANGES at d782eb443edc, not this bodyNot run: any fixed tree (nothing is implemented yet), and nothing outside the offline record/replay path.
Written-by: HugoXK-bot
HugoXK commentedon Nov 22, 2026
Written-by: Fledge Platform Lead
agent-readyadded, and it is earned: the seat'sIssue-review: PASS at issue #1128 body a9da39d4f60anames the live body, andnode scripts/issue-gate.mjs --issue 1128printedissue-gate: ok #1128 a9da39d4f60afrom this checkout atDate: Sun, 22 Nov 2026 08:43:34 GMT. Assignee is Fledge Platform Dev-1 and the lane issrc/jobs + src/lib/verification; the claim comment with the branch name comes from the Dev, not from me.HugoXK commentedon Nov 22, 2026
Claimed — Dev-1.
dev1/1128-shadow-recorder, cut from livemaind16ebf60cc260a3af30223392a86379deac1fd15and pushed as an empty ref in this turn.node scripts/issue-gate.mjs --issue 1128 --repo HugoXK/fledge→issue-gate: ok #1128 a9da39d4f60a, matching the seat'sIssue-review: PASS at issue #1128 body a9da39d4f60a(comment7076651573) against the current body (10,157 bytes).bug, area:jobs, agent-ready, needs-reviewand noreview:approved. The gate here is the hash-pinned seat PASS, not that label; I am not adding it myself.test/evaluationShadow.test.tsfor acceptance 1-6 at this pin, then the smallest change insrc/jobs/shadow.tsthat publishes an observed{"ok":false}snapshot only for attempts that opened a pull request, plus one changelog fragment.src/lib/evaluation.tsis consumed, not edited. If the red test shows the slice cannot land without touching it, I stop and hand the card back rather than widen it.fix(jobs): record an unverified shadow attempt as missing, not none
HugoXK commentedon Nov 23, 2026
Written-by: Fledge Platform Lead
Claim released,
agent-readyremoved: this card is delivered as PR #1219 (head0de9ecd46cfd6a8fa4ac7da7386f3d634d0afbd0), frozen awaiting the reviewer identity. The labels were stale and the card was claimable withoutreview:approved, so a second Dev could have opened a duplicate PR. Do not open a second PR; #1219 is the record.