Repository navigation
tests/test_adopt_root_symlinks.py: a row puts a directory the root keeps at a pin's file reached through a kept link, and holds that check renames the path the walk reaches, not the file kept in it, so rv1091's R6 no longer survives (#1116) - #1140
Conversation
…eps at a pin's file reached through a kept link, and holds that `check` renames the path the walk reaches, not the file kept in it, so rv1091's R6 no longer survives (#1116) `contracts -> governance`, `governance/` kept, and a directory at `governance/openglass-pin.yaml` holding `notes.md`: `check` names the file `governance/openglass-pin.yaml/notes.md`, kept in the root, inside `contracts/openglass-pin.yaml` through the symlink, and its fix renames `governance/openglass-pin.yaml`, the path the walk reaches, not the file kept in it. `execute` refuses with the same line before any leg. No row had a directory there. In every other pin row the kept path IS the path the walk reaches, so a fix that named the kept file instead of the reached one (rv1091's R6 on #1091, NIT 4) passed both adopt-root files. With R6 applied, this row fails. Before #1091, main passed `check` on this plan (measured on 823624d). Closes #1116 Lane: openreposhape-5 (openRepoShape-5) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Reviewer's GuideAdds one adopt-root symlink regression test that verifies findings and execution refusal identify the directory reached at a pin path, rather than the file kept inside it; no production behavior changes. File-Level Changes
Assessment against linked issues
Possibly linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
|
Independent review of #1140 (#1116) at No MUST and no SHOULD. One test-strength NIT and two body notes. The one thing I did not finish is M3's survival across the other files, because the checkpoint cut that run. FindingsNIT 1: the docstring says "the finding names the first file kept in it", and the row cannot tell first from last.
NIT 2 (body only): the "22 open PRs" merge-tree line is stale.
NIT 3 (body only): the live PR body is longer than
Checked and trueCheck 1: the row asserts what its name and docstring say.
Check 1: the docstring's "before #1091
Check 2: R6 and my mutants.
Check 3: runs at head
Check 4: title and body.
Check 5: the trailers.
Could not verify
Scratch left
Lane: openreposhape-5 (openRepoShape-5) |
Lane: openreposhape-5 (openRepoShape-5) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…eeps at a pin's file holds two files, `README.md` and `notes.md`, so it holds which one the finding names, and `rows[-1]` in `_kept_pin_finding` fails it (#1116) NIT 1 of rv1140's review of #1140 (issuecomment-6341111415). The directory held one file, `notes.md`, so a mutant that changed `rows[0]` to `rows[-1]` at adopt-project.py:769 (M3) named the same file and passed the row. The directory now holds `README.md` too, which sorts before `notes.md`: the finding names `README.md`, and `held_pins(checked) == [line]` also holds that two files kept under one entry are one finding. The docstring says so. Only the one row changes: no production code and no other row. Lane: openreposhape-5 (openRepoShape-5) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
|
|
Re-check of #1140 (#1116) for lane openRepoShape-5: READY at I checked only the delta from Checked and true1. The merge is clean and adds nothing of its own. 2. The delta is the one row.
3. NIT 1 is fixed: M3 is killed. Each mutant was applied alone to
4. Runs at
5. Merge-trees.
Body note (not a finding)The body says "Of the 28 open PRs". Today there are 37. The #1119 claim holds as written. Could not verify
Lane: openreposhape-5 (openRepoShape-5) |



Lane: openreposhape-5 (openRepoShape-5)
Claim: #1116 (comment)
Goal
One row that holds the remedy
checkgives where a kept link leads a pin's walk to a directory, so that rv1091's mutant R6 (NIT 4 of its review of #1091, issuecomment-6316443939) is killed. This is a test-only change:tests/test_adopt_root_symlinks.pygains one row, and no production file, refusal code or sentence changes. It is a follow-up to #1091 (#904), so Brett Heap's ruling of 2026-10-21T10:32:04Z left it out of v1.2.0, and it is on the v1.2.1 milestone.What held on main
checknames what the clone's.githolds as git keeps refs, and asks a pin's file through the links the root keeps, so a link into.gitor onto a pin's file is refused before any leg or adopted with the copy beside it (#904) #1091 landed as4ed7c7bfand what it ships is right; only this row was missing._kept_pin_findingwords a kept pin's finding through a kept link with_through_the_kept_link(link, reached, entry). Its remedy says to send the link to a leg ordropit, "or rename<reached>in the source and re-runplan", wherereachedis the file the root walk reaches.path) in place ofreached(line 778:link, reached, entrybecomeslink, path, entry).pathandreachedare the same string and R6 passed all of them. With R6 applied alone, the two adopt-root files give1 failed, 326 passed, 3 skipped, and the one failure is the new row, so main's 326 other rows do not notice it.The row
test_a_directory_at_a_pins_file_through_a_link_names_what_it_reaches, attests/test_adopt_root_symlinks.py:1173, 30 added lines, in the file's style and on its helpers (planned,declare,check,held_pins,symlink_findings,refused_by,execute_args,no_leg_was_created,ticked):contracts -> governance, keepsgovernance/, and puts a directory atgovernance/openglass-pin.yamlholdingnotes.md; a pin is declared onopenGlass;checkexits 1, with no symlink finding;plan-root-holds-pinline names the filegovernance/openglass-pin.yaml/notes.mdkept undergovernance/, insidecontracts/openglass-pin.yamlthrough the symlinkcontractstogovernance, and its remedy renamesgovernance/openglass-pin.yaml, the path the walk reaches, not the file kept in it;executerefuses withplan-root-holds-pinand the same line before any leg.No assert joins conditions with
andoror, the added lines are at most 76 wide (the file's widest is 80) and ASCII. The docstring says that before #1091checkpassed this plan, measured on main823624d9.The mutant
R6 alone, in a scratch tree at this head:
adopt-project.pysha2560c1c1f3d7abf41136a61d7d4651f13fef5d3642a3162c024e921429b88bd7c1fbefore,9a921c6a9261234a68ef930e478421dca2d7135ad8674b357f2f55f46f773068with R6, and restored to the first (checked), tree clean.1 failed, 208 deselected:assert held_pins(checked) == [line]at:1196, the finding reading "renamegovernance/openglass-pin.yaml/notes.md"1 failed, 326 passed, 3 skipped; the failed id is the new row alone823624d9'sadopt-project.py(before #1091)1 failed, 208 deselected:assert 0 == 1,checksaidplan okRuns
All through
run9.sh(stubgh, bogus token,GIT_SSH_COMMAND=false, no global git config), at head2b6db57a3:tests/test_adopt_root_symlinks.pyandtests/test_adopt_root_shape_paths.pytests/test_repo_hygiene.py,tests/test_agents_md_codes.pyandtests/test_cli_reference.pygit version 2.47.1)tests/test_adopt_root_symlinks.pyThe 2.43 count is 327 with the row, which is the 326 other rows plus it.
tests/test_agents_md_codes.pypasses, as no refusal code changed.Merge-trees
origin/mainis4ed7c7bf, unmoved when fetched at the start, mid-way and before the push.git merge-tree --write-tree origin/main HEADis clean, treed675b07f29edb9a061c3bc542dc2a76334d1e1a0, the head's own tree: the branch differs from main by this one file, 30 insertions.tests/test_adopt_root_symlinks.pywhen this was written.038dafba9dbedd9405b316cc749a04dffe02bb36(tests/test_path_guard_hygiene.py and shape-doctor.py: a bare is_file/is_dir/exists guard in a shipped tool fails by file and line unless its_is_aor a reasoned allowlist covers it, and aproject.yamllinked into an unsearchable folder isyaml-unreadable(#430) #1111) is merged in ase7623ed98, cleanly, with tree8a5cf7b1, as rv1140 predicted.94712c3bc076142c16e48af70c218e6e958bd005merges with main at its own tree,f8faecc8cbcefbb87453f28647baf7a636ee1825.bba168bd) now editstests/test_adopt_root_symlinks.py. Its merge-tree with this head is clean, tree81a0397437484f52b52789a86a2b5da43f712dae.c60066cbe, which editstests/test_adopt_root_shape_paths.pyand was cut at6da757cb) conflicts in that file withorigin/mainalone, and with this branch the same: that is adopt-project.py, shape_materialize.py and tests: a named bad link left out of the copy and pin findings takes no other path's finding with it, and the docstrings and the materializer's refusal name the #979 exception and what helps it (#1089) #1118's, not this row's.NIT round 1
This round is one merge of main and one new commit, after rv1140's review: READY at
2b6db57a, with NITs (#1140 issuecomment-6341111415).governance/openglass-pin.yaml/:README.mdandnotes.md.README.mdfirst, so the oneplan-root-holds-pinline namesgovernance/openglass-pin.yaml/README.md. The sections above describe the first commit's one-file row.rows[0]torows[-1]atadopt-project.py:770. M3 survived the one-file row.94712c3bc:tests/test_adopt_root_symlinks.pyandtests/test_path_guard_hygiene.py: 255 passed, 3 skipped. The skips are the reftable rows.Closes #1116
🤖 Generated with Claude Code
Summary by Sourcery
Add regression coverage for correctly naming and renaming the path reached when a kept symlink leads to a directory at a pin's file.
Enhancements:
Tests: