fix(mobile): keep retired sections manager out of successor cache - #7873
Conversation
A newer layout from another device replaced the sections store but left the edit's debounce armed, so it republished the peer's layout as a redundant event. Cancel the waiting timer like desktop's cancelPendingPublish; a publish already running is untouched. A retired manager's late OK could also restore its submitted layout into the successor's shared prefs cache; fence the restore on !_disposed. Co-authored-by: Will Pfleger <pfleger.will@gmail.com> Signed-off-by: Will Pfleger <pfleger.will@gmail.com>
🔐 Codex Security Review
|
Drop the debounce cancel on remote adoption: the surviving republish is what re-converges an OK that wins the cursor after a same-second loser replaced the store. Guard _persist on _disposed so no retired-manager path (late-OK restore or the dispose flush pre-read) writes the prefs key its successor owns. Co-authored-by: Will Pfleger <pfleger.will@gmail.com> Signed-off-by: Will Pfleger <pfleger.will@gmail.com>
wesbillman
left a comment
There was a problem hiding this comment.
Carl, an automated reviewer, commenting via Wes’s GitHub account.
Review clear
HEAD 9a75f5432f07a8ada0818245c84477242632c59f; BASE 797012ff01a6d499959b45ed2e56f7927c6a4d6b. No actionable blocker found in this two-file fix. This is a comment, not merge approval.
- The central persistence guard prevents a retired manager from initiating preference writes after disposal, including late relay OK restoration and the dispose-flush history continuation. I traced provider replacement, startup/resume reads, live callbacks, local edits and publish completion through the shared pubkey-keyed storage boundary. Active-manager persistence and existing relay-flush behavior are preserved.
- The two retirement regressions exercise the production manager, signing/session path and storage with held history/OK responses, then verify the successor’s cache survives. The additional edit-during-OK and same-second convergence tests cover adjacent behavior. The latter establishes convergence, not preservation of every intervening local edit; the documented own-echo residual is unchanged and outside this fix.
- Existing CI passed: mobile analysis,
2444Flutter tests (4skipped), and3push-unconfigured tests. Evidence is for synthetic merge6ff82c9a435cf32ed556d3400efb3cc43fba4f8dof this exact head/base. Codex Security Review was cancelled, leaving the commit rollup red; resolve or explicitly disposition that separate gate before merge. No cancellation cause inferred.
Source-only review on pinned Blox2933794; no checkout, local tests, runtime probe or CI rerun. This guard does not add a durability/completion fence for preference writes initiated before disposal, or cancel inherited relay-side flushes.
…c-agent-commit-identity * origin/main: fix(mobile): keep retired sections manager out of successor cache (#7873) Select one feature flag provider at compile time (#7677) chore(release): release Buzz Desktop version 0.5.25 (#7867) fix(ci): consume the published MinIO image (#7870) fix(mobile): converge sidebar managers on relay head with resume re-read (#7806) fix(ci): bootstrap the reusable MinIO image in GHCR (#7869) Discover alternate Buzz ACP commands (#6948) fix(hooks): surface nextest failures and stale pnpm deps in pre-push (#7850) feat(acp): run one prepared task from a file or stdin (#7851) Fix mobile heart and warning emoji with native font fallback (#7842) chore(mesh): upgrade MeshLLM to 0.76.2 (#7559) feat(agents): humanize uncurated Databricks model ids with a label grammar (#7844) Signed-off-by: Hayt <211b96e6a2b7f45fd4047988976c7bbbeeda0c15f3ae7b32eec20834b5a55118@buzz.block.builderlab.xyz> # Conflicts: # Cargo.lock
…undation-local * origin/main: (50 commits) feat(desktop): relay admin console for the /api/admin/v1 operator surface (#4768) fix(mobile): keep retired sections manager out of successor cache (#7873) Select one feature flag provider at compile time (#7677) chore(release): release Buzz Desktop version 0.5.25 (#7867) fix(ci): consume the published MinIO image (#7870) fix(mobile): converge sidebar managers on relay head with resume re-read (#7806) fix(ci): bootstrap the reusable MinIO image in GHCR (#7869) Discover alternate Buzz ACP commands (#6948) fix(hooks): surface nextest failures and stale pnpm deps in pre-push (#7850) feat(acp): run one prepared task from a file or stdin (#7851) Fix mobile heart and warning emoji with native font fallback (#7842) chore(mesh): upgrade MeshLLM to 0.76.2 (#7559) feat(agents): humanize uncurated Databricks model ids with a label grammar (#7844) fix: route databricks claude fqns to anthropic messages (#7829) feat(relay): add opt-in newest-first thread windows (#7823) refactor: move agent Git bootstrap into ACP harness (#7819) Use worker snapshots for relay storage metrics (#7845) fix(hooks): strip repo-local git env from pre-push test lanes (#7841) fix(mobile-infra): render push grant lifetimes as decimal in chart 0.3.2 (#7820) fix(agent): preserve Databricks Opus UC reasoning and tool continuation (#7840) ... Signed-off-by: tornquist <tornquist@squareup.com>
…t/osc-event-write-chokepoint * commit 'a6a3032e446e6e66e8e41a229ef655ea79f36202': (50 commits) feat(desktop): relay admin console for the /api/admin/v1 operator surface (#4768) fix(mobile): keep retired sections manager out of successor cache (#7873) Select one feature flag provider at compile time (#7677) chore(release): release Buzz Desktop version 0.5.25 (#7867) fix(ci): consume the published MinIO image (#7870) fix(mobile): converge sidebar managers on relay head with resume re-read (#7806) fix(ci): bootstrap the reusable MinIO image in GHCR (#7869) Discover alternate Buzz ACP commands (#6948) fix(hooks): surface nextest failures and stale pnpm deps in pre-push (#7850) feat(acp): run one prepared task from a file or stdin (#7851) Fix mobile heart and warning emoji with native font fallback (#7842) chore(mesh): upgrade MeshLLM to 0.76.2 (#7559) feat(agents): humanize uncurated Databricks model ids with a label grammar (#7844) fix: route databricks claude fqns to anthropic messages (#7829) feat(relay): add opt-in newest-first thread windows (#7823) refactor: move agent Git bootstrap into ACP harness (#7819) Use worker snapshots for relay storage metrics (#7845) fix(hooks): strip repo-local git env from pre-push test lanes (#7841) fix(mobile-infra): render push grant lifetimes as decimal in chart 0.3.2 (#7820) fix(agent): preserve Databricks Opus UC reasoning and tool continuation (#7840) ... Signed-off-by: tornquist <tornquist@squareup.com> # Conflicts: # crates/buzz-db/src/store/event.rs
…ction * origin/main: (21 commits) docs(vision): add /buzz/v1 read endpoints to the protocol contract (#7879) 🤖 fix(justfile): point just staging at the current staging relay (#7881) fix(relay-admin): make thread deletions atomic and fence expired action leases under row lock (#7853) feat(desktop): relay admin console for the /api/admin/v1 operator surface (#4768) fix(mobile): keep retired sections manager out of successor cache (#7873) Select one feature flag provider at compile time (#7677) chore(release): release Buzz Desktop version 0.5.25 (#7867) fix(ci): consume the published MinIO image (#7870) fix(mobile): converge sidebar managers on relay head with resume re-read (#7806) fix(ci): bootstrap the reusable MinIO image in GHCR (#7869) Discover alternate Buzz ACP commands (#6948) fix(hooks): surface nextest failures and stale pnpm deps in pre-push (#7850) feat(acp): run one prepared task from a file or stdin (#7851) Fix mobile heart and warning emoji with native font fallback (#7842) chore(mesh): upgrade MeshLLM to 0.76.2 (#7559) feat(agents): humanize uncurated Databricks model ids with a label grammar (#7844) fix: route databricks claude fqns to anthropic messages (#7829) feat(relay): add opt-in newest-first thread windows (#7823) refactor: move agent Git bootstrap into ACP harness (#7819) Use worker snapshots for relay storage metrics (#7845) ... Signed-off-by: Tom Brow <tomb@block.xyz>
…rcement * origin/main: docs: specify durable data backfills (#7326) docs(vision): add /buzz/v1 read endpoints to the protocol contract (#7879) 🤖 fix(justfile): point just staging at the current staging relay (#7881) fix(relay-admin): make thread deletions atomic and fence expired action leases under row lock (#7853) feat(desktop): relay admin console for the /api/admin/v1 operator surface (#4768) fix(mobile): keep retired sections manager out of successor cache (#7873) Select one feature flag provider at compile time (#7677) chore(release): release Buzz Desktop version 0.5.25 (#7867) Signed-off-by: Hayt <211b96e6a2b7f45fd4047988976c7bbbeeda0c15f3ae7b32eec20834b5a55118@buzz.block.builderlab.xyz>
…ivery * origin/main: feat(relay): enforce NIP-FI assertion+NIP-98 pairing on HTTP ingress (#7264) fix(ci): run the admin disabled-mode DB test in the PostgreSQL lane (#7900) 🤖 docs: add pre-PR checklist and review guidance to AGENTS.md (#7897) docs: specify durable data backfills (#7326) docs(vision): add /buzz/v1 read endpoints to the protocol contract (#7879) 🤖 fix(justfile): point just staging at the current staging relay (#7881) fix(relay-admin): make thread deletions atomic and fence expired action leases under row lock (#7853) feat(desktop): relay admin console for the /api/admin/v1 operator surface (#4768) fix(mobile): keep retired sections manager out of successor cache (#7873) Signed-off-by: Tom Brow <tomb@block.xyz>
Follow-up to #7806.
_persist()now returns once the manager is disposed. That covers every path a torn-down manager could take after an account or relay switch, including a late OK restoring its submitted layout and thedispose()flush's read-before-write merging a head. Before this change, both could overwrite the successor's cache on the same pubkey key._lastPublishedStoreis built from the submitted store)Residual: an edit made just before our own echo arrives can be replaced by that echo. This is existing behaviour on main and on desktop.