Skip to content
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

exceptions #16

Open
GooRingX opened this issue May 29, 2024 · 1 comment
Open

exceptions #16

GooRingX opened this issue May 29, 2024 · 1 comment

Comments

@GooRingX
Copy link

E/DartMessenger(21029): Uncaught exception in binary message listener
E/DartMessenger(21029): java.lang.IllegalStateException: Reply already submitted
E/DartMessenger(21029): at io.flutter.embedding.engine.dart.DartMessenger$Reply.reply(DartMessenger.java:431)
E/DartMessenger(21029): at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler.onMessage(MethodChannel.java:287)
E/DartMessenger(21029): at io.flutter.embedding.engine.dart.DartMessenger.invokeHandler(DartMessenger.java:292)
E/DartMessenger(21029): at io.flutter.embedding.engine.dart.DartMessenger.lambda$dispatchMessageToQueue$0$io-flutter-embedding-engine-dart-DartMessenger(DartMessenger.java:319)
E/DartMessenger(21029): at io.flutter.embedding.engine.dart.DartMessenger$$ExternalSyntheticLambda0.run(Unknown Source:12)
E/DartMessenger(21029): at android.os.Handler.handleCallback(Handler.java:942)
E/DartMessenger(21029): at android.os.Handler.dispatchMessage(Handler.java:99)
E/DartMessenger(21029): at android.os.Looper.loopOnce(Looper.java:211)
E/DartMessenger(21029): at android.os.Looper.loop(Looper.java:300)
E/DartMessenger(21029): at android.app.ActivityThread.main(ActivityThread.java:8348)
E/DartMessenger(21029): at java.lang.reflect.Method.invoke(Native Method)
E/DartMessenger(21029): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:582)
E/DartMessenger(21029): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1028)

E/MethodChannel#android_package_manager(21029): Failed to handle method call
E/MethodChannel#android_package_manager(21029): java.lang.IllegalArgumentException: Unsupported value: 'kotlin.Unit' of type 'class kotlin.Unit'
E/MethodChannel#android_package_manager(21029): at io.flutter.plugin.common.StandardMessageCodec.writeValue(StandardMessageCodec.java:297)
E/MethodChannel#android_package_manager(21029): at io.flutter.plugin.common.StandardMethodCodec.encodeSuccessEnvelope(StandardMethodCodec.java:61)
E/MethodChannel#android_package_manager(21029): at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler$1.success(MethodChannel.java:272)
E/MethodChannel#android_package_manager(21029): at lab.neruno.android_package_manager.AndroidPackageManagerPlugin.runWithPackageNameAndFlags(AndroidPackageManagerPlugin.kt:315)
E/MethodChannel#android_package_manager(21029): at lab.neruno.android_package_manager.AndroidPackageManagerPlugin.getApplicationLabel(AndroidPackageManagerPlugin.kt:626)
E/MethodChannel#android_package_manager(21029): at lab.neruno.android_package_manager.AndroidPackageManagerPlugin.onMethodCall(AndroidPackageManagerPlugin.kt:83)
E/MethodChannel#android_package_manager(21029): at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler.onMessage(MethodChannel.java:267)
E/MethodChannel#android_package_manager(21029): at io.flutter.embedding.engine.dart.DartMessenger.invokeHandler(DartMessenger.java:292)
E/MethodChannel#android_package_manager(21029): at io.flutter.embedding.engine.dart.DartMessenger.lambda$dispatchMessageToQueue$0$io-flutter-embedding-engine-dart-DartMessenger(DartMessenger.java:319)
E/MethodChannel#android_package_manager(21029): at io.flutter.embedding.engine.dart.DartMessenger$$ExternalSyntheticLambda0.run(Unknown Source:12)
E/MethodChannel#android_package_manager(21029): at android.os.Handler.handleCallback(Handler.java:942)
E/MethodChannel#android_package_manager(21029): at android.os.Handler.dispatchMessage(Handler.java:99)
E/MethodChannel#android_package_manager(21029): at android.os.Looper.loopOnce(Looper.java:211)
E/MethodChannel#android_package_manager(21029): at android.os.Looper.loop(Looper.java:300)
E/MethodChannel#android_package_manager(21029): at android.app.ActivityThread.main(ActivityThread.java:8348)
E/MethodChannel#android_package_manager(21029): at java.lang.reflect.Method.invoke(Native Method)
E/MethodChannel#android_package_manager(21029): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:582)
E/MethodChannel#android_package_manager(21029): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1028)

@workerbee22
Copy link

workerbee22 commented Nov 29, 2024

Ditto. We get an unhandled exception when calling getPackageInfo:

E/DartMessenger(20348): Uncaught exception in binary message listener
E/DartMessenger(20348): android.content.pm.PackageManager$NameNotFoundException: com.biostrap.vitalscience
E/DartMessenger(20348): 	at android.app.ApplicationPackageManager.getPackageInfoAsUser(ApplicationPackageManager.java:241)
E/DartMessenger(20348): 	at android.app.ApplicationPackageManager.getPackageInfo(ApplicationPackageManager.java:213)
E/DartMessenger(20348): 	at lab.neruno.android_package_manager.AndroidPackageManagerPlugin$getPackageInfo$2.invoke(AndroidPackageManagerPlugin.kt:862)
E/DartMessenger(20348): 	at lab.neruno.android_package_manager.AndroidPackageManagerPlugin$getPackageInfo$2.invoke(AndroidPackageManagerPlugin.kt:857)
E/DartMessenger(20348): 	at lab.neruno.android_package_manager.AndroidPackageManagerPlugin.runWithPackageNameAndFlags(AndroidPackageManagerPlugin.kt:325)
E/DartMessenger(20348): 	at lab.neruno.android_package_manager.AndroidPackageManagerPlugin.getPackageInfo(AndroidPackageManagerPlugin.kt:857)
E/DartMessenger(20348): 	at lab.neruno.android_package_manager.AndroidPackageManagerPlugin.onMethodCall(AndroidPackageManagerPlugin.kt:117)
E/DartMessenger(20348): 	at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler.onMessage(MethodChannel.java:267)
E/DartMessenger(20348): 	at io.flutter.embedding.engine.dart.DartMessenger.invokeHandler(DartMessenger.java:292)
E/DartMessenger(20348): 	at io.flutter.embedding.engine.dart.DartMessenger.lambda$dispatchMessageToQueue$0$io-flutter-embedding-engine-dart-DartMessenger(DartMessenger.java:319)
E/DartMessenger(20348): 	at io.flutter.embedding.engine.dart.DartMessenger$$ExternalSyntheticLambda0.run(Unknown Source:12)
E/DartMessenger(20348): 	at android.os.Handler.handleCallback(Handler.java:938)
E/DartMessenger(20348): 	at android.os.Handler.dispatchMessage(Handler.java:99)
E/DartMessenger(20348): 	at android.os.Looper.loopOnce(Looper.java:201)
E/DartMessenger(20348): 	at android.os.Looper.loop(Looper.java:288)
E/DartMessenger(20348): 	at android.app.ActivityThread.main(ActivityThread.java:7842)
E/DartMessenger(20348): 	at java.lang.reflect.Method.invoke(Native Method)
E/DartMessenger(20348): 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
E/DartMessenger(20348): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1003)

But that is by design, as if a specific package is not installed, then Android throws an exception. But we cannot seem to catch it in Flutter code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants