Repository navigation
proposal: atomic working-surface persistence for App #2207 - #126
Conversation
|
This pull request has been ignored for the connected project Preview Branches by Supabase. |
|
Caution Review failedThe pull request is closed. Walkthrough
Merge Risk:
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
The current assistant persistence path replaces full UIMessage JSON and cannot safely acknowledge concurrent saved controls. This proposal selects a current companion plus digest-bound receipts inside the existing disabled chat_fence boundary, preserving the source snapshot in chat_messages.
The SQL outside migrations defines absent-version create, compare-and-swap saves, authorized head/exact reads, original-operation reconciliation, source immutability and deletion markers under the existing session/chat locks. Actual suffix deletion clears controls in the same transaction; deleted IDs cannot return. The API-facing design also binds acknowledgements to the submitted draft so a late save cannot mark newer edits saved.
Validation: 15 new mechanics cases plus 17 existing fencing regressions pass with the extension installed on both PostgreSQL 15 and 17 (32 each). Tests include actual lock waits, both save/delete orders, source-revocation seam, changed-key retry rejection, lost ack, receipt-insert rollback, and byte limits. Independent source review PASS after repairs. Added scoped read-only CI for the same disposable harness.
This is NOT a migration or runtime activation. No service EXECUTE grant or enrollment is supplied; the source-authority adapter deliberately refuses until an owning implementation exists. The test adapter is synthetic and does not establish live authorization. No production store, grant, provider action or migration apply occurred. Root owns adoption and merge; App #2207 remains incomplete. See proposals/durable-surfaces-2207/PROTOCOL.md for placement alternatives, lock order, writer inventory and remaining owner facts.
Related App contract: recoupable/app#2373
Paired API contract: recoupable/api#1185 (head 484cb541233fd7f8e1d0983e39ede45d4860e41d).
Fresh remote CI passed on exact head 6d1da43: PG17 job 122284403200 and PG15 job 122284403523 each ran all 32 tests successfully with cleanup. Other Database Actions checks also passed; Supabase Preview was skipped. This remains offline proposal verification, not an applied migration.
Summary by CodeRabbit