Repository navigation
fix: draw a last-resort thread's part only after the primary's view lands - #7074
Merged
Merged
Conversation
…ands #7046 started revealThread in inPrimary's own task whenever a travelling route found the thread's part undrawn. Where the primary held the thread as the last resort, as the panel holds a reply whose diff file the user left, that drawing gave the thread a seat on the page before the panel's view landed. returnToPage then took the thread back and aborted the route before focus moved, so `g i` left the user on the file tree instead of in their reply. The early drawing now skips a thread the primary holds as the last resort, which draws its part after the view lands, as before #7046. The panel-choice route #7046 fixed still draws in the press's task. test_keyboard_file_navigation_keeps_its_destination_beside_a_retained_reply fails on main and passes here. Closes #7071
This was referenced Nov 24, 2026
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.
test_keyboard_file_navigation_keeps_its_destination_beside_a_retained_replyhas failed onmainsince #7046 (run 45468221584). After the user leaves a reply in a diff seat and moves to another file,g ishould bring them back into the reply. Instead focus stays on the file tree.git bisect runover the test names b39f054 (#7046) as the first bad commit, and the test fails every time onmain.Cause. #7046 had
inPrimarystartrevealThreadin the press's own task, so that under the panel choice a diff's search clears in the press rather than after the route's awaits. While the user is on another file, the panel holds the reply's thread as the last resort.g iasks the panel to show it, and the early reveal now draws the thread's line in the diff before the panel's view has landed. The page drawing the thread sends it back there (returnToPage), which aborts the route before it focuses the reply. Before #7046, the line was drawn only after the user landed in the panel's view, which then handed the reply to the page's seat.Fix. The early reveal skips a thread the primary holds as the last resort (
lastResort). Such a thread's part is drawn after the view lands, as before. A route under the panel choice holds no last-resort thread, so #7046's search clearing still happens in the press's task.Verification. The failing test fails on
mainand passes on this branch. These also pass: all oftest_reply_sessionsandtest_threads_in_panel;test_seated_threads; the two diff journeys #7046 repaired intest_render_anchors(test_a_data_bound_diff_aims_and_selects_one_source_line,test_a_diff_surface_keeps_the_complete_thread_lifecycle_inline); andpnpm run test:runtime.Closes #7071 — automated triage