Skip to content
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

Android "heads-up notifications" not showing up even with "android_priority" set to 2 #382

Open
weichen35 opened this issue Dec 14, 2022 · 2 comments
Labels

Comments

@weichen35
Copy link

weichen35 commented Dec 14, 2022

The "heads-up notifications" (aka the "Pop on Screen" feature shown below in the image) on Android will not show up after the device receives a push with android_priority set to < 1 (i.e. priority lower than "high").

I was able to see the "heads-up" when I sent a push with android_priority: 2, to an app freshly installed on my device. However, after receiving a push with android_priority: 0, the "heads-up" no longer showed up, even if subsequent pushes with android_priority: 2 were sent. It appears that receiving a medium to low priority push on a device will make the "Pop on Screen" option stuck at false forever, until the app is re-installed.

My dependencies:
pushwoosh-cordova-plugin 8.3.2
cordova-android 8.1.0

Devices that showed this behavior:
Actual Pixel 5 API level 33
Emulator Pixel 5 API level 31

@wfhm wfhm added the 74491 label Dec 14, 2022
@wfhm
Copy link
Member

wfhm commented Dec 19, 2022

@ethanchen35
This is actually weird. On Android 8+, all notification settings, such as sound, vibration, showing pop-up notifications, are applied to a notification channel, not to a notification itself. Settings are applied to a channel once and can only be changed manually by a user, so there should be no way for you to disable showing a pop-up notification remotely or programmatically from the application itself.

I was able to reproduce the issue with an Android 13 device, and we will investigate this. Meanwhile, as a workaround, you can send pushes with high priority to a separate notification channel. You can find the guide by the link below:

https://docs.pushwoosh.com/platform-docs/pushwoosh-sdk/android-push-notifications/customizing-android-sdk/notification-channels

@weichen35
Copy link
Author

Thank you for the response. Yes, increasing priority on a new channel works. It appears that making a non-channel push to show pop-up still works, but it just has the mentioned weird behavior. Hope you have a smooth debug process.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants