Skip to content

fix(firstmate): Persist chat drafts across app restarts - #113

Merged
gpambrozio merged 1 commit into
gpambrozio:mainfrom
camerontaylor:fm/scout-firstmate-drafts
Nov 12, 2026
Merged

gpambrozio merged 1 commit into
gpambrozio:mainfrom
camerontaylor:fm/scout-firstmate-drafts

Conversation

@camerontaylor

Copy link
Copy Markdown
Contributor

Unsent FirstMate chat text now returns after an app reload or relaunch. The composer retains its synchronous memory store and saves through supported plugin RPCs to an atomic host-side file, with guarded hydration, serialized writes and lifecycle flushes. Settings were considered; a separate RPC avoids contending with display-setting revisions and keeps each mate's draft independent.

Nonempty edits debounce for 300 ms; clears flush immediately. Backgrounding, navigation and plugin disposal also flush, but termination before transport completes can still lose the latest edit. Drafts are shared across clients of the same host/mate (last arriving write wins). Text stays visible until sending succeeds, preserving it on failure or app termination during delivery; follow-up edits survive success. Attachments, card answers and panel notes keep their existing persistence behavior.

Validation on Pluto: typecheck and 95 focused tests passed, including fresh-runtime recovery, hydration/clear races, in-flight write ordering, offline retry, reconnect subscriptions and send success/failure. No live plugin install/reload was performed. Physical-device background termination and human UI checks remain unverified.

CRQ request bdd2990d-c338-49f8-bc1f-5f8f7be745cb for ff76fc1 returned unsupported-repo; no CRQ verdict is claimed.

@gpambrozio
gpambrozio merged commit 1fa5236 into gpambrozio:main Nov 12, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants