-
Notifications
You must be signed in to change notification settings - Fork 664
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
App crashes if both image_picker and file_picker 1.3.0 are installed #48
Comments
Hi. This is quite weird since they aren’t related in any way at the moment. Can you described the steps to fully reproduce this? Does it happen on both platforms? Thank you. |
Hi, here are the steps to reproduce:
The app will stop the moment a file is selected or cancelled. I currently running on Android only, so I'm not sure if this happens on iOS. |
Somehow, I'm glad that you've experienced this issue so quickly as it could lead some other users to come across this exception. A result callback was trying to be invoked when it shouldn't. It was a minor fix, yet important. If you are using Thank you. |
It's working perfectly now. Thank you for your prompt response and pushing out a fix so quickly. |
Getting this exception
This is my code
I am using |
The file_picker appears to be working fine, but any attempt to use the image_picker causes the app to crash, which will happen after a file is selected or captured by the camera, or when the user cancels selection or capture.
D/AndroidRuntime(12668): Shutting down VM
E/AndroidRuntime(12668): FATAL EXCEPTION: main
E/AndroidRuntime(12668): Process: app, PID: 12668
E/AndroidRuntime(12668): java.lang.RuntimeException: Failure delivering result ResultInfo{who=null, request=2343, result=-1, data=Intent { }} to activity {MainActivity}: java.lang.IllegalStateException: Reply already submitted
E/AndroidRuntime(12668): at android.app.ActivityThread.deliverResults(ActivityThread.java:4126)
E/AndroidRuntime(12668): at android.app.ActivityThread.handleSendResult(ActivityThread.java:4169)
E/AndroidRuntime(12668): at android.app.ActivityThread.-wrap20(ActivityThread.java)
E/AndroidRuntime(12668): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1552)
E/AndroidRuntime(12668): at android.os.Handler.dispatchMessage(Handler.java:102)
E/AndroidRuntime(12668): at android.os.Looper.loop(Looper.java:154)
E/AndroidRuntime(12668): at android.app.ActivityThread.main(ActivityThread.java:6186)
E/AndroidRuntime(12668): at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime(12668): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:889)
E/AndroidRuntime(12668): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:779)
E/AndroidRuntime(12668): Caused by: java.lang.IllegalStateException: Reply already submitted
E/AndroidRuntime(12668): at io.flutter.embedding.engine.dart.DartMessenger$Reply.reply(DartMessenger.java:124)
E/AndroidRuntime(12668): at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler$1.error(MethodChannel.java:209)
E/AndroidRuntime(12668): at com.mr.flutter.plugin.filepicker.FilePickerPlugin$1.onActivityResult(FilePickerPlugin.java:85)
E/AndroidRuntime(12668): at io.flutter.app.FlutterPluginRegistry.onActivityResult(FlutterPluginRegistry.java:218)
E/AndroidRuntime(12668): at io.flutter.app.FlutterActivityDelegate.onActivityResult(FlutterActivityDelegate.java:143)
E/AndroidRuntime(12668): at io.flutter.app.FlutterActivity.onActivityResult(FlutterActivity.java:142)
E/AndroidRuntime(12668): at android.app.Activity.dispatchActivityResult(Activity.java:6937)
E/AndroidRuntime(12668): at android.app.ActivityThread.deliverResults(ActivityThread.java:4122)
The text was updated successfully, but these errors were encountered: