cancelNotification: false causes the loader to be run indefinitely without adding the reply notification
First of all, thanks a lot for this amazing package. This helped me a lot in many of my projects. Currently, I am developing a messaging application for a client and the clinet needs direct reply from notifications. They also want to keep the history like seen on Whatsapp or Instagram.
Describe the bug
When given cancelNotification: false, the loader sometimes doesn't disappear. I was able to reproduce this 4/10 times. I tried this in two different devices and the outcome was same. I tried the example code also. It also had the same issue.
An interesting thing is that the background call (Send reply in my case) is executed and completed successfully.
To Reproduce
- Go to Example app
- Click on 'Show notification with text action'. Reply works normally
- Now set the
cancelNotificationtofalsein the action. - Try the notification again.
- See the error
Expected behavior The reply notification should be sent with 'Me' as person. And also the previous notifications shouldn't be cancelled. This is important to keep the history like seen on Whatsapp or Instagram.
running into the same issue here.
leaving it cancelNotification: true is an okay compromise because the notification is still visible, as mentioned by @MaikuB's comment.
ditto on the praise for this amazing project. @MaikuB, you're doing god's work
Thanks for raising this. Based on what you shared with at least the modifications for the example app, this would be expected. Since you aren't cancelling the notification but keeping it, this means there's a need to follow the flow covered in the official Android docs. There's a requirement to update the notification as the way for Android to confirm the reply has been processed and get rid of the direct reply UI
One thing I forgot to add to my other message is to ask if you have checked to essentially update the notification by using the same ID and tag? An update can be done by calling the show() method