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

On detach - Servicebinding not initialized #58

Open
xunreal75 opened this issue Apr 20, 2024 · 2 comments
Open

On detach - Servicebinding not initialized #58

xunreal75 opened this issue Apr 20, 2024 · 2 comments

Comments

@xunreal75
Copy link

xunreal75 commented Apr 20, 2024

Caused by fh.s
lateinit property serviceBindManager has not been initialized

With an actual flutter version on Android 11-14 it seems, that the late initilize serviceBinding is not initialized.
Please check this on destroy and solve the issue.

com.nankai.flutter_nearby_connections.FlutterNearbyConnectionsPlugin.onDetachedFromEngine (FlutterNearbyConnectionsPlugin.java:25)
io.flutter.embedding.engine.FlutterEngineConnectionRegistry.remove (FlutterEngineConnectionRegistry.java:122)
io.flutter.embedding.engine.FlutterEngineConnectionRegistry.remove (FlutterEngineConnectionRegistry.java:16)
io.flutter.embedding.engine.FlutterEngineConnectionRegistry.removeAll (FlutterEngineConnectionRegistry.java:11)
io.flutter.embedding.engine.FlutterEngineConnectionRegistry.destroy (FlutterEngineConnectionRegistry.java:10)

@xunreal75
Copy link
Author

Complete Crashlytics report

com.nankai.flutter_nearby_connections.FlutterNearbyConnectionsPlugin.onDetachedFromEngine (FlutterNearbyConnectionsPlugin.java:25)
io.flutter.embedding.engine.FlutterEngineConnectionRegistry.remove (FlutterEngineConnectionRegistry.java:122)
io.flutter.embedding.engine.FlutterEngineConnectionRegistry.remove (FlutterEngineConnectionRegistry.java:16)
io.flutter.embedding.engine.FlutterEngineConnectionRegistry.removeAll (FlutterEngineConnectionRegistry.java:11)
io.flutter.embedding.engine.FlutterEngineConnectionRegistry.destroy (FlutterEngineConnectionRegistry.java:10)
io.flutter.embedding.engine.FlutterEngine.destroy (FlutterEngine.java:31)
io.flutter.embedding.android.FlutterActivityAndFragmentDelegate.onDetach (FlutterActivityAndFragmentDelegate.java:105)
io.flutter.embedding.android.FlutterActivity.onDestroy (FlutterActivity.java:18)
android.app.Activity.performDestroy (Activity.java:9048)
android.app.Instrumentation.callActivityOnDestroy (Instrumentation.java:1554)
android.app.ActivityThread.performDestroyActivity (ActivityThread.java:5814)
android.app.ActivityThread.handleDestroyActivity (ActivityThread.java:5859)
android.app.servertransaction.DestroyActivityItem.execute (DestroyActivityItem.java:47)
android.app.servertransaction.ActivityTransactionItem.execute (ActivityTransactionItem.java:60)
android.app.servertransaction.TransactionExecutor.executeLifecycleItem (TransactionExecutor.java:254)
android.app.servertransaction.TransactionExecutor.executeLifecycleState (TransactionExecutor.java:228)
android.app.servertransaction.TransactionExecutor.execute (TransactionExecutor.java:91)
android.app.ActivityThread$H.handleMessage (ActivityThread.java:2544)
android.os.Handler.dispatchMessage (Handler.java:107)
android.os.Looper.loopOnce (Looper.java:232)
android.os.Looper.loop (Looper.java:317)
android.app.ActivityThread.main (ActivityThread.java:8501)
java.lang.reflect.Method.invoke (Method.java)
com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:552)
com.android.internal.os.ZygoteInit.main (ZygoteInit.java:878)

91% Android 14
4% Android 11
4% Android 12
1% Android 13

@dev3-tech
Copy link

FATAL EXCEPTION: main
Process: {package name}, PID: 10126
java.lang.RuntimeException: Unable to destroy activity {{package name}/{package name}.MainActivity}: wg.h0: lateinit property serviceBindManager has not been initialized at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:4521)
at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:4539)
at android.app.servertransaction.DestroyActivityItem.execute(DestroyActivityItem.java:39)
at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:145)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:70)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1831)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:201)
at android.app.ActivityThread.main(ActivityThread.java:6810)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:547)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:873)
Caused by: wg.h0: lateinit property serviceBindManager has not been initialized
at wc.c.onDetachedFromEngine(FlutterNearbyConnectionsPlugin.kt:2)
at io.flutter.embedding.engine.c.t(FlutterEngineConnectionRegistry.java:25)
at io.flutter.embedding.engine.c.u(FlutterEngineConnectionRegistry.java:2)
at io.flutter.embedding.engine.c.v(FlutterEngineConnectionRegistry.java:1)
at io.flutter.embedding.engine.c.i(FlutterEngineConnectionRegistry.java:3)
at io.flutter.embedding.engine.a.g(FlutterEngine.java:4)
at io.flutter.embedding.android.d.u(FlutterActivityAndFragmentDelegate.java:16)
at io.flutter.embedding.android.c.onDestroy(FlutterActivity.java:4)
at com.macymind.calculatorlock.MainActivity.onDestroy(Unknown Source:0)
at android.app.Activity.performDestroy(Activity.java:7524)
at android.app.Instrumentation.callActivityOnDestroy(Instrumentation.java:1307)
at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:4506)
at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:4539) 
at android.app.servertransaction.DestroyActivityItem.execute(DestroyActivityItem.java:39) 
at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:145) 
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:70) 
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1831) 
at android.os.Handler.dispatchMessage(Handler.java:106) 
at android.os.Looper.loop(Looper.java:201) 
at android.app.ActivityThread.main(ActivityThread.java:6810) 
at java.lang.reflect.Method.invoke(Native Method) 
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:547) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:873) 

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