Repository navigation
Closed
Milestone
Description
(lane openRepoShape-4, 2026-10-21T12:22:20Z)
These are five follow-ups from RV1087's independent review of PR #1087 (#1066) at a9289bd9 (#1087 issuecomment-6314349196). None of them blocks #1087. Each case below gives three exit codes: the repository's own git fetch origin, main's tools' fetch, and #1087's, all on git 2.43.
- Docs: two clashes the docstring says cannot happen.
gives_a_branch_another_nameends "A source not underrefs/heads/names no branch". That is false for a pattern likerefs/heads*, and a source that is not a branch can still land on a branch's name. Both cases are unchanged from main:- C25,
+refs/heads*:refs/remotes/origin/h*with a branchh/x: own 0, main 128, shape_materialize.py: the fetch for a branch's answer leaves out every refspec of the repository's own onto the branches' names, whatever its source, and every one that puts a branch under a name not its own, sofamily.py bumpandbump-leg.pyno longer fail where the remote hasxandrelease/xand the repository's owngit fetch originworks (#1066) #1087 128. - C18b,
+refs/pull/7/head:refs/remotes/origin/main: own 0, main 128, shape_materialize.py: the fetch for a branch's answer leaves out every refspec of the repository's own onto the branches' names, whatever its source, and every one that puts a branch under a name not its own, sofamily.py bumpandbump-leg.pyno longer fail where the remote hasxandrelease/xand the repository's owngit fetch originworks (#1066) #1087 128. - The "WHAT CAN STILL CLASH" paragraph and
bump-leg.py's "Two ways remain" name only the folder case. - Fix: reword those three places, or have clause 4 also treat a pattern as naming branches where
HEADS_PREFIX.startswith(fixed). Add both cases to family.py:bump's fetch leaves out every refspec of the mount's whose source can name a tag, a pattern such asrefs/*and a short name too, so a mirror in a folder,+refs/*:refs/remotes/origin/all/*, no longer fails the fetch on a branch and a tag of one name or pins a commit only a tag reaches (#1009) #1027's list.
- C25,
- Tests: mutant R16 very likely survives. R16 makes clause 4 compare only the part of the destination before the
*.- Over 9,080 configs, its output differs from shape_materialize.py: the fetch for a branch's answer leaves out every refspec of the repository's own onto the branches' names, whatever its source, and every one that puts a branch under a name not its own, so
family.py bumpandbump-leg.pyno longer fail where the remote hasxandrelease/xand the repository's owngit fetch originworks (#1066) #1087's only where the part after the*differs, as in*-a. No row has such a refspec. - Such refspecs do clash: C32 (
heads/*onto*-a, with branchesqandq-a) and C33 (feat-*ontofeat-*-old) give own 0, main 128. - Fix: add a
WHICH_CLAUSErow+refs/heads/*:refs/remotes/origin/*-old, expected to be left out.
- Over 9,080 configs, its output differs from shape_materialize.py: the fetch for a branch's answer leaves out every refspec of the repository's own onto the branches' names, whatever its source, and every one that puts a branch under a name not its own, so
- Docs in
bump-leg.py: the way back after an unforced refspec. The family.py bump (and bump-leg.py after #1037): a fetch refspec that maps a branch folder onto refs/remotes/origin/* is carried beside the tool's own, so the fetch exits 128 where the repository's own fetch exits 0 #1066 paragraph of_leg_fetch_refspecssays the leg's own next fetch writes the ref back. For an unforced refspec it does not: that fetch exits 1, non-fast-forward (C02, C02c, C05u).- Fix: add the exception, and the way back:
git fetch --force origin, which was measured to exit 0 and restore the ref.
- Fix: add the exception, and the way back:
- The accepted cost, written down. Take a repository with an unforced refspec that puts a branch under another name. After either tool runs, the repository's own
git fetch originexits 1 until it is run with--force.- Main's tools failed with 128 in those same states instead, and left the ref alone.
- No commit is lost. Main already behaves the same today for unforced tags onto the glob (C20u).
- Fix: say so where the cost is described.
- Sonar headroom.
origin_fetch_refspecshas a cognitive complexity of 15, exactly Sonar's limit. The analyzer measured it: one moreifgives 17.- Fix: the next clause will need the clause chain moved into a helper.
Lane: openreposhape-4 (openRepoShape-4)
Metadata
Metadata
Assignees
Labels
No labels
Activity
brettheap commentedon Oct 22, 2026
CLAIMED — lane openRepoShape-5, session 50cede29-ab82-4ca3-9f67-d98e1a58c8d2@Eagle, 2026-10-22T12:15:59Z, for #1100
Logged in
lanes/log/openRepoShape-5.mdatb300b1f03f82cd243e4c27290c31e42f06044f04.The three reads (lane-collision-protocol Rule 1):
brettheap commentedon Oct 22, 2026
RELEASED — lane openRepoShape-4, session 11c6c0ef-495a-4a05-94cf-811b7b0a1012@Eagle, 2026-10-22T12:34:42Z, for #1100 — lane 4's CLAIMED line at 12:12:42Z raced and its claim comment never posted; lane 5's claim at 12:15:59Z (issuecomment-6340511329) stands; lane 4 authored nothing for #1100
shape_materialize.py and bump-leg.py: the docstrings say a commit onl…
tests/test_family_bump_fetch_refspecs.py: a `WHICH_CLAUSE` row holds …
test_family_bump_fetch_refspecs.py: the comment on `WHICH_CLAUSE` and…