Repository navigation
Keep a turn's scroll request when its link resolves again - #483
Merged
Merged
Conversation
When a pending link resolves again because its patch or session arrived, every step is applied again, and the turn step asked the session's turn list to scroll once more. With a cached session the list had already scrolled to the turn, so the second ask pulled the pane back to it even if the reader had moved while the diff loaded. A link resolved again now keeps turnScrollRequest when it names the same turn: the list waits for the turn, so the first ask is enough. Found by Codex's second review of #482. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.

Follow-up to #481 and #482, which merged before Codex's second-round finding was fixed.
When a pending link resolves again because its patch or session arrived,
openedFromapplies every step again, and the turn step bumpedturnScrollRequest. If the session was already loaded, the turn list had already scrolled to the turn, so the new request pulled the session pane back to it even if the reader had scrolled away while the diff loaded. A link that resolves again now keeps the request ID when it names the same turn. The list waits for its target, so the first request is enough. A new link still makes a new request.Tests
links-open.test.ts: a turn that waited for its session keeps request 1 after the session arrives. With the fix removed, it fails with 2.Review by Codex
No findings. It checked that a link resolving again keeps the request for the same turn, and that opening the link again still makes a new one.
🤖 Generated with Claude Code