Persistent history tracking returns all transactions on app launch #480

Closed
opened 2024-05-23 18:42:39 +00:00 by shadowfacts · 0 comments
Owner

let req = NSPersistentHistoryChangeRequest.fetchHistory(after: self.lastRemoteChangeToken)

Because we call fetchHistory(after:) with nil, we waste a lot of time/energy going through every history instruction. We need to save the NSPersistentHistoryToken to disk after each remote change notification is handled.

Should also purge old history entries per https://developer.apple.com/documentation/coredata/consuming_relevant_store_changes

https://git.shadowfacts.net/shadowfacts/Tusker/src/commit/844d4056e3bf584d9bf6e7d86bb8ef74fd9e0b7a/Tusker/CoreData/MastodonCachePersistentStore.swift#L531 Because we call `fetchHistory(after:)` with nil, we waste a lot of time/energy going through every history instruction. We need to save the `NSPersistentHistoryToken` to disk after each remote change notification is handled. Should also purge old history entries per https://developer.apple.com/documentation/coredata/consuming_relevant_store_changes
shadowfacts added this to the 2024.3 milestone 2024-05-23 18:42:39 +00:00
shadowfacts added the
bug
label 2024-05-23 18:42:39 +00:00
Sign in to join this conversation.
No Milestone 2024.3
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: shadowfacts/Tusker#480
No description provided.