Let Windows users turn on notifications after a false denial#2483
Open
BradGroux wants to merge 1 commit into
Open
Let Windows users turn on notifications after a false denial#2483BradGroux wants to merge 1 commit into
BradGroux wants to merge 1 commit into
Conversation
Co-authored-by: Brad Groux <bradgroux@hotmail.com> Signed-off-by: Brad Groux <bradgroux@hotmail.com>
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.
Addresses #2445.
What Windows users saw
Buzz could report desktop notification permission as
deniedbefore Windowshad registered the app as a notification sender. The settings toggle then
treated that value as final, so users could not turn notifications on even
though requesting permission would repair the state.
Why it happened
The settings flow only called
requestDesktopNotificationAccess()when thereported permission was
default.On the affected Windows path, Tauri's injected notification shim can initialize
Notification.permissionasdenied. CallingNotification.requestPermission()repairs the state and returnsgranted, butBuzz never made that request after the false denial.
What changed
ensureDesktopNotificationPermission()to keep the transition policysmall and testable:
defaultrequests access on every platform, preserving existing behavior;deniedretries once on Windows;deniedremains terminal on macOS, Linux, and the web.deniedstate,the later
grantedresult, and the exact request count.There is no retry loop, Tauri plugin fork, new dependency, or change to
notification delivery itself.
Regression coverage
denied→ one request →granteddenied→ no requestdefault→ request on Windows and non-WindowsWin32platform detection without the formerDarwinfalse-positive riskgranted → toggle enabled
Verification
Verified at commit
500753b900a4a52275b8870fb91e04f731d96c23.just ciWindows retries a false denied notification permission from settings—1 passed
One unrelated native process-group harness test returned a transient macOS PGID
of
-1during an intermediate full run. It passed immediately in isolation andagain in the subsequent full
just ciruns, including the final commit above.What still needs a real Windows test
The automated regression uses a Windows platform identity and exercises the
real Buzz settings hook against the notification shim. It does not run inside
Windows WebView2 or Tauri.
Keep #2445 open until an affected Windows 11 installation passes this smoke
test:
deniedstate described in the issue.grantedand the setting changes toOn.
That final check is required before claiming the Windows shell integration is
fixed.