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
Delayed notifications #1170
Comments
What exactly do you mean by 'high priority messaging'? |
If my phone has been locked for a while and it's not being charged then OH notifications can be delayed for many minutes. If the phone is unlocked or being charged then OH notifications are instant. Unlocking the phone makes any delayed notifications appear. In the notification settings for WhatsApp it has the "Use high priority notifications" option ticked. Not really sure what that means, but WhatsApp doesn't have any problem in immediately being able to show a notification. Perhaps this is related to high priority messages for Firebase Cloud Messaging which states they can wake the device from the doze state. My phone is running Oxygen OS 9.0.3 |
Can you please make a screenshot of that settings UI? Can't find anything similar in the AOSP settings UI at the moment.
|
The latest beta in using FCM instead of GCM and the latest server sends messages as high priority fcm messages. @digitaldan Did you deploy FCM on myopenhab.org? |
The beta is still showing the same delayed behaviour. |
Yes, because the openhab-cloud update wasn't deployed to myopenhab.org yet. There's nothing we can do on the client side. |
Did the openhab-cloud update actually get deployed last night since I'm still seeing the same delayed behaviour? |
Are there any updates regarding that problem yet? I experience the delayed notification behavior on my phone too. |
Can you have a look at https://dontkillmyapp.com/ and if your device is listed there? Delayed notifications can be caused by non-standard battery savers. |
Yes my device is listed on that website. I've disabled all the battery optimisations and have confirmed that the app is still running in the background and isn't being killed. Do the messages from the server contain a notification payload or is it just a data message? |
It's just a data message. With current openhab-cloud code deployed on myopenhab.org, it should be a high priority one. |
I think there's a typo (prority instead of priority) in opehab-cloud and it's not being sent as high priority: const firebaseOptions = { |
Ouch, that's correct. Can you create a PR against openhab-cloud for fixing this? |
Is there any schedule when this goes live or did the openHAB cloud already get updated? |
Quickly wanted to report that I also have this issue. For my openHab app battery optimisation is disabled, so that shouldn't be a problem.
|
@Andirs55 Can you have a look at https://dontkillmyapp.com/xiaomi? |
Thanks for the hint, but i would say that does not apply to me since I do not run MIUI OS but LineageOS. I guess this comes closest to the AOSP devices and I checked that battery optimization is turned off for openHAB which is the only advice for these devices. |
@digitaldan Where can I see the version of openhab-cloud on myopenhab.org? |
I noticed that there is a similar problem in other repositories. Perhaps we can refer to this issue, and this oneto find more context about the bug (e.g. the Android version, or their steps to reproduce?). Besides, microg/GmsCore#1093, AmazMod/AmazMod#121, urbanairship/android-library#52, katzer/cordova-plugin-local-notifications#938 are also similar issues that may provide useful context. |
As far as I know @MikeJMajor already submitted a PR with the fix and the PR is already merged too. I assume the only thing missing is a new release of the openhab cloud and the deployment to the myopenhab instance. |
This seems to be fixed for me now. |
On my OnePlus 6 notifications are often delayed until I unlock the device.
I've tried disabling all battery saving features which doesn't seem to help. I'm sure this is related to Android Pie since I've only noticed this since updating the phone, but WhatsApp doesn't seem to have the same problem (settings indicate it's using high priority messaging).
The text was updated successfully, but these errors were encountered: