Repository navigation
fix: remove 30-minute recency window that silently drops notifications - #3
Open
jeffstieler wants to merge 1 commit into
Open
jeffstieler wants to merge 1 commit into
jeffstieler wants to merge 1 commit into
Conversation
The _notificationRecencyWindow check causes agent notifications to be silently discarded when the last WebRTC session was more than 30 minutes ago. This is the primary use case for AFK — the user stepped away and wants to be notified when their agent finishes. The APNs token check remains as a valid guard (no token = no way to deliver), but the time-based gate defeats the purpose of the app. Fixes LiboShen#2
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.
Summary
_notificationRecencyWindow(30-minute) check in_handleAgentNotificationthat silently drops push notifications when the last WebRTC session was more than 30 minutes agoContext
The full notification flow: CLI → Unix socket →
CliServer→_handleAgentNotification→ signaling server → APNs → phone.The CLI side works perfectly — socket connects, data flushes, exits 0. But inside
_handleAgentNotification, the 30-minute recency check silently discards the notification before it reaches the signaling server. The user gets no feedback that their notification was dropped.See #2 for the full root cause analysis.
Test plan
afk notify 'test'