-
Notifications
You must be signed in to change notification settings - Fork 16
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 application got crash on notification receive in killed state using Ably notifications #437
Comments
Thanks for reporting this @Asharulislam. Can you please confirm that you had this issue since v1.2.15? |
@ikbalkaya Yes the above issue is occurred when I am using v1.2.15. |
Thank you. I will investigate |
A small update from me - I've looked into it today for a bit, but couldn't find a way to reproduce this crash (tried using the example app with various emulators and a physical device, hasn't crashed once). I'm leaving Ably, so for whomever looks at it in the future - since it seems like this started happening since v. 1.2.15, it might be connected to the ably-java version bump (unlikely): #435 Please keep in mind that all those issues might become irrelevant once we switch to the federated plugin approach, but that will probably take a while. |
The corresponding Jira issue is https://ably.atlassian.net/browse/SDK-2480 |
@Asharulislam Could you provide Android version that causes this issue please? For the note I tested this on Android 11 and 13. It turns out that
|
@ikbalkaya My android version was 12. Ably version 1.2.15. |
Thanks @Asharulislam. I just did another test with
The behaviour was similar to the one as Android 11. Notifications aren't received but I did not experience a crash on app startup. When I was doing initial testing I realized the Flutter version was 2.8.0 - Would it be possible for you to increase your Flutter version and give it another go and see whether you are having a similar issue. In the meantime I realize that not receiving push messages when the app is terminated is another issue and I'm going to look into addressing it. Also please could you try using a release build of your app when testing push notifications on terminated state? |
if you open "Auto start" setting, you will receive message even if app is closed. Howerer, ably will start a new flutter engine to transport message to flutter. I think it's useless. |
Now I am using latest package of Ably 1.2.15.
Flutter version 2.5.3
Reference to ISSUE : #429
QuintinWillison ikbalkaya
If I send notifications then in Android (in terminated state) Application got crash.
Steps to reproduce:
Tried to send a platform message to Flutter, but FlutterJNI was detached from native C++. Could not send. Channel: io.ably.flutter.plugin. Response ID: 0
W/FlutterJNI(13840): Tried to send a platform message to Flutter, but FlutterJNI was detached from native C++. Could not send. Channel: io.ably.flutter.plugin. Response ID: 0
E/AndroidRuntime(13840): FATAL EXCEPTION: main
E/AndroidRuntime(13840): Process: com.appiskey.dang.dev, PID: 13840
E/AndroidRuntime(13840): java.lang.IllegalStateException: Reply already submitted
E/AndroidRuntime(13840): at io.flutter.embedding.engine.dart.DartMessenger$Reply.reply(DartMessenger.java:164)
E/AndroidRuntime(13840): at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler$1.success(MethodChannel.java:238)
E/AndroidRuntime(13840): at io.ably.flutter.plugin.AblyMethodCallHandler$MethodResultWrapper.lambda$success$0$AblyMethodCallHandler$MethodResultWrapper(AblyMethodCallHandler.java:133)
E/AndroidRuntime(13840): at io.ably.flutter.plugin.-$$Lambda$AblyMethodCallHandler$MethodResultWrapper$mM2gyGmNB_FxOxEa-tdyQn04YRo.run(Unknown Source:4)
E/AndroidRuntime(13840): at android.os.Handler.handleCallback(Handler.java:938)
E/AndroidRuntime(13840): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime(13840): at android.os.Looper.loop(Looper.java:246)
E/AndroidRuntime(13840): at android.app.ActivityThread.main(ActivityThread.java:8506)
E/AndroidRuntime(13840): at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime(13840): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:602)
E/AndroidRuntime(13840): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130)
h3. Some Time this error occured:
FATAL EXCEPTION: main
E/AndroidRuntime(18800): Process: com.appiskey.dang.dev, PID: 18800
E/AndroidRuntime(18800): java.lang.IllegalStateException: Reply already submitted
E/AndroidRuntime(18800): at io.flutter.embedding.engine.o.e.a(Unknown Source:35)
E/AndroidRuntime(18800): at g.b.d.a.v.b(Unknown Source:14)
E/AndroidRuntime(18800): at g.a.a.a.k1.e(:1)
E/AndroidRuntime(18800): at g.a.a.a.p0.run(Unknown Source:4)
E/AndroidRuntime(18800): at android.os.Handler.handleCallback(Handler.java:938)
E/AndroidRuntime(18800): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime(18800): at android.os.Looper.loop(Looper.java:246)
E/AndroidRuntime(18800): at android.app.ActivityThread.main(ActivityThread.java:8506)
E/AndroidRuntime(18800): at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime(18800): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:602)
E/AndroidRuntime(18800): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130)
┆Issue is synchronized with this Jira Bug by Unito
The text was updated successfully, but these errors were encountered: