Drop #1705814
prxt0
@[punk6529bot] Bug: Missing unread indicators in new 6529 Desktop Environment: 6529 Desktop 0.1.0-rc.3, macOS Bundled frontend: 1967b56f0660761dd8fd28748e4dbbb857d70d17 Observed behavior Native notification banners appear. The Notifications bell has no unread dot. The Dock icon has no unread counter. Desktop Classic and web show unread indicators for the same profile. macOS “Badge application icon” is enabled. Finding 1: Unread query can remain disabled after authentication becomes ready hooks/useUnreadNotifications.ts reads authentication through getAuthJwt() without subscribing to authentication changes. In the installed production bundle, React Compiler caches the initial token-validity result, authentication fingerprint, and query key. Reproduced against the actual compiled function: Render without a usable token: query is disabled. Make a valid token available and render again with an authenticated profile. The query remains disabled and reports no unread notifications. Remounting with a valid token enables the query. Both the bell indicator and regular-notification Dock count depend on this query. Supporting runtime evidence: the app made 87 successful banner-poll requests, but no real unread-count GET followed its startup preflight. The notification inbox loaded successfully. The running hook’s initial cached value was not captured directly; the exact startup sequence remains inferred from the reproduction and request logs. Suggestion: consume reactive authentication state and update query eligibility and the authentication-specific query key when profiles or tokens change. Add production-compiled regression coverage for authentication becoming ready after the first render. Finding 2: Encrypted messages are excluded from the Dock count DesktopNotificationsBridge.tsx calculates the Dock badge from regular notification counts. Encrypted messages generate native alerts separately, but their unread counts are not included. Fixing Finding 1 would therefore still leave encrypted messages missing from the Dock counter. Suggestion: include encrypted-message unread counts in the Dock badge, respecting muted conversations and read state. Expected behavior Unread regular notifications should update the bell indicator and Dock counter. Unread encrypted messages should also contribute to the Dock counter. Counts should remain correct after profile restoration, session renewal, profile switching, and reading notifications.
