New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support Android 13 run time notification permission #2398
Comments
Thx. The linked PR would help with disabling / delaying notifications until the permission is granted. However, I'm not clear what the default behavior when you don't set anything should be. |
One of the drivers here is to allow apps to control when we should attempt to show notifications, for scenarios where we don't want that permission to show up. |
As a first step, we'll add a control to allow disabling all LeakCanary notifications. |
@pyricau I still want the notifications, but I want to be the one to request for the permission and Leak Canary should show notifications after that. |
I believe yes, just set |
Problem description
Android 13 is changing the requirement for notification permission to run-time grant by user instead of auto grant. Refer this link.
Due to this change for apps that are not changing target SDK version to 33 have no control over permission rationale dialog and it is shown to user as soon as a notification channel is created or a notification is posted by app. With using LeakCanary, notification channel is created upon finding first leak and hence causes a permission dialog to be shown. Refer screenshot displayed in third screen at this link. So app has no control on when this permission dialog shows up. This affects the user behavior and there isn't any work around.
Expecting a way to control the leak canary notifications to be generated only after a certain point after notification permission is granted.
Potential solutions
There can be couple of solutions possible.
Additional information
Not specific with app but can be checked with any app that targets lower than 33 API and includes leak canary.
Refer to a comment for related change #2395 (comment)
The text was updated successfully, but these errors were encountered: