Skip to content

Disclose scope exclusions on the receipt; pin the harvested input - #4

Merged
joshft merged 2 commits into
masterfrom
scope-exclusion-disclosure
Aug 17, 2026
Merged

Disclose scope exclusions on the receipt; pin the harvested input#4
joshft merged 2 commits into
masterfrom
scope-exclusion-disclosure

Conversation

@joshft

@joshft joshft commented Aug 17, 2026

Copy link
Copy Markdown
Owner

Closes the external review's "blind spots are always stated" violation: the change resolver's deliberate exclusions (never-tracked top-level trees, hidden untracked paths) happened before coverage could see them, so no part of the receipt could state them. Now the scope boundary itself does:

  • ChangeRef.Excluded (schema 0.0.6): reason, count, and affected top-level trees — counts, not paths, because the measured case was 2,000+ cache files and listing them would reproduce the noise the rule exists to exclude. Rendered under the change line in both formats, including the "invisible until first git add" trade-off.
  • ChangeRef.InputDigest: SHA-256 over the exact harvested content (sorted path + per-file content hash, deletions marked absent; formula documented for independent recomputation). Commit SHAs identify only committed state — this pins the mid-branch receipts that harvest staged/unstaged/untracked work.

Measured live before the PR: on a real dogfood repo with an installed tool's cache tree, the receipt now discloses "scope excluded 2135 untracked file(s) in never-tracked top-level trees (...) · 14 hidden untracked file(s)" where it was previously silent, and the input digest renders beside the SHA pins.

What the receipt cannot check here: the live measurement above ran on a repo outside this one.

🤖 Generated with Claude Code

https://claude.ai/code/session_015GeUG1gboWiZSnFyzQghyp

joshft and others added 2 commits August 17, 2026 10:12
The change resolver deliberately excludes two classes of untracked file
(never-tracked top-level trees, hidden paths). Excluded files never
reach the harvest, so the coverage section cannot account for them —
the exclusion happened before coverage could see it, in conflict with
"blind spots are always stated". The scope boundary now states its own:
ChangeRef.Excluded carries reason + count + affected top-level trees
(counts, not paths — the measured case was 2,000+ cache files, and
listing them would reproduce the noise the rule exists to exclude),
rendered beside the file count in every format.

ChangeRef.InputDigest closes the sibling identity gap: commit SHAs only
identify committed state, but a mid-branch receipt harvests staged,
unstaged, and untracked work. The digest (sorted path + per-file
content SHA-256, deletions marked absent — formula documented so anyone
can recompute it) makes dirty-tree receipts reproducible and
comparable.

Schema 0.0.6: ChangeRef gains excluded and input_digest.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015GeUG1gboWiZSnFyzQghyp
A GitHub API outage during comment posting failed the job before the
Gate step ran, even though the receipt was clean (20/20 verified). The
comment is a delivery channel, not the contract: the Gate step carries
the verdict, and the receipt is also in the job summary and log —
continue-on-error keeps the outage visible as a step annotation without
letting it masquerade as a receipt failure.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015GeUG1gboWiZSnFyzQghyp
@github-actions

Copy link
Copy Markdown

correctful receipt

20 claims — ✅ 20 verified · ❌ 0 refuted · ⚠️ 0 unverified

Change: origin/master...HEAD (77a37fe..32f61cc · input:c024d79b8675) — 9 files

⚠️ Unverified remainder (0) — what nothing checked

Empty — every harvested claim reached a probe.

✅ Verified (20)
Tier Claim Statement
T1-assertion TestDetectBaseFallsBackToLocalDefaultBranch Detect Base Falls Back To Local Default Branch
T1-assertion TestDetectBaseHonorsCIBaseRef Detect Base Honors CIBase Ref
T1-assertion TestDetectBaseFailsLoudWithNoCandidate Detect Base Fails Loud With No Candidate
T1-assertion TestTrackedByPattern Tracked By Pattern
T1-assertion TestPatchCarriesCommittedAndUncommittedHunks Patch Carries Committed And Uncommitted Hunks
T1-assertion TestResolveIncludesUntrackedButNotHiddenState Resolve Includes Untracked But Not Hidden State
T1-assertion TestInputDigestPinsWorkingTreeContent Input Digest Pins Working Tree Content
T1-assertion INV-001 Remainder Contains Every Unverified Claim
T1-assertion INV-002 Refuted Claim Never Enters Remainder
T1-assertion TestVerifiedClaimCarriesProbeTier Verified Claim Carries Probe Tier
T1-assertion INV-007 Refutation Dominates Verification
T1-assertion TestT0PassConfersNoVerification T0 Pass Confers No Verification
T1-assertion TestScopeExclusionsAndInputDigestAreDisclosed Scope Exclusions And Input Digest Are Disclosed
T1-assertion TestSuppressedMentionsAreDisclosed Suppressed Mentions Are Disclosed
T1-assertion TestRemainderSectionAlwaysRenders Remainder Section Always Renders
T1-assertion TestCoverageDisclosesUnreadFiles Coverage Discloses Unread Files
T1-assertion TestAnchoringSummaryAndMarkers Anchoring Summary And Markers
T1-assertion TestLLMProposedMarker LLMProposed Marker
T1-assertion TestRefutedDetailComesFromFailingProbe Refuted Detail Comes From Failing Probe
T1-assertion TestReceiptSanitizesPathsAndPinsSHAs Receipt Sanitizes Paths And Pins SHAs

Harvest coverage: 9 files — 3 claimed · 5 scanned · 1 unread
unread (no harvester for): .yml×1
2 spec-id mention(s) not minted as claims — the repo defines no spec-id corpus, so a reference has no possible referent

schema 0.0.6 · exit gate: refuted claims block; the remainder informs, never fails

@joshft
joshft merged commit d304477 into master Aug 17, 2026
1 check passed
@joshft
joshft deleted the scope-exclusion-disclosure branch August 17, 2026 17:17
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