-
-
Notifications
You must be signed in to change notification settings - Fork 88
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
Clicking on notification does not invoke a callback in ringStream #153
Comments
Hi @arungopalan Thanks for your interest in the plugin. I never heard of this issue before. I'll take a close look at it as soon as I find the time. Let me know if you if you find something. |
I'm using Firebase services in my app with FirebaseMessaging. I did a small test:
|
Hi @vitalii-t12 Thanks for sharing your issue. It looks like there is a conflict between my plugin and Firebase Messaging. If you could answer the following questions it could help me a lot identify the issue:
Thanks in advance. |
Hi, @gdelataillade
I'm using the example app and just added Firebase to it, nothing else. Video timing 2:00 when I kill the app WITH ALARM RINGING and then click on notification, it works perfectly well. But in this case I don't get the log that
You can see this at timing 3:27 the message with Feel free to ask any questions, I would be happy to help resolving this issue. |
Hi @arungopalan Thanks a lot for the detailed answer. I might have a workaround you can try: change the plugin's code and in the
to:
Let me know if it changes something. Thanks in advance. |
@gdelataillade Hi. Thanks for suggested fix. I tried it, but didn't help. When using I also noticed, that when |
Hi @vitalii-t12 Thanks for your answer ! It seems the issue lies with the For testing the proposed fix, you'll need to modify your pubspec.yaml to use the alarm plugin from a specific branch where the fix has been applied. Here's how you can do it: alarm:
git:
url: https://github.com/gdelataillade/alarm.git
ref: fix/android-ring-stream-issue Please let me know if this resolves the issue for you. Your feedback will be invaluable. |
Hi, @gdelataillade I'm happy to help! I love your lib, and will do anything I can to make it better. I tried running it with your fix, but the app doesn't run. Do you have any idea why I'm getting this issue? |
@gdelataillade hello again :) I managed to fix the issue above by pulling the project from your branch and setting up firebase again. Probably, was some caching issue. This fix brought some very interesting behavior to the app: alarm screen works ONE TIME when app is freshly installed. I tried it on my real device as well, and it's the same behavior, except, if I wait some time (like 5min.) and do a cold start, the alarm screen works one time as well, and then doesn't work again. Here is a short video, describing the case: |
Hi @vitalii-t12 Thanks for the feedback ! I just pushed a commit on the |
Hi, @gdelataillade That's amazing! It works well now!!! The only thing is, that when I open the app from notification I get the Here is a short video describing how it works and the bug I described above: Screencast.from.03-18-2024.05.14.54.PM.webm |
Hi again @vitalii-t12 Glad to see it works ! I'll take a look a this. In the meantime you can avoid the double navigation by checking if the navigation to the ring screen was already done once. Let me know if you think I can merge this branch to the main branch and make a release, and if you think I can close this issue. |
Hi, @gdelataillade We're almost there, but the side effect we're getting with double ring screen is a bit concerning. It looks, like it's called twice independently, while Screencast.from.03-19-2024.05.35.15.PM.webm |
Hi @vitalii-t12 I've been unable to reproduce the double navigation issue... Have you been able to find a fix or a workaround ? |
HI, @gdelataillade I didn't have time recently to play around with it. |
Hello, @gdelataillade Sorry for taking so long, was busy recently.
It worked now. I tried earlier doing something similar with state varialbe, but it didn't work (I really don't wanna investigate why, I'm happy it works now). Now it works perfecly well, and there are no other side effects. I can confirm that it works perfectly well, and you can close this discussion and merge your fix into main branch! |
Hi @vitalii-t12 Awesome ! I'm glad that it works now and that you like the library. Thank you so much and I wish you all the best too ! |
Alarm plugin version
Latest version
Describe the bug
If the app has been sent to the background, sometimes clicking on an alarm notification does not call the Stream subscription callback
Instead I see the following error in the logcat
W/FlutterJNI(13027): Tried to send a platform message to Flutter, but FlutterJNI was detached from native C++. Could not send. Channel: com.gdelataillade.alarm/alarm. Response ID: 3
Has anyone seen this behavior?
I am trying to make a small project to reproduce this behavior. But just wanted to see if someone else has seen this?
The text was updated successfully, but these errors were encountered: