Skip to content

docs(phi-scan): the branch-and-merge fixture went red on a committer identity, not an empty index - #111

Merged
NSchatz merged 1 commit into
mainfrom
docs-unmerged-fixture-red-cause
Aug 11, 2026
Merged

docs(phi-scan): the branch-and-merge fixture went red on a committer identity, not an empty index#111
NSchatz merged 1 commit into
mainfrom
docs-unmerged-fixture-red-cause

Conversation

@NSchatz

@NSchatz NSchatz commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

What

Deletes one false clause from the two carriers that explained why the first (branch-and-merge) version of the unmerged-index fixture went red in CI, and states the measured cause instead.

Both carriers said the run came back with no records for the path at all:

  • documentation/agent-notes.md
  • test/scripts/phi-scan.test.ts (comment)

Why it is false

The red run (31478670886, both runners) printed:

AssertionError: expected [ Array(1) ] to have a length of 3 but got 1

One record, not zero. It is also impossible on its own terms: the gitIn calls above the merge assert exit 0 on git add c.xml and on all the commits, so a stage-0 record necessarily existed.

The real cause

The draft handed its git merge no committer identity (the commits got one via -c, the merge did not). A merge with no resolvable identity dies before it touches the index, leaving the ordinary stage-0 record the last commit wrote. Reproduced here: exit 128, Committer identity unknown, one stage-0 record, for both conflicting and cleanly-auto-merging sides.

The premise assertion expect(merged.status, "premise: the merge really conflicts").not.toBe(0) passed on that 128. A premise assertion that accepts any non-zero exit accepts a crash - that is the transferable lesson the false clause was displacing, and repoWithConflict already hands its own merge an identity for exactly this reason.

Also

Drops "so the next failure names its own cause" from the same paragraph. The premise captures listed.stdout only and never its status or stderr, unlike every other call in the case, so a failing ls-files still hides its own cause. Disclosed, not grown: the assertion is deliberately unchanged.

Scope

No behavior change. scripts/phi-scan.ts, the fixture and every assertion are byte-identical; the test-file edit is comment text only. CLAUDE.md untouched.

conformance-refuter ran and returned REFUTED on the first draft of the replacement prose (two introduced claim defects: a wrong statement that the file never passes identity to a merge, and a prose record count). Both were cut and re-checked against the file and the CI log firsthand before this commit.

…identity, not an empty index

The note and the test comment covering the unmerged-index case both explained
the red CI run as `git ls-files -s` coming back with no records for the path at
all. Measured FALSE. The run's own output reads `expected [ Array(1) ] to have a
length of 3 but got 1`, and the `gitIn` calls above it assert exit 0 on the add
and on the commits, so a stage-0 record necessarily existed.

The draft handed its `git merge` no committer identity. The merge died before it
touched the index and left the ordinary stage-0 record the last commit wrote,
and the premise assertion, `.not.toBe(0)` written to mean "the merge really
conflicts", accepted that crash as a conflict. A premise assertion that accepts
any non-zero exit accepts a crash, which is the transferable lesson the false
clause was displacing.

Also drops "so the next failure names its own cause" from the same paragraph:
the premise captures `listed.stdout` only and never its status or stderr, so a
failing `ls-files` still hides its own cause. Disclosed, not grown.

No behavior change. `scripts/phi-scan.ts`, the fixture and every assertion are
byte-identical; the test edit is comment text only.
@NSchatz
NSchatz merged commit 498ef6d into main Aug 11, 2026
8 checks passed
@NSchatz
NSchatz deleted the docs-unmerged-fixture-red-cause branch August 11, 2026 10:20
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