mapbox / flutter-mapbox-gl

Moved to https://github.com/tobrun/flutter-mapbox-gl
Other
271 stars 60 forks source link

Clicking the info icon crashes app #72

Closed tobrun closed 5 years ago

tobrun commented 5 years ago

Crashes with following stacktrace:

E/AndroidRuntime( 2088): Process: com.mapbox.mapboxglexample, PID: 2088
E/AndroidRuntime( 2088): java.lang.ClassCastException: $Proxy1 cannot be cast to android.view.WindowManagerImpl
E/AndroidRuntime( 2088):    at android.view.Window.setWindowManager(Window.java:770)
E/AndroidRuntime( 2088):    at android.view.Window.setWindowManager(Window.java:751)
E/AndroidRuntime( 2088):    at android.app.Dialog.<init>(Dialog.java:220)
E/AndroidRuntime( 2088):    at android.app.AlertDialog.<init>(AlertDialog.java:201)
E/AndroidRuntime( 2088):    at android.app.AlertDialog$Builder.create(AlertDialog.java:1107)
E/AndroidRuntime( 2088):    at android.app.AlertDialog$Builder.show(AlertDialog.java:1134)
E/AndroidRuntime( 2088):    at com.mapbox.mapboxsdk.maps.AttributionDialogManager.showAttributionDialog(AttributionDialogManager.java:73)
E/AndroidRuntime( 2088):    at com.mapbox.mapboxsdk.maps.AttributionDialogManager.onClick(AttributionDialogManager.java:65)
E/AndroidRuntime( 2088):    at com.mapbox.mapboxsdk.maps.MapView$AttributionClickListener.onClick(MapView.java:1744)
E/AndroidRuntime( 2088):    at android.view.View.performClick(View.java:6877)
E/AndroidRuntime( 2088):    at android.view.View$PerformClick.run(View.java:26069)
E/AndroidRuntime( 2088):    at android.os.Handler.handleCallback(Handler.java:789)
E/AndroidRuntime( 2088):    at android.os.Handler.dispatchMessage(Handler.java:98)
E/AndroidRuntime( 2088):    at android.os.Looper.loop(Looper.java:164)
E/AndroidRuntime( 2088):    at android.app.ActivityThread.main(ActivityThread.java:6938)
E/AndroidRuntime( 2088):    at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime( 2088):    at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:327)
E/AndroidRuntime( 2088):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1374)
yoavrofe commented 5 years ago

We have a similar problem when placing a simple TextField in the map. tapping the TextField crashes the app. Hot reload also causes the app to crash.

These are critical bugs, and we'll appreciate your help, @tobrun .

Here's the stacktrace for the TextField crash:

