fix(desktop): dedupe replayed thread reply notifications#2189
Open
Areson wants to merge 1 commit into
Open
Conversation
Areson
force-pushed
the
Areson/thread-reply-notification-dedupe
branch
7 times, most recently
from
July 21, 2026 02:00
5e386ee to
47be921
Compare
Persist notified reply IDs per channel and retain replay-boundary entries until reconnect catch-up completes. Co-authored-by: Ian Oberst <ioberst@squareup.com> Signed-off-by: Ian Oberst <ioberst@squareup.com> Co-authored-by: Codex <noreply@openai.com> Ai-assisted: true
Areson
force-pushed
the
Areson/thread-reply-notification-dedupe
branch
from
July 21, 2026 02:30
47be921 to
9e07d18
Compare
Areson
marked this pull request as ready for review
July 21, 2026 14:03
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Reconnect catch-up re-delivers already-seen thread replies through the live handler, causing macOS notifications to replay after laptop sleep, network changes, or retryable subscription recovery.
What
CLOSEDrecovery callbacks from remaining bound to a retired identityCLOSEDCLOSEDrecovery per live subscription from scheduling through recovered EOSE buffer drain, suspending cap eviction and persistence until every overlapping socket/subscription replay completesstalledbefore reset releases subscription recovery, eliminating a cap/flush gap before reconnect beginsCLOSEDrecovery one non-extendable eight-second EOSE deadline that resets into socket reconnect while recovery ownership is still heldRisk Assessment
Medium-low — notification dedupe remains isolated to thread replies. Shared desktop recovery preserves long-lived filter semantics, bounds socket and standalone subscription EOSE waits, and exposes an idempotent recovery lifecycle only to broad channel subscriptions. Identity handoff recreates those subscriptions; subscription removal, terminal
CLOSED, stalled/socket reset, and timeout all settle recovery state. The global cap remains a bounded-storage tradeoff among currently active subscriptions.References
Generated with Codex