Chat list keeps taking updates after a row with a spinner (stuck "pending", bubble under the composer) #4
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/list-stuck-updates"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Two reports, one cause:
Cause.
ScrollEngine's DifferenceKit update clearedisApplyingUpdatein aCATransactioncompletion block. That block runs only after every animation added in the transaction finishes.isApplyingUpdatestayed set andisBusyheld. Every later update waited inpendingParentuntil a drag drained it: the row'sConfirmed(new stamp, status cleared), the picture's grown size, the next message.Fix. The update finishes from
performBatchUpdates(nil)'s completion, queued after DifferenceKit's batches. That waits for the collection view's own animations only. Stick-to-bottom, the viewport signals, the top load and the drain run there as before.Tested in the iPhone 18 Pro simulator (iOS 27.0), with a test account on another.im in a group of its own.
Before:
isApplyingUpdate=1.After:
gmake test: 359 tests, 0 failures.Not reproduced with an incoming message from another member (the test group has one). No unit test: the coordinator is private to the representable and needs a laid-out collection view.
Touches
ScrollEngine.swift, as does #3; the two merge cleanly.🤖 Generated with Claude Code
c241e36f71toac157a5dc3