surfstudio / flutter-otp-autofill

Made by Surf 🏄
Apache License 2.0
75 stars 42 forks source link

java.lang.RuntimeException: Error receiving broadcast Intent { act=com.google.android.gms.auth.api.phone.SMS_RETRIEVED #34

Closed BLUECALF closed 1 year ago

BLUECALF commented 1 year ago

java.lang.RuntimeException: Error receiving broadcast Intent { act=com.google.android.gms.auth.api.phone.SMS_RETRIEVED flg=0x200010 pkg=privpay.siriyangu.co.ke.privpay (has extras) } in ru.surfstudio.otp_autofill.SmsRetrieverReceiver@c5e4919 E/AndroidRuntime(19746): at android.app.LoadedApk$ReceiverDispatcher$Args.lambda$getRunnable$0$LoadedApk$ReceiverDispatcher$Args(LoadedApk.java:1561) E/AndroidRuntime(19746): at android.app.-$$Lambda$LoadedApk$ReceiverDispatcher$Args$_BumDX2UKsnxLVrE6UJsJZkotuA.run(Unknown Source:2) E/AndroidRuntime(19746): at android.os.Handler.handleCallback(Handler.java:883) E/AndroidRuntime(19746): at android.os.Handler.dispatchMessage(Handler.java:100) E/AndroidRuntime(19746): at android.os.Looper.loop(Looper.java:264) E/AndroidRuntime(19746): at android.app.ActivityThread.main(ActivityThread.java:7684) E/AndroidRuntime(19746): at java.lang.reflect.Method.invoke(Native Method) E/AndroidRuntime(19746): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492) E/AndroidRuntime(19746): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:980) E/AndroidRuntime(19746): Caused by: java.lang.IllegalStateException: Reply already submitted E/AndroidRuntime(19746): at io.flutter.embedding.engine.dart.DartMessenger$Reply.reply(DartMessenger.java:431) E/AndroidRuntime(19746): at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler$1.success(MethodChannel.java:267) E/AndroidRuntime(19746): at ru.surfstudio.otp_autofill.OTPPlugin$registerSmsRetrieverBroadcastReceiver$1$1.onSuccess(OTPPlugin.kt:181) E/AndroidRuntime(19746): at ru.surfstudio.otp_autofill.SmsRetrieverReceiver.onReceive(SmsRetrieverReceiver.kt:24) E/AndroidRuntime(19746): at android.app.LoadedApk$ReceiverDispatcher$Args.lambda$getRunnable$0$LoadedApk$ReceiverDispatcher$Args(LoadedApk.java:1551) E/AndroidRuntime(19746): ... 8 more I/Process (19746): Sending signal. PID: 19746 SIG: 9 Lost connection to device.

BLUECALF commented 1 year ago

This happens when

jale-codex commented 1 year ago

Same error and situation

BLUECALF commented 1 year ago

I used sms_autofill: ^2.2.0 and it worked for me. even with many sms

Tchisky commented 1 year ago

Same issue for me too, with version 2.1.0 when the SMS is received it throws same exception and app crashes.

plasticfiresam commented 1 year ago

PR that mentioned this issue was merged and issue with stopListen() method was also merged, closing issue