Repository navigation
Conversation
Git writes a file turning into a symlink as a deletion and an addition of the same path. The pull request Code tab ordered diff blocks through a map keyed by path, so the addition overwrote the deletion and the removed contents never showed. Group blocks by path, order the paths as before, and emit every block of a path in patch order.
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — This is a small, self-contained web bug fix that preserves existing diff ordering while retaining both blocks of file-to-symlink changes. Focused tests cover the affected representation and import ordering, with no production configuration, schema, security, or deployment impact. You can add or adjust custom eligibility rules. Learn more. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: pingdotgg/t3code/.coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review. 📝 WalkthroughWalkthroughThe diff ordering logic now preserves multiple blocks for the same path, reads imports from all owned blocks, and returns blocks in patch order. Tests cover symlink conversion ordering, unique render keys, and imports found in deletion lines. ChangesDiff block ordering
Priority: ⬇️ Low Estimated code review effort: 3 (Moderate) | ~20 minutes Change: Bug fix Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
Note This comment is posted by Julius' dot Closing for missing UI verification. The tests show that both diff blocks survive ordering, but the PR supplies no before/after capture of the Code tab displaying the previously missing deletion. Add those screenshots and the observed client result, then request reconsideration. |
|
Note 🤖 Claude Fable 5.1 on behalf of Mnigos Added the missing verification to the description: before/after screenshots of the Code tab on macOS (headless Chromium 1400×900) using a draft PR on my fork that replaces |
When a pull request turns a file into a symlink (or back), Git writes the change as two blocks for the same path: a deletion of the old file and an addition of the new one. The Code tab orders diff blocks with
orderDiffFiles, which indexed them in aMapkeyed by path, so the second block overwrote the first and the deleted contents never appeared in the review. #11075 made those two blocks render safely; this is the remaining place that still assumed one block per path.orderDiffFilesnow groups blocks by path, orders the paths exactly as before, and emits every block of a path in patch order. Import detection reads the lines of all blocks a path owns.Tests:
pullRequestFileOrder.logic.test.tsgains two cases. One parses a real deleted-plus-symlink patch and asserts both blocks survive with distinct render keys; the other covers imports spread across two blocks. Both fail onmain(['AGENTS.md:new', 'src/b.ts:new']instead of the deleted block first) and pass here, along with the existing 15. Targeted lint and web typecheck are clean. The change is pure ordering logic, so there is no visual diff beyond the previously missing block showing up.Evidence
Captured in the web client on macOS 15.7.5 (Playwright, headless Chromium 1400×900) with a temporary draft PR on my fork that replaces
LICENSEwith a symlink toREADME.md, viewed in the PR panel's Code tab (All commits, stacked layout, hunks expanded, light appearance). Before is today'smain(5cc99e1), after is this branch (413da8b); both panels are cropped identically.Observed: on
mainthe Code tab lists one block forLICENSE, the added one-line symlink, and the 21 deleted lines never appear. On this branch the deletedLICENSEblock renders first, followed by the added symlink block, matchinggh pr diff. The tab's counter reads "2 files" for the two blocks of that path while the PR header reads "1 file"; that counter counts diff blocks and is unchanged by this PR. Desktop and mobile clients were not exercised; the ordering logic is shared.Implemented with Claude Code (Claude Fable 5.1).