Uh oh!
There was an error while loading. Please reload this page.
fix(pm): split the governed-merges attribution column three ways - #12658
Merged
Conversation
A PR-less mainline entry — the loudest line the sweep prints — rendered "merged_by UNAVAILABLE — every channel failed; see the attribution note below" when zero channels had been tried: `main()` skips an entry with no PR number (there is no pull request to query), and the column was picked on `entry.attribution` alone. The note it pointed at is never produced for such an entry either, since `summariseAttributionFailures` groups only entries carrying `attributionError`. The column now reads: resolved · UNAVAILABLE, every channel failed (an `attributionError` is present — the only case that may point at the note) · NOT LOOKED UP, with the reason read off the entry rather than assumed. Report-only: no judgment moves. `attributionFailed` and the INCOMPLETE exit are still driven by real channel failures alone, and the direct-push warning on a PR-less entry is unchanged. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MnijPVVDakqK2J335JoJtq
os-litant
marked this pull request as ready for review
August 27, 2026 05:09
Uh oh!
There was an error while loading. Please reload this page.
This was referenced Aug 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes#12645
The attribution column was picked on
entry.attributionalone, so it coveredthree facts with two words. The entry that fell through the gap is the loudest
line the sweep prints: a mainline commit whose subject names no PR.
main()skips it deliberately —
if (entry.pr == null) continue;— because there is nopull request to query, so zero channels were tried, and the column said
every one of them had failed. It also referred the reader to "the attribution
note below", which
summariseAttributionFailuresnever produces for such anentry: that function groups only entries carrying
attributionError, and thisone carries none.
Reproduction — the card's constructed sweep, before and after
A governed PR-less mainline entry, zero API lookups, rendered through
renderReport(no network, no checkout). The0 API lookup(s)line is printedfrom the same report, four lines above the entry.
Before (
de4733663, currentorigin/mainat branch point):After:
The change
A new pure exported helper,
attributionCell(entry), following this file'sestablished shape (
describeWindow,windowEdgeReason,nextRoundRefLine—one pure fragment per report region, so
--self-testasserts on the words):attributionErroris present, sochannels really were tried. This is now the only branch that points at
the attribution note, because it is the only one the note is written for.
entry rather than assumed. An absent PR number is the case
main()produces; an entry that has a PR number yet reaches this branch gets an
honest residual instead of being told it has no PR number. Asserting an
untried channel and asserting an absent PR number are the same defect in
different words, and fixing one by introducing the other would not be a fix.
Report-only, as ruled. No judgment moves:
attributionFailed— and with itthe INCOMPLETE exit — is still set by a real channel failure alone, so a PR-less
entry still does not make the sweep incomplete on attribution grounds. The
--jsonpath emits raw entries and is untouched. The direct-push warning isnot weakened; the header block that states a PR-less commit is more
anomalous than any PR merge now also records why its column reads NOT LOOKED UP.
Assertions added (13;
--self-test193 → 206, all green)Placed beside the two existing fixtures, since the defect was a two-way split
covering three facts and the set is what pins it:
a-pr-less-entry-is-NOT-LOOKED-UP-not-a-failed-lookupand-it-says-WHY-nothing-was-querieda-not-looked-up-entry-points-at-no-attribution-noteand-the-report-prints-none-for-it—summariseAttributionFailuresreallyreturns nothing for the entry, so the dangling pointer is pinned from both ends
the-note-pointer-belongs-to-the-every-channel-failed-case-alonethe-third-case-does-not-soften-the-direct-push-warningand-carries-no-resolved-column-caveatcell-case-1-resolved-names-its-channelcell-case-2-every-channel-failed-needs-an-attributionErrorcell-case-3-no-pr-number-is-nothing-to-querycell-residual-never-invents-a-missing-pr-numberand-the-residual-is-not-a-channel-failure-eithera-resolved-reading-outranks-a-stale-errorVerification
Everything below ran at
8c5717fb5, the final commit on this branch, underthe shared verify lock.
node scripts/pm/check-governed-merges.mjs --self-test— its own printedverdict line:
Reverse verification (expected direction: RED). The fix was committed first,
so the restore leg has a real reference point. The mutation reverted the call
site to the pre-fix two-way ternary; it was proved on disk before anything
was read — deleted-text count 0, injected-text count 1, and the on-disk blob
a7e619a8…differing from the HEAD blob0b534cd4…. The mutated tree failedwith exactly the three rendering pins that route through the call site:
The ten
attributionCellpins stayed green under that mutation, correctly: themutation removed the call, not the helper, so those pins were not exercised by
it. Restore was proved by state rather than by exit code — on-disk blob back to
0b534cd4…andgit diff HEADempty — and the restored tree re-ran green at206. The script carried a
trap … EXIT INT TERMwith absolute paths throughout.No build or
dist/resolution is involved: this module is executed directly bynode from source.
Derived gate union —
node scripts/pm/dispatch-gates.mjs --repo objectstack-ai/objectstack(paths taken by the script from the merge base, nothand-supplied), giving 11 path-matched families plus the 2 convention-triggered
by a gate-script edit. Run with importer siblings (three modules import from
this file) and the universal control-byte gate; 17 of 17 green:
check:pm-dispatch-gatesprinted✓ dispatch-gates self-test: 719 cases pass.and
check:nul-bytesprintedcheck-nul-bytes: OK (scanned 7018 text file(s) … no raw ASCII control bytes); a separate control-byte scan over the edited filefound no hits.
No changeset. This publishes nothing — internal PM tooling, and a pure bug
fix, which AGENTS.md exempts. It is also this file's own convention: none of the
last five commits touching it carried one.
Generated by Claude Code