A stuck scroll's report always says the reader was slid 0s ago #488

Closed
opened 2026-11-22 05:37:45 -08:00 by rays · 1 comment
Owner

All three scroll_stuck reports since 9035306 (#450) end with slid 0s ago: 2026-11-18 18:06 (jason, :all), 2026-11-19 18:37 and 19:15 (rays, :signal:1 and :all). The swipe code's own touchend, registered before the stuck-scroll watcher's, calls slide(0) on every touch in the reader that is not a swipe, and slide sets slidAt whatever dx is, so the field measures the touch it is reporting and never says when the reader was last slid across. That was the one field meant to test the theory in #450 that a swipe leaves WebKit without its scroller.

Also: the report reads scrollTop on touchend. On iOS the scroll runs off the main thread, and a fast flick (two to four touchmoves seen, as two of the three were) can end before the page has the new position, so a scroll that did move may be reported as stuck. Checking again a moment later would tell the two apart.

Found by the prod check:

$Q logs '{container="iPX"} |= "\"ev\":\"scroll_stuck\"" | json | line_format "{{.timestamp}} {{.user}} {{.feed}} {{.state}}"' 7d
All three scroll_stuck reports since 9035306 (#450) end with `slid 0s ago`: 2026-11-18 18:06 (jason, :all), 2026-11-19 18:37 and 19:15 (rays, :signal:1 and :all). The swipe code's own touchend, registered before the stuck-scroll watcher's, calls `slide(0)` on every touch in the reader that is not a swipe, and `slide` sets `slidAt` whatever dx is, so the field measures the touch it is reporting and never says when the reader was last slid across. That was the one field meant to test the theory in #450 that a swipe leaves WebKit without its scroller. Also: the report reads `scrollTop` on touchend. On iOS the scroll runs off the main thread, and a fast flick (two to four touchmoves seen, as two of the three were) can end before the page has the new position, so a scroll that did move may be reported as stuck. Checking again a moment later would tell the two apart. Found by the prod check: $Q logs '{container="iPX"} |= "\"ev\":\"scroll_stuck\"" | json | line_format "{{.timestamp}} {{.user}} {{.feed}} {{.state}}"' 7d
rays added the bug label 2026-11-22 05:37:45 -08:00
Author
Owner

Fixed in 8afa79b, deployed in ipx-web: slidAt is set only when the reader moves across, so slid says when it was last swiped; and the watcher looks at scrollTop again 300 ms after the touch ends, reporting only a reader that still has not moved, with the drag's time (N moves seen in Mms).

Fixed in 8afa79b, deployed in ipx-web: `slidAt` is set only when the reader moves across, so `slid` says when it was last swiped; and the watcher looks at scrollTop again 300 ms after the touch ends, reporting only a reader that still has not moved, with the drag's time (`N moves seen in Mms`).
rays closed this issue 2026-11-22 05:40:09 -08:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: rays/ipx#488