fix(swift-ios): show last message age on the thread activity row #14021
Closedsaphid(GitHub profile, opens in a new tab)wants to merge 250+ commits into
t3code/rebuild-mobile-app-swift fromrefs/pull/14021/headopened View on GitHubgithub-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:trusted
github-actions[bot](GitHub profile, opens in a new tab) added labelssize:XXL
- @@ -1010,15 +1202,18 @@1202+ let threadID = key.threadID10101203 if pendingSubmissionsByID.values.contains(where: {10111204 $0.threadID == threadID && $0.creation != nil10121205 }) {10131206 await stopOutboxDrain()1207+ defer { scheduleOutboxDrain() }10141208 let queued = pendingSubmissionsByID.values.filter { $0.threadID == threadID }1209+ var discardedAll = true10151210 for submission in queued {10161211 if !(await discardQueuedSubmission(submission)) {1212+ discardedAll = false10171213 scheduleOutboxRetry()10181214 }10191215 }1216+ guard discardedAll else { throw FeatureStopStatusUnavailableError() }10201217 if pendingThreadsByID[threadID] == nil,10211218 snapshot.threads.contains(where: { $0.id == threadID }) {1022- await perform {1023- try await client.cancelTurn(threadID: threadID)1024- }1219+ try await client.cancelTurn(threadID: threadID)@@ -6122,11 +7057,6 @@61227057 let messages = thread.messages.map {61237058 mapMessage($0, environmentID: environmentID)61247059 }6125- let workIsLive = thread.session?.status == "starting"6126- || thread.session?.status == "running"6127- || backgroundLiveness(threadID: thread.id, environmentID: environmentID) == .working6128- let activities = thread.activities.compactMap {6129- NativeActivityNotice.message($0, createdAt: parseDate($0.createdAt))6130- }6131- + collapsedWorkLogs(thread.activities, sessionIsLive: workIsLive)6132- return (messages + activities).sorted { $0.createdAt < $1.createdAt }7060+ // Older pages contain earlier turn windows, but carry current session7061+ // metadata. That metadata must not revive their historical tool rows.7062+ return NativeTranscriptTimeline(
t3dotgg(GitHub profile, opens in a new tab) closed this
Sign in to join this conversation.



macroscopeapp[bot](GitHub profile, opens in a new tab) reviewed