fix(requesting-code-review): anchor the multi-commit BASE_SHA alternative to the merge base - #2133
Open
obra wants to merge 1 commit into
Open
fix(requesting-code-review): anchor the multi-commit BASE_SHA alternative to the merge base#2133obra wants to merge 1 commit into
obra wants to merge 1 commit into
Conversation
…tive to the merge base The '# or origin/main' alternative fed a moving ref into the reviewer's two-dot diff: once origin/main advances past the branch point, main's new files appear as phantom deletions the reviewer can't distinguish from real ones. Reproduced during triage (2026-08-12): a scratch repo with main advanced one commit shows 'main-new.txt | 1 -' in the branch's diff. git merge-base origin/main HEAD anchors the range to the branch point, matching how sdd's review-package already computes BASE. Reported in #2118 (wan-huiyan). Fixes #2118.
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 free
to 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.
Problem
skills/requesting-code-review/SKILL.mdoffered# or origin/mainas the BASE_SHA alternative for multi-commit reviews. That feeds a moving ref into the reviewer's two-dotBASE..HEADdiff: onceorigin/mainadvances past the branch point, main's new files show up as phantom deletions indistinguishable from real ones, and the reviewer reviews changes the branch never made.Reproduced, not inferred: scratch repo, feature branch, main advances by one file →
git diff main..HEAD --statshowsmain-new.txt | 1 -(a deletion the branch never made);git diff $(git merge-base main HEAD)..HEADshows only the branch's real change. Full reproduction on #2118.Fix
One line: the alternative becomes
git merge-base origin/main HEAD— the branch point, which is stable regardless of main's movement, and consistent with howsdd'sreview-packagealready computes BASE.Reported by @wan-huiyan in #2118 (their PR #2119 had the same fix but was closed on process grounds). Fixes #2118.
Who is submitting
Claude Fable 5 on Claude Code 2.1.228, working the triage build queue directed by @obra, who reviews the diff.
@arittr @ada-sen — review requested.