E/SpannableStringBuilder(18472): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
I/chatty  (18472): uid=10207(com.mapbox.mapboxglexample) identical 2 lines
E/SpannableStringBuilder(18472): SPAN_EXCLUSIVE_EXCLUSIVE spans cannot have a zero length
I/Adreno  (18472): DequeueBuffer: dequeueBuffer failed
I/Adreno  (18472): DequeueBuffer: dequeueBuffer failed
I/Adreno  (18472): DequeueBuffer: dequeueBuffer failed
W/OpenGLRenderer(18472): swapBuffers encountered EGL error 12301 on 0x77ab61cf80, halting rendering...
D/libEGL  (18472): eglInitialize: enter
D/libEGL  (18472): eglInitialize: exit(res=1)
I/Mbgl-EGLConfigChooser(18472): In emulator: false
W/com.mapbox.mapboxglexample(18472): type=1400 audit(0.0:171058): avc: denied { search } for comm=474C546872656164203731313631 name="ctx" dev="debugfs" ino=15054 scontext=u:r:untrusted_app_27:s0:c512,c768 tcontext=u:object_r:qti_debugfs:s0 tclass=dir permissive=0
F/libc    (18472): Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0xb0 in tid 18882 (GLThread 71161), pid 18472 (mapboxglexample)
*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
Build fingerprint: 'Xiaomi/beryllium/beryllium:9/PKQ1.180729.001/V10.1.3.0.PEJMIFI:user/release-keys'
Revision: '0'
ABI: 'arm64'
pid: 18472, tid: 18882, name: GLThread 71161  >>> com.mapbox.mapboxglexample <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0xb0
Cause: null pointer dereference
x0  00000077be06b100  x1  0000000000003466  x2  00000077a0e00000  x3  000000000000000e
x4  000000000000006e  x5  0000000000000000  x6  00000077a0951cc0  x7  00000077a0951d00
x8  0000000000000000  x9  2e817e2dedba37d0  x10 000000000000006e  x11 0000000000000000
x12 000000779fdff880  x13 00000077a0951c00  x14 00000000311ebe08  x15 00000077a0dbde30
x16 0000007849070be0  x17 000000784900356c  x18 0000000000000008  x19 00000077a0fb8420
x20 00000077a0e74ee0  x21 00000077bc859ac0  x22 00000077af321470  x23 00000077af959a55
x24 0000000000000004  x25 00000077a4dff588  x26 00000077a4dff588  x27 0000000000000001
x28 00000077a4dfda80  x29 00000077a4dfd8a0
sp  00000077a4dfd8a0  lr  00000077a22c68f0  pc  00000077a22c5478
backtrace:
#00 pc 0000000000045478  /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/lib/arm64/libmapbox-gl.so
#01 pc 00000000000468ec  /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/lib/arm64/libmapbox-gl.so
#02 pc 0000000000046934  /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/lib/arm64/libmapbox-gl.so
#03 pc 0000000000126e54  /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/lib/arm64/libmapbox-gl.so
#04 pc 00000000000ab5c4  /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/lib/arm64/libmapbox-gl.so
#05 pc 00000000000ab60c  /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/lib/arm64/libmapbox-gl.so
#06 pc 00000000000a81e4  /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/lib/arm64/libmapbox-gl.so
#07 pc 0000000000089868  /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/lib/arm64/libmapbox-gl.so
#08 pc 000000000055f5e0  /system/lib64/libart.so (art_quick_generic_jni_trampoline+144)
#09 pc 0000000000556588  /system/lib64/libart.so (art_quick_invoke_stub+584)
#10 pc 00000000000cfcc8  /system/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+200)
#11 pc 0000000000280338  /system/lib64/libart.so (art::interpreter::ArtInterpreterToCompiledCodeBridge(art::Thread*, art::ArtMethod*, art::ShadowFrame*, unsigned short, art::JValue*)+344)
#12 pc 000000000027a34c  /system/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+968)
#13 pc 00000000005275c8  /system/lib64/libart.so (MterpInvokeDirect+296)
#14 pc 0000000000548c94  /system/lib64/libart.so (ExecuteMterpImpl+14484)
#15 pc 0000000000197134  /dev/ashmem/dalvik-classes.dex extracted in memory from /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/base.apk (deleted) (com.mapbox.mapboxsdk.maps.renderer.MapRenderer.onSurfaceCreated)
#16 pc 0000000000254050  /system/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEb.llvm.2198905147+488)
#17 pc 0000000000259b44  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+216)
#18 pc 000000000027a330  /system/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+940)
#19 pc 0000000000526920  /system/lib64/libart.so (MterpInvokeSuper+1420)
#20 pc 0000000000548c14  /system/lib64/libart.so (ExecuteMterpImpl+14356)
#21 pc 0000000000197d5c  /dev/ashmem/dalvik-classes.dex extracted in memory from /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/base.apk (deleted) (com.mapbox.mapboxsdk.maps.renderer.glsurfaceview.GLSurfaceViewMapRenderer.onSurfaceCreated)
#22 pc 0000000000254050  /system/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEb.llvm.2198905147+488)
#23 pc 0000000000259b44  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+216)
#24 pc 000000000027a330  /system/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+940)
#25 pc 0000000000526920  /system/lib64/libart.so (MterpInvokeSuper+1420)
#26 pc 0000000000548c14  /system/lib64/libart.so (ExecuteMterpImpl+14356)
#27 pc 000000000018d63e  /dev/ashmem/dalvik-classes.dex extracted in memory from /data/app/com.mapbox.mapboxglexample-E2CTrhJAtG7aPvrRHPfHsQ==/base.apk (deleted) (com.mapbox.mapboxsdk.maps.MapView$5.onSurfaceCreated+10)
#28 pc 0000000000254050  /system/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEb.llvm.2198905147+488)
#29 pc 0000000000259b44  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+216)
#30 pc 000000000027a330  /system/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+940)
#31 pc 0000000000527204  /system/lib64/libart.so (MterpInvokeInterface+1392)
#32 pc 0000000000548d94  /system/lib64/libart.so (ExecuteMterpImpl+14740)
#33 pc 0000000000b84e14  /system/framework/boot-framework.vdex (android.opengl.GLSurfaceView$GLThread.guardedRun+888)
#34 pc 0000000000254050  /system/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEb.llvm.2198905147+488)
#35 pc 0000000000259b44  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+216)
#36 pc 000000000027a330  /system/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+940)
#37 pc 00000000005275c8  /system/lib64/libart.so (MterpInvokeDirect+296)
#38 pc 0000000000548c94  /system/lib64/libart.so (ExecuteMterpImpl+14484)
#39 pc 0000000000b8546c  /system/framework/boot-framework.vdex (android.opengl.GLSurfaceView$GLThread.run+48)
#40 pc 0000000000254050  /system/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEb.llvm.2198905147+488)
#41 pc 0000000000516b3c  /system/lib64/libart.so (artQuickToInterpreterBridge+1020)
#42 pc 000000000055f6fc  /system/lib64/libart.so (art_quick_to_interpreter_bridge+92)
#43 pc 0000000000556588  /system/lib64/libart.so (art_quick_invoke_stub+584)
#44 pc 00000000000cfcc8  /system/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+200)
#45 pc 000000000045dba4  /system/lib64/libart.so (art::(anonymous namespace)::InvokeWithArgArray(art::ScopedObjectAccessAlreadyRunnable const&, art::ArtMethod*, art::(anonymous namespace)::ArgArray*, art::JValue*, char const*)+104)
#46 pc 000000000045ec60  /system/lib64/libart.so (art::InvokeVirtualOrInterfaceWithJValues(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, _jmethodID*, jvalue*)+424)
#47 pc 0000000000489ae8  /system/lib64/libart.so (art::Thread::CreateCallback(void*)+1120)
#48 pc 0000000000081dac  /system/lib64/libc.so (__pthread_start(void*)+36)
#49 pc 0000000000023788  /system/lib64/libc.so (__start_thread+68)
Lost connection to device.
Exited (sigterm)
tobrun commented 5 years ago

will be continued in https://github.com/tobrun/flutter-mapbox-gl/issues/2