Repository navigation
test(app): read the tab-switch scroll regression as a reader would, at a loaded runner's speed - #4483
Conversation
… speed Main's browser lane failed this script twice at the second trip's scroll check (8471 -> 8720) and it passed locally. With Chrome's CPU throttled 4x, as a loaded runner is, it fails every time here too: the chat's rows above the reader are measured after the place was read, the transcript grows by 188 to 249 px and the list keeps the reader's row by moving scrollTop, so the raw offset differs although the same row is at the top. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ll checks The regression set scrollTop by hand and dispatched a scroll event. ChatView takes a scroll it saw no reader input for as the list's own, so on a loaded runner the chat went on following its end: the "reader" was at the bottom (8471 = 9160 - 689 in main's failing run), the demo's agent then finished its turn, the chat followed the new end, and the second trip's exact scrollTop check read 8720. The reader now scrolls up with the wheel, the place is read once the list holds still and must be away from the end, the long history keeps each pane's first answer (the finished turn repeated in every round grew the transcript above the reader too), and the second trip checks the row the reader left, as the first return does, instead of an exact scrollTop. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
No actionable comments were generated in the recent review. Summary
Merge Risk:
|
|
Merged through |
Summary
scripts/tab-switch-keeps-scroll-demo-regression.ts(added with #4155) failed main's CI run 45068560928 twice at its second-trip check ("a desktop: the second trip keeps the scroll offset (8471 → 8720)"); the next run on main passed. The app is not at fault; the script was timing-dependent:scrollTopby hand, which the chat treats as no reader input. On a loaded runner the chat kept following its end, so the "reader" was really at the bottom (8471 = 9160 − 689). When the demo agent finished its turn, the chat followed the new end and the exact-offset check read 8720.Changes, script only:
Validation
bun run check faston b33a65a: green.Test-only: no app code changes.
🤖 Generated with Claude Code