Skip to content
Source
Sign inSign up
pingdotgg/t3code

perf(mobile): thread list resumes from the saved cache, and large gaps reload over gzip HTTP #32287

Mergedjuliusmarmingemerged 1 commit intomain fromrefs/pull/32287/headmerged by juliusmarminge View on GitHub

Showing 11 changed files with 60 additions and 21 deletions (loading 8).

x
0 of 11 viewed, 11 left
10 additions and 1 deletionapps/mobile/src/connection/environment-cache-store.test.tsModified
View file
@@ -498,12 +498,21 @@
Effect.provideService(MobileDatabase.MobileDatabase, memory.database),
​
- yield* store.saveShell(ENVIRONMENT_ID, SHELL_SNAPSHOT);
+ const origin = {
+ serverVersion: "1.0.0",
+ databaseMigration: 70,
+ omitIdleSubagents: true,
+ omitOlderSettled: false,
+ snapshotAt: 1_800_000_000_000,
+ };
+ yield* store.saveShell(ENVIRONMENT_ID, SHELL_SNAPSHOT, origin);
yield* store.saveThread(ENVIRONMENT_ID, THREAD_SNAPSHOT);
​
const shell = Option.getOrThrow(yield* store.loadShell(ENVIRONMENT_ID));
const thread = Option.getOrThrow(yield* store.loadThread(ENVIRONMENT_ID, THREAD_ID));
​
+ expect(shell.origin).toEqual(origin);
+​
expect(DateTime.formatIso(shell.threads[0]!.updatedAt)).toBe("2026-07-29T12:00:00.000Z");
expect(DateTime.formatIso(shell.threads[0]!.latestUserMessageAt!)).toBe(
"2026-07-29T12:00:00.000Z",
26 additions and 11 deletionsapps/mobile/src/connection/environment-cache-store.tsModified
View file
@@ -106,7 +106,13 @@
operation: "load-shell",
decode: decodeStoredShellSnapshot,