Skip to content

fix(mobile): preserve saved work after storage failures - #274

Merged
rynfar merged 3 commits into
pylonfrom
upstream/2026-09-05-mobile-storage
Sep 6, 2026
Merged

fix(mobile): preserve saved work after storage failures#274
rynfar merged 3 commits into
pylonfrom
upstream/2026-09-05-mobile-storage

Conversation

@rynfar

@rynfar rynfar commented Sep 6, 2026

Copy link
Copy Markdown
Collaborator

A failed storage read can be mistaken for an empty mobile draft/outbox, allowing later writes or attachment cleanup to destroy saved work. Propagate read/decode failures to those operations and retry failed debounced saves during the final flush, preserving saved work and new edits.

Adopts upstream #9710 (7839140e5e) while retaining Pylon's draft fields and environment ownership. Applies to iOS and Android with every provider and server connection; no native dependency or contract changes. Recorded as a partial upstream adoption.

Validation: 103 draft/outbox tests, mobile typecheck, formatting, and targeted lint pass. This changes persistence behavior without changing layout; no simulator or live state was used.

The durable implementation and review record is consolidated in companion #279.

Model: GPT-6 Astra. Harness: Codex.

@github-actions github-actions Bot added size:M vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. labels Sep 6, 2026
@github-actions

github-actions Bot commented Sep 6, 2026

Copy link
Copy Markdown

Thread transfer impact

✅ Thread transfer remains within every enforced ceiling.

Provider Metric Main baseline This PR Impact PR ceiling
Codex Total thread wire 13.6 KiB 13.6 KiB +22 B (+0.2%) 15.1 KiB
Codex Thread snapshot wire 7.1 KiB 7.1 KiB 0 B (0.0%) 7.3 KiB
Codex Live turn WebSocket wire 6.5 KiB 6.6 KiB +22 B (+0.3%) 7.8 KiB
Codex Live turn WebSocket decoded 56.5 KiB 56.5 KiB 0 B (0.0%) 66.4 KiB
Codex Live turn messages 8 8 0 (0.0%) 21
Claude Total thread wire 13.6 KiB 13.6 KiB −10 B (−0.1%) 15.1 KiB
Claude Thread snapshot wire 7.1 KiB 7.1 KiB +5 B (+0.1%) 7.3 KiB
Claude Live turn WebSocket wire 6.6 KiB 6.5 KiB −15 B (−0.2%) 7.8 KiB
Claude Live turn WebSocket decoded 57.3 KiB 57.3 KiB 0 B (0.0%) 66.4 KiB
Claude Live turn messages 8 8 0 (0.0%) 21

Baseline: de8d090 · PR result: e638d20 · Source CI: success

Scenario and decoded snapshot size

10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

  • Codex decoded thread snapshot: 111.2 KiB
  • Claude decoded thread snapshot: 111.9 KiB

Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

@rynfar
rynfar force-pushed the upstream/2026-09-05-mobile-storage branch from a20686e to e638d20 Compare September 6, 2026 02:33
@rynfar
rynfar merged commit cebe7ad into pylon Sep 6, 2026
18 checks passed
@rynfar
rynfar deleted the upstream/2026-09-05-mobile-storage branch September 6, 2026 02:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants