mapbox / mapbox-maps-android

Interactive, thoroughly customizable maps in native Android powered by vector tiles and OpenGL.
https://www.mapbox.com/mobile-maps-sdk
Other
464 stars 131 forks source link

SIGABRT - Native crash on Samsung devices running Android 12 #1697

Open alexbranti opened 1 year ago

alexbranti commented 1 year ago

Environment

Observed behavior and steps to reproduce

SIGABRT Abort program /apex/com.android.runtime/lib64/bionic/libc.so:334716 abort /apex/com.android.runtime/lib64/bionic/libc.so:267876 scudo::die() /apex/com.android.runtime/lib64/bionic/libc.so:269692 scudo::ScopedErrorReport::~ScopedErrorReport() /apex/com.android.runtime/lib64/bionic/libc.so:270288 scudo::reportInvalidChunkState(scudo::AllocatorAction, void*) /apex/com.android.runtime/lib64/bionic/libc.so:276076 scudo::Allocator<scudo::AndroidConfig, &scudo_malloc_postinit>::deallocate(void*, scudo::Chunk::Origin, unsigned long, unsigned long) /data/app/~~_2--0h93ACPR9pHhIGV-6w==/com.example.app-ZtmHjD0tXEcUUikBUwc_FQ==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3049648 0x7949f238b0 /data/app/~~_2--0h93ACPR9pHhIGV-6w==/com.example.app-ZtmHjD0tXEcUUikBUwc_FQ==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3053908 0x7949f24954 /data/app/~~_2--0h93ACPR9pHhIGV-6w==/com.example.app-ZtmHjD0tXEcUUikBUwc_FQ==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3046420 0x7949f22c14 /data/app/~~_2--0h93ACPR9pHhIGV-6w==/com.example.app-ZtmHjD0tXEcUUikBUwc_FQ==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3042340 0x7949f21c24 /data/app/~~_2--0h93ACPR9pHhIGV-6w==/com.example.app-ZtmHjD0tXEcUUikBUwc_FQ==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3040696 0x7949f215b8 /data/app/~~_2--0h93ACPR9pHhIGV-6w==/com.example.app-ZtmHjD0tXEcUUikBUwc_FQ==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3010112 0x7949f19e40 /data/app/~~_2--0h93ACPR9pHhIGV-6w==/com.example.app-ZtmHjD0tXEcUUikBUwc_FQ==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:2688456 0x7949ecb5c8 /data/app/~~_2--0h93ACPR9pHhIGV-6w==/com.example.app-ZtmHjD0tXEcUUikBUwc_FQ==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:2301556 0x7949e6ce74 /data/app/~~_2--0h93ACPR9pHhIGV-6w==/com.example.app-ZtmHjD0tXEcUUikBUwc_FQ==/oat/arm64/base.odex:2831344 art_jni_trampoline

Expected behavior

The app should not crash after being launched.

Notes / preliminary analysis

This is currently our top crash in the app.

Additional links and references

kiryldz commented 1 year ago

@alexbranti it's not possible to analyze log you provided properly, could you please share either tombstone or better log so that ndk-stack could be used to symbolicate it?

As a side note I'm using SM-G988B for regular development and did never see any issues. If you have code that could reproduce the crash, you could share it as well.

alexbranti commented 1 year ago

@kiryldz Unfortunately both of those options require us to reproduce the crash and collect the logs from the device. The only thing we have so far are stacktraces from Bugsnag. Do you have any recommendation in how to proceed from here?

We've been observing those crashes from several app releases but they had very different stack traces from each other (resulting in dozens of isolated crashes). Since we've updated Mapbox to 10.7.0 (and now 10.8.0), we noticed that most crashes are grouped in 3 categories and only Samsung devices are affected (running Android 12).

Top crashes in our last app release:

1 - SIGABRT (stacktrace in the issue descriptions)

2 - SIGBUS (stacktrace below)

4 - SIGBUG (stacktrace below)

SIGBUS Bus error (bad memory access) 
    /vendor/lib64/egl/libGLESv2_mtk.so:1750488 0x70319ec5d8
    /vendor/lib64/egl/libGLESv2_mtk.so:1735144 0x70319e89e8
    /vendor/lib64/egl/libGLESv2_mtk.so:1710908 0x70319e2b3c
    /vendor/lib64/egl/libGLESv2_mtk.so:1241068 0x703196ffec
    /vendor/lib64/egl/libGLESv2_mtk.so:1234856 glTexImage2D
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:5039968 0x6fc56ce760
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:5039488 0x6fc56ce580
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3179484 0x6fc55083dc
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:4591728 0x6fc5661070
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3485916 0x6fc55530dc
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3718060 0x6fc558bbac
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3667448 0x6fc557f5f8
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3494696 0x6fc5555328
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:2719604 0x6fc5497f74
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:2703152 0x6fc5493f30
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:2452720 0x6fc5456cf0
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/oat/arm64/base.odex:1999868 art_jni_trampoline
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/oat/arm64/base.odex:6815848 com.mapbox.maps.renderer.MapboxRenderThread.draw
    /data/app/~~HXKK7za82zz4OObm0KMKnw==/com.example.app-UNwikW2YZoozpaX1z2u4hg==/oat/arm64/base.odex:6824552 com.mapbox.maps.renderer.MapboxRenderThread.doFrame
    /system/framework/arm64/boot-framework.oat:9518088 android.view.Choreographer.doCallbacks
    /system/framework/arm64/boot-framework.oat:9520836 android.view.Choreographer.doFrame
    /system/framework/arm64/boot-framework.oat:10209612 android.view.Choreographer$FrameDisplayEventReceiver.run
    /system/framework/arm64/boot-framework.oat:8007072 android.os.Handler.dispatchMessage
    /system/framework/arm64/boot-framework.oat:8020652 android.os.Looper.loopOnce
    /system/framework/arm64/boot-framework.oat:8019460 android.os.Looper.loop
    /system/framework/arm64/boot-framework.oat:8015436 android.os.HandlerThread.run
    /apex/com.android.art/lib64/libart.so:2926436 art_quick_invoke_stub
    /apex/com.android.art/lib64/libart.so:3205504 art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)
    /apex/com.android.art/lib64/libart.so:3939764 art::JValue art::InvokeVirtualOrInterfaceWithJValues<art::ArtMethod*>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, art::ArtMethod*, jvalue const*)
    /apex/com.android.art/lib64/libart.so:4552940 art::Thread::CreateCallback(void*)
    /apex/com.android.runtime/lib64/bionic/libc.so:971064 __pthread_start(void*)
    /apex/com.android.runtime/lib64/bionic/libc.so:570016 __start_thread
SIGBUS Bus error (bad memory access) 
    /vendor/lib64/egl/libGLESv2_mtk.so:1736600 0x7763be8f98
    /vendor/lib64/egl/libGLESv2_mtk.so:1710908 0x7763be2b3c
    /vendor/lib64/egl/libGLESv2_mtk.so:1241068 0x7763b6ffec
    /vendor/lib64/egl/libGLESv2_mtk.so:1234856 glTexImage2D
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:5039968 0x76fe2cf760
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:5039488 0x76fe2cf580
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3179484 0x76fe1093dc
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:4591728 0x76fe262070
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3485916 0x76fe1540dc
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3718060 0x76fe18cbac
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3667448 0x76fe1805f8
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:3494696 0x76fe156328
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:2719604 0x76fe098f74
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:2703152 0x76fe094f30
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/split_config.arm64_v8a.apk!/lib/arm64-v8a/libmapbox-maps.so:2452720 0x76fe057cf0
    /apex/com.android.art/lib64/libart.so:2965572 art_quick_generic_jni_trampoline
    /apex/com.android.art/lib64/libart.so:2926436 art_quick_invoke_stub
    /apex/com.android.art/lib64/libart.so:3073712 art::interpreter::ArtInterpreterToCompiledCodeBridge(art::Thread*, art::ArtMethod*, art::ShadowFrame*, unsigned short, art::JValue*)
    /apex/com.android.art/lib64/libart.so:3069180 bool art::interpreter::DoCall<false, true>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)
    /apex/com.android.art/lib64/libart.so:4019276 MterpInvokeInterface
    /apex/com.android.art/lib64/libart.so:2904212 mterp_op_invoke_interface
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/oat/arm64/base.odex:13483452 0x7711f99dbc
    /apex/com.android.art/lib64/libart.so:2611264 art::interpreter::Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art::JValue, bool, bool) [clone .llvm.3351068054637636664]
    /apex/com.android.art/lib64/libart.so:3071608 bool art::interpreter::DoCall<false, true>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)
    /apex/com.android.art/lib64/libart.so:4019276 MterpInvokeInterface
    /apex/com.android.art/lib64/libart.so:2904212 mterp_op_invoke_interface
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/oat/arm64/base.odex:14485434 0x771208e7ba
    /apex/com.android.art/lib64/libart.so:2611264 art::interpreter::Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art::JValue, bool, bool) [clone .llvm.3351068054637636664]
    /apex/com.android.art/lib64/libart.so:3071608 bool art::interpreter::DoCall<false, true>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)
    /apex/com.android.art/lib64/libart.so:2887612 MterpInvokeVirtual
    /apex/com.android.art/lib64/libart.so:2903700 mterp_op_invoke_virtual
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/oat/arm64/base.odex:14481670 0x771208d906
    /apex/com.android.art/lib64/libart.so:2611264 art::interpreter::Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art::JValue, bool, bool) [clone .llvm.3351068054637636664]
    /apex/com.android.art/lib64/libart.so:3071608 bool art::interpreter::DoCall<false, true>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)
    /apex/com.android.art/lib64/libart.so:4235372 MterpInvokeDirect
    /apex/com.android.art/lib64/libart.so:2903956 mterp_op_invoke_direct
    /data/app/~~3es-W3fcs5DTQarPm-YiGw==/com.route.app-nSyFLEXoQ2qhH6BGUqvJYg==/oat/arm64/base.odex:14481384 0x771208d7e8
    /apex/com.android.art/lib64/libart.so:2611264 art::interpreter::Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art::JValue, bool, bool) [clone .llvm.3351068054637636664]
    /apex/com.android.art/lib64/libart.so:2607592 artQuickToInterpreterBridge
    /apex/com.android.art/lib64/libart.so:2965880 art_quick_to_interpreter_bridge
    /system/framework/arm64/boot-framework.oat:9518888 android.view.Choreographer.doCallbacks
    /system/framework/arm64/boot-framework.oat:9521636 android.view.Choreographer.doFrame
    /system/framework/arm64/boot-framework.oat:10210412 android.view.Choreographer$FrameDisplayEventReceiver.run
    /system/framework/arm64/boot-framework.oat:8007504 android.os.Handler.dispatchMessage
    /system/framework/arm64/boot-framework.oat:8021084 android.os.Looper.loopOnce
    /system/framework/arm64/boot-framework.oat:8019892 android.os.Looper.loop
    /system/framework/arm64/boot-framework.oat:8015868 android.os.HandlerThread.run
    /apex/com.android.art/lib64/libart.so:2926436 art_quick_invoke_stub
    /apex/com.android.art/lib64/libart.so:3205504 art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)
    /apex/com.android.art/lib64/libart.so:3939764 art::JValue art::InvokeVirtualOrInterfaceWithJValues<art::ArtMethod*>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, art::ArtMethod*, jvalue const*)
    /apex/com.android.art/lib64/libart.so:4552940 art::Thread::CreateCallback(void*)
    /apex/com.android.runtime/lib64/bionic/libc.so:970824 __pthread_start(void*)
    /apex/com.android.runtime/lib64/bionic/libc.so:569792 __start_thread
alexbranti commented 1 year ago

Play Console has more info in the stacktrace (it seems to be related to Camera plugin):

backtrace:
  #00  pc 0x0000000000051b7c  /apex/com.android.runtime/lib64/bionic/libc.so (abort+168)
  #01  pc 0x0000000000041664  /apex/com.android.runtime/lib64/bionic/libc.so (scudo::die()+12)
  #02  pc 0x0000000000041d7c  /apex/com.android.runtime/lib64/bionic/libc.so (scudo::ScopedErrorReport::~ScopedErrorReport()+36)
  #03  pc 0x0000000000041fd0  /apex/com.android.runtime/lib64/bionic/libc.so (scudo::reportInvalidChunkState(scudo::AllocatorAction, void*)+80)
  #04  pc 0x000000000004366c  /apex/com.android.runtime/lib64/bionic/libc.so (scudo::Allocator<scudo::AndroidConfig, &(scudo_malloc_postinit)>::deallocate(void*, scudo::Chunk::Origin, unsigned long, unsigned long)+316)
  #05  pc 0x00000000002e88b0  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #06  pc 0x00000000002e9954  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #07  pc 0x00000000002e7c14  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #08  pc 0x00000000002e6c24  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #09  pc 0x00000000002e65b8  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #10  pc 0x00000000002dee40  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #11  pc 0x00000000002905c8  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #12  pc 0x0000000000231e74  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #13  pc 0x0000000000440554  /apex/com.android.art/lib64/libart.so (art_quick_generic_jni_trampoline+148)
  #14  pc 0x000000000020b0d4  /apex/com.android.art/lib64/libart.so (nterp_helper+7636)
  #15  pc 0x0000000000cdbde2  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/oat/arm64/base.vdex (com.mapbox.maps.NativeMapImpl.setCamera+14)
  #16  pc 0x000000000020b074  /apex/com.android.art/lib64/libart.so (nterp_helper+7540)
  #17  pc 0x0000000000cda332  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/oat/arm64/base.vdex (com.mapbox.maps.MapboxMap.setCamera+30)
  #18  pc 0x000000000020b074  /apex/com.android.art/lib64/libart.so (nterp_helper+7540)
  #19  pc 0x0000000000d8ee86  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/oat/arm64/base.vdex (com.mapbox.maps.plugin.animation.CameraAnimationsPluginImpl.performMapJump$plugin_animation_release+50)
  #20  pc 0x000000000020a254  /apex/com.android.art/lib64/libart.so (nterp_helper+3924)
  #21  pc 0x0000000000d8ece0  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/oat/arm64/base.vdex (com.mapbox.maps.plugin.animation.CameraAnimationsPluginImpl.commitChangesRunnable$lambda-0+48)
  #22  pc 0x0000000000209334  /apex/com.android.art/lib64/libart.so (nterp_helper+52)
  #23  pc 0x0000000000d8e7a4  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/oat/arm64/base.vdex (com.mapbox.maps.plugin.animation.CameraAnimationsPluginImpl.$r8$lambda$Q1xLlWoVQ16QyJTQHFZvvXRplO4)
  #24  pc 0x0000000000209334  /apex/com.android.art/lib64/libart.so (nterp_helper+52)
  #25  pc 0x0000000000d8d4bc  /data/app/~~hWkkwo2zqPay46cxdYQ3Ag==/com.example.app-KnK_Bz8r9w6DQnjIwUntRg==/oat/arm64/base.vdex (com.mapbox.maps.plugin.animation.CameraAnimationsPluginImpl$$ExternalSyntheticLambda1.run+4)
  #26  pc 0x0000000000ea0e54  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (android.os.Handler.dispatchMessage+84)
kiryldz commented 1 year ago

@alexbranti please provide errors in the format that we could symbolicate them, see https://developer.android.com/ndk/guides/ndk-stack#usage

When it begins parsing the logcat output, the tool looks for an initial line of asterisks. For example:
florianPOLARSTEPS commented 1 year ago

@alexbranti @kiryldz

I have no way to reproduce the issue, but I am seeing the same crashes for many of our users (across various android versions).

Screenshot 2022-10-31 at 17 19 52
backtrace:
  #00  pc 0x00000000002285f0  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #01  pc 0x00000000002e88b0  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #02  pc 0x00000000002e9954  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #03  pc 0x00000000002e7c14  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #04  pc 0x00000000002e6c24  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #05  pc 0x00000000002e65b8  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #06  pc 0x00000000002dee40  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #07  pc 0x00000000002905c8  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #08  pc 0x0000000000231e74  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #09  pc 0x000000000021d0a8  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/oat/arm64/base.odex (art_jni_trampoline+152)
  #10  pc 0x0000000002096d0c  /memfd:jit-cache (com.mapbox.maps.MapboxMap.setCamera+172)
  #11  pc 0x0000000002081a64  /memfd:jit-cache (com.mapbox.maps.plugin.animation.CameraAnimationsPluginImpl.performMapJump$plugin_animation_release+212)
  #12  pc 0x0000000002061bf4  /memfd:jit-cache (com.mapbox.maps.plugin.animation.CameraAnimationsPluginImpl.commitChangesRunnable$lambda-0+484)
  #13  pc 0x0000000002038e64  /memfd:jit-cache (com.mapbox.maps.plugin.animation.CameraAnimationsPluginImpl.a+36)
  #14  pc 0x000000000025b6dc  /data/app/~~9ygOXKzmHEsCzX5Wmyda2g==/com.polarsteps-ZPfWd_nHgyuv8jrgNbh6wA==/oat/arm64/base.odex (androidx.activity.g.run+5740)
  #15  pc 0x00000000006c137c  /system/framework/arm64/boot-framework.oat (android.os.Handler.dispatchMessage+76)
  #16  pc 0x00000000006c48dc  /system/framework/arm64/boot-framework.oat (android.os.Looper.loop+1516)
  #17  pc 0x0000000000460514  /system/framework/arm64/boot-framework.oat (android.app.ActivityThread.main+820)
  #18  pc 0x00000000001347e8  /apex/com.android.art/lib64/libart.so (art_quick_invoke_static_stub+568)
  #19  pc 0x0000000000198eb0  /apex/com.android.art/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+232)
  #20  pc 0x00000000005323fc  /apex/com.android.art/lib64/libart.so (art::(anonymous namespace)::InvokeWithArgArray(art::ScopedObjectAccessAlreadyRunnable const&, art::ArtMethod*, art::(anonymous namespace)::ArgArray*, art::JValue*, char const*)+104)
  #21  pc 0x00000000005340f0  /apex/com.android.art/lib64/libart.so (art::InvokeMethod(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, _jobject*, _jobject*, unsigned long)+1352)
  #22  pc 0x00000000004b569c  /apex/com.android.art/lib64/libart.so (art::Method_invoke(_JNIEnv*, _jobject*, _jobject*, _jobjectArray*)+52)
  #23  pc 0x000000000008a6f4  /apex/com.android.art/javalib/arm64/boot.oat (art_jni_trampoline+180)
  #24  pc 0x0000000000af3908  /system/framework/arm64/boot-framework.oat (com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run+136)
  #25  pc 0x0000000000afd95c  /system/framework/arm64/boot-framework.oat (com.android.internal.os.ZygoteInit.main+2444)
  #26  pc 0x00000000001347e8  /apex/com.android.art/lib64/libart.so (art_quick_invoke_static_stub+568)
  #27  pc 0x0000000000198eb0  /apex/com.android.art/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+232)
  #28  pc 0x00000000005323fc  /apex/com.android.art/lib64/libart.so (art::(anonymous namespace)::InvokeWithArgArray(art::ScopedObjectAccessAlreadyRunnable const&, art::ArtMethod*, art::(anonymous namespace)::ArgArray*, art::JValue*, char const*)+104)
  #29  pc 0x0000000000531ff4  /apex/com.android.art/lib64/libart.so (art::JValue art::InvokeWithVarArgs<art::ArtMethod*>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, art::ArtMethod*, std::__va_list)+428)
  #30  pc 0x0000000000532f5c  /apex/com.android.art/lib64/libart.so (art::JValue art::InvokeWithVarArgs<_jmethodID*>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, _jmethodID*, std::__va_list)+92)
  #31  pc 0x0000000000424c58  /apex/com.android.art/lib64/libart.so (art::JNI<true>::CallStaticVoidMethodV(_JNIEnv*, _jclass*, _jmethodID*, std::__va_list)+656)
  #32  pc 0x000000000009c434  /system/lib64/libandroid_runtime.so (_JNIEnv::CallStaticVoidMethod(_jclass*, _jmethodID*, ...)+124)
  #33  pc 0x00000000000a4574  /system/lib64/libandroid_runtime.so (android::AndroidRuntime::start(char const*, android::Vector<android::String8> const&, bool)+848)
  #34  pc 0x000000000000358c  /system/bin/app_process64 (main+1348)
  #35  pc 0x000000000004a31c  /apex/com.android.runtime/lib64/bionic/libc.so (__libc_init+108)
yunikkk commented 1 year ago

@alexbranti for some reason all the crashlogs you've shared from Bugsnag could not be decoded, suspect the addresses reported contain library offset not subtracted, e.g. 0x703196ffec is a very large value, compare for example to the values that Google play reports, 0x00000000002e88b0. Also, the log reported by Google play seem different from the ones from Bugsnag, those from Bugsnag all end up in libGLESv2_mtk.so, so probably related to rendering. To be able to decode them we'll need a properly formatted addresses, probably from Google play?

Also exact version of Maps SDK that the crash is tied to is needed to decode it correctly, could you share it @alexbranti @florianPOLARSTEPS ?

florianPOLARSTEPS commented 1 year ago

@yunikkk The stacktrace I shared is from com.mapbox.maps:android:10.8.1 👍

yunikkk commented 1 year ago

@florianPOLARSTEPS thanks, this should be fixed at https://github.com/mapbox/mapbox-maps-android/releases/tag/v10.10.0-beta.1

alexbranti commented 1 year ago

Hey @yunikkk , sorry for late response (I was OOO). Here is the most recent crash from Google Play (Mapbox v10.8.1).

*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
pid: 0, tid: 0 >>> com.example.com <<<

backtrace:
  #00  pc 0x00000000001ab5d8  /vendor/lib64/egl/libGLESv2_mtk.so
  #01  pc 0x00000000001a79e8  /vendor/lib64/egl/libGLESv2_mtk.so
  #02  pc 0x00000000001a1b3c  /vendor/lib64/egl/libGLESv2_mtk.so
  #03  pc 0x000000000012efec  /vendor/lib64/egl/libGLESv2_mtk.so
  #04  pc 0x000000000012d7a8  /vendor/lib64/egl/libGLESv2_mtk.so (glTexImage2D+320)
  #05  pc 0x00000000004ce760  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #06  pc 0x00000000004ce580  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #07  pc 0x00000000003083dc  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #08  pc 0x0000000000461070  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #09  pc 0x00000000003530dc  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #10  pc 0x000000000038bbac  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #11  pc 0x000000000037f5f8  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #12  pc 0x0000000000355328  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #13  pc 0x0000000000297f74  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #14  pc 0x0000000000293f30  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #15  pc 0x0000000000256cf0  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #16  pc 0x00000000000ee3fc  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/oat/arm64/base.odex (art_jni_trampoline+92)
  #17  pc 0x00000000002ca764  /apex/com.android.art/lib64/libart.so (art_quick_invoke_stub+548)
  #18  pc 0x00000000002ee6b0  /apex/com.android.art/lib64/libart.so (art::interpreter::ArtInterpreterToCompiledCodeBridge(art::Thread*, art::ArtMethod*, art::ShadowFrame*, unsigned short, art::JValue*)+312)
  #19  pc 0x00000000002ed4fc  /apex/com.android.art/lib64/libart.so (bool art::interpreter::DoCall<false, true>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+1480)
  #20  pc 0x00000000003d544c  /apex/com.android.art/lib64/libart.so (MterpInvokeInterface+5120)
  #21  pc 0x00000000002c5094  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_interface+20)
  #22  pc 0x0000000000cd6960  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/oat/arm64/base.vdex (com.mapbox.maps.NativeMapImpl.render+4)
  #23  pc 0x000000000027d840  /apex/com.android.art/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art::JValue, bool, bool) (.llvm.3351068054637636664)+644)
  #24  pc 0x00000000002ede78  /apex/com.android.art/lib64/libart.so (bool art::interpreter::DoCall<false, true>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+3908)
  #25  pc 0x00000000003d544c  /apex/com.android.art/lib64/libart.so (MterpInvokeInterface+5120)
  #26  pc 0x00000000002c5094  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_interface+20)
  #27  pc 0x0000000000dcc68e  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/oat/arm64/base.vdex (com.mapbox.maps.renderer.MapboxRenderer.render+10)
  #28  pc 0x000000000027d840  /apex/com.android.art/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art::JValue, bool, bool) (.llvm.3351068054637636664)+644)
  #29  pc 0x00000000002ede78  /apex/com.android.art/lib64/libart.so (bool art::interpreter::DoCall<false, true>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+3908)
  #30  pc 0x00000000002c0fbc  /apex/com.android.art/lib64/libart.so (MterpInvokeVirtual+5660)
  #31  pc 0x00000000002c4e94  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_virtual+20)
  #32  pc 0x0000000000dcb7ce  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/oat/arm64/base.vdex (com.mapbox.maps.renderer.MapboxRenderThread.draw+142)
  #33  pc 0x000000000027d840  /apex/com.android.art/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art::JValue, bool, bool) (.llvm.3351068054637636664)+644)
  #34  pc 0x00000000002ede78  /apex/com.android.art/lib64/libart.so (bool art::interpreter::DoCall<false, true>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+3908)
  #35  pc 0x000000000040a06c  /apex/com.android.art/lib64/libart.so (MterpInvokeDirect+2488)
  #36  pc 0x00000000002c4f94  /apex/com.android.art/lib64/libart.so (mterp_op_invoke_direct+20)
  #37  pc 0x0000000000dcb6b0  /data/app/~~_vmkDOLBOnmaGlBv65CqpQ==/com.example.com-Qx38HLRAHXxHEnlULDjlrA==/oat/arm64/base.vdex (com.mapbox.maps.renderer.MapboxRenderThread.doFrame+20)
  #38  pc 0x000000000027d840  /apex/com.android.art/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art::JValue, bool, bool) (.llvm.3351068054637636664)+644)
  #39  pc 0x000000000027c9e8  /apex/com.android.art/lib64/libart.so (artQuickToInterpreterBridge+1176)
  #40  pc 0x00000000002d4178  /apex/com.android.art/lib64/libart.so (art_quick_to_interpreter_bridge+88)
  #41  pc 0x0000000000913c98  /system/framework/arm64/boot-framework.oat (android.view.Choreographer.doCallbacks+872)
  #42  pc 0x0000000000914754  /system/framework/arm64/boot-framework.oat (android.view.Choreographer.doFrame+1492)
  #43  pc 0x00000000009bc9bc  /system/framework/arm64/boot-framework.oat (android.view.Choreographer$FrameDisplayEventReceiver.run+92)
  #44  pc 0x00000000007a2c80  /system/framework/arm64/boot-framework.oat (android.os.Handler.dispatchMessage+80)
  #45  pc 0x00000000007a618c  /system/framework/arm64/boot-framework.oat (android.os.Looper.loopOnce+1036)
  #46  pc 0x00000000007a5ce4  /system/framework/arm64/boot-framework.oat (android.os.Looper.loop+516)
  #47  pc 0x00000000007a4d2c  /system/framework/arm64/boot-framework.oat (android.os.HandlerThread.run+540)
  #48  pc 0x00000000002ca764  /apex/com.android.art/lib64/libart.so (art_quick_invoke_stub+548)
  #49  pc 0x000000000030e980  /apex/com.android.art/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+156)
  #50  pc 0x00000000003c1db4  /apex/com.android.art/lib64/libart.so (art::JValue art::InvokeVirtualOrInterfaceWithJValues<art::ArtMethod*>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, art::ArtMethod*, jvalue const*)+380)
  #51  pc 0x00000000004578ec  /apex/com.android.art/lib64/libart.so (art::Thread::CreateCallback(void*)+992)
  #52  pc 0x00000000000ed048  /apex/com.android.runtime/lib64/bionic/libc.so (__pthread_start(void*)+264)
  #53  pc 0x000000000008b1c0  /apex/com.android.runtime/lib64/bionic/libc.so (__start_thread+64)
yunikkk commented 1 year ago

@alexbranti could you please check the phone models that throw this exceptions (those ending within the libGLESv2_mtk.so)? libGLESv2_mtk.so assumes it should be Mediatek chip, while the ones in the ticket description are with Snapdragon mostly.

alexbranti commented 1 year ago

Sure! Here is the list of most affected devices pulled from Play Console (stacktrace ending with libGLESv2_mtk.so):

rakuishi commented 1 year ago

I have also encountered the same issue. Is there an update for this issue? Additionally, crashes have been reported on the following devices in my app.

SamuelBrucksch commented 1 year ago

I also saw this crash on Galaxy S10+ (SM-G975F) with Android 12:

SIGBUS: Bus error (bad memory access)

0  libmapbox-maps.so +0xa7e43         0x716e90be43
1  libc++_shared.so +0xe8234          0x71d8940238
2  libc++_shared.so +0xe7e68          0x71d893fe6c
3  libc++_shared.so +0xe3f4c          0x71d893bf50
4  base.apk!libc++_shared.so +0xe3da0 __gxx_personality_v0
5  libmapbox-maps.so +0x222040        0x716ea86044
6  libmapbox-maps.so +0x222548        0x716ea8654c
7  libmapbox-maps.so +0x508830        0x716ed6c834
8  libmapbox-maps.so +0x509f18        0x716ed6df1c
9  libmapbox-maps.so +0x50979c        0x716ed6d7a0
10 libmapbox-maps.so +0x509620        0x716ed6d624
11 libmapbox-maps.so +0x4f97f4        0x716ed5d7f8
12 libmapbox-maps.so +0x500548        0x716ed6454c
13 libmapbox-common.so +0x1633f4      0x716f4183f8
14 libc.so +0xb4b34                   __pthread_start(void*)
15 libc.so +0x52c5c                   __start_thread

We use 10.9.0

We are in contact with a user, that has this issue, please let me know if this is the same error as the ones above, then i can build a new version with 10.10.0 as mentioned in https://github.com/mapbox/mapbox-maps-android/issues/1697#issuecomment-1305571354

SamuelBrucksch commented 1 year ago

We can also see the same issue now on a Pixel 3a:

SIGBUS: Bus error (bad memory access)

0  libmapbox-maps.so +0xa7e43         0x7959cfde43
1  libc++_shared.so +0xe8234          0x795b5d2238
2  libc++_shared.so +0xe7e68          0x795b5d1e6c
3  libc++_shared.so +0xe3f4c          0x795b5cdf50
4  base.apk!libc++_shared.so +0xe3da0 __gxx_personality_v0
5  libmapbox-maps.so +0x222040        0x7959e78044
6  libmapbox-maps.so +0x222548        0x7959e7854c
7  libmapbox-maps.so +0x508830        0x795a15e834
8  libmapbox-maps.so +0x509f18        0x795a15ff1c
9  libmapbox-maps.so +0x50979c        0x795a15f7a0
10 libmapbox-maps.so +0x509620        0x795a15f624
11 libmapbox-maps.so +0x4f97f4        0x795a14f7f8
12 libmapbox-maps.so +0x500548        0x795a15654c
13 libmapbox-common.so +0x1633f4      0x795b7783f8
14 libc.so +0xb180c                   __pthread_start(void*)
15 libc.so +0x512ec                   __start_thread

Seems to be the same issue, so not only Samsung related. Just checked our logs again, and it actually seems to happen on all kind of devices and Android Versions image

That it mainly happens on Android 12 is probably because that is currently installed on most of the phones.

@yunikkk could you please confirm, that this should be solved by upgrading to 10.10? I did not fully understand if your comment above was related to exactly this issue.

Here are some more logs from google console, hope it helps:

backtrace:
  #00  pc 0x00000000000a7e43  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-maps.so
  #01  pc 0x00000000000e8238  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libc++_shared.so
  #02  pc 0x00000000000e7e6c  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libc++_shared.so
  #03  pc 0x00000000000e3f50  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libc++_shared.so
  #04  pc 0x00000000000e3da4  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libc++_shared.so (__gxx_personality_v0+224)
  #05  pc 0x0000000000222044  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-maps.so
  #06  pc 0x000000000022254c  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-maps.so
  #07  pc 0x0000000000508834  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-maps.so
  #08  pc 0x0000000000509f1c  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-maps.so
  #09  pc 0x00000000005097a0  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-maps.so
  #10  pc 0x0000000000509624  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-maps.so
  #11  pc 0x00000000004f97f8  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-maps.so
  #12  pc 0x000000000050054c  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-maps.so
  #13  pc 0x00000000001633f8  /data/app/~~b8pdKNXbNd_pe0nYI06OBA==/com.iternio.abrpapp-BijcVUmqy4alvWlX-hjuMQ==/base.apk!libmapbox-common.so
  #14  pc 0x00000000000deb44  /apex/com.android.runtime/lib64/bionic/libc.so (__pthread_start(void*)+264)
  #15  pc 0x000000000007b2fc  /apex/com.android.runtime/lib64/bionic/libc.so (__start_thread+68)
backtrace:
  #00  pc 0x000000000008bc48  /apex/com.android.runtime/lib64/bionic/libc.so (abort+168)
  #01  pc 0x00000000000cece8  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libc++_shared.so
  #02  pc 0x00000000000ceeb4  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libc++_shared.so
  #03  pc 0x00000000000e3c5c  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libc++_shared.so
  #04  pc 0x00000000000e32f4  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libc++_shared.so
  #05  pc 0x00000000000e3248  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libc++_shared.so (__cxa_throw+124)
  #06  pc 0x00000000001234b4  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libmapbox-common.so
  #07  pc 0x00000000001afd9c  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libmapbox-common.so
  #08  pc 0x0000000000236f50  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libmapbox-common.so
  #09  pc 0x00000000002345cc  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libmapbox-common.so
  #10  pc 0x0000000000162610  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libmapbox-common.so
  #11  pc 0x00000000001633f8  /data/app/~~OA3aMV6trU3y2I5I6aw30g==/com.iternio.abrpapp-QI2BIkHIAc-46CvhdlivoQ==/base.apk!libmapbox-common.so
  #12  pc 0x00000000000f0d34  /apex/com.android.runtime/lib64/bionic/libc.so (__pthread_start(void*)+264)
  #13  pc 0x000000000008d57c  /apex/com.android.runtime/lib64/bionic/libc.so (__start_thread+68)
darrellbutt commented 1 year ago

Just jumping on this train...

I am using version 110.11.1 of the SDK and the crash i am seeing (reported by crashlytics):

Crashed: Thread: SIGBUS  0x0000006fb16dbfed
#00 pc 0xacfed libmapbox-maps.so (BuildId: 331a309c6d4e90a8)
#01 pc 0xe8238 libc++_shared.so (BuildId: fcc246cbb373c5edee634b117c4b4564cc9becf3)
#02 pc 0xe7e6c libc++_shared.so (BuildId: fcc246cbb373c5edee634b117c4b4564cc9becf3)
#03 pc 0xe3f50 libc++_shared.so (BuildId: fcc246cbb373c5edee634b117c4b4564cc9becf3)
#04 pc 0xe3da4 libc++_shared.so (BuildId: fcc246cbb373c5edee634b117c4b4564cc9becf3)
#05 pc 0x231044 libmapbox-maps.so (BuildId: 331a309c6d4e90a8)
#06 pc 0x23154c libmapbox-maps.so (BuildId: 331a309c6d4e90a8)
#07 pc 0x527770 libmapbox-maps.so (BuildId: 331a309c6d4e90a8)
#08 pc 0x528e5c libmapbox-maps.so (BuildId: 331a309c6d4e90a8)
#09 pc 0x5286e0 libmapbox-maps.so (BuildId: 331a309c6d4e90a8)
#10 pc 0x528564 libmapbox-maps.so (BuildId: 331a309c6d4e90a8)
#11 pc 0x51864c libmapbox-maps.so (BuildId: 331a309c6d4e90a8)
#12 pc 0x51f408 libmapbox-maps.so (BuildId: 331a309c6d4e90a8)
#13 pc 0x180370 libmapbox-common.so (BuildId: b5a10fefd0c88a9c)
#14 pc 0x172d6c libmapbox-common.so (BuildId: b5a10fefd0c88a9c)
#15 pc 0xb4ad8 libc.so (BuildId: 721f9a1e738668c9f29a0ef6a2870cb9)
#16 pc 0x52c08 libc.so (BuildId: 721f9a1e738668c9f29a0ef6a2870cb9)

I am also seeing this crash, its suddenly began to spike in occurrence, like others have mentioned, its primarily Samsung devices but occurring on others as well.. image

I should also note, we are using react-native@0.71.6

SamuelBrucksch commented 1 year ago

So an additional note: This only seems to happen when the Mapbox instance is programatically initialized and added to the UI. Previously, when we already defined it as part of the Android View, this error did not appear. But when we moved it out of the view, and initialized it programatically, this error started to pop up for some users.

We used a MapSurface before that with the exact same init properties and there is did not happen. Maybe that helps to identify the rootcause.

As a lot of users seem to be affected by this in our app, could this please be treated with some priority @yunikkk or @kiryldz?

yunikkk commented 1 year ago

@SamuelBrucksch hi, the crash you've first mentioned at https://github.com/mapbox/mapbox-maps-android/issues/1697#issuecomment-1517549540 is related to offline and it's different from the one that was discussed in this ticket previously (and fixed in 10.10.0). Do you still have the contact with the user seeing the crash? Also, the second stacktrace (ending with `backtrace:

00 pc 0x000000000008bc48 /apex/com.android.runtime/lib64/bionic/libc.so (abort+168)` represents different issue).

@darrellbutt and the crash you've shared seems to be the same one.

darrellbutt commented 1 year ago

@yunikkk

We have had contact with multiple users reporting the crash (currently seeing ~ 20k users affected), The issue seems to have risen after an app update event (this has been present for a couple of versions, but has had a sudden spike).

Currently the only way we can resolve the crash (confirmed by some of our users) is to either clear the data and cache of the app OR uninstalling and re-installing the app. The app then works as intended and the crash doesn't occur again.

Hopefully that can assist in debugging the issue.

yunikkk commented 1 year ago

@darrellbutt or @SamuelBrucksch could you get full logcat with the crash from any of the users devices? Exception should print more useful details before the native stacktrace

darrellbutt commented 1 year ago

@yunikkk

Unfortunately I am still unable to reproduce and still trying to source a device failing, so I can get it plugged in and have logcat running.

SamuelBrucksch commented 1 year ago

It's not exactly easy to describe users how to generate a bug report, as it's actually a semi-hidden feature of android. However I'm in contact with a user and he will try to grab a bug report from his phone after the crash, so I'll let you know once I have something.

If anybody else has the chance to grab one, please don't hesitate and still do it, as I'm not 100% sure if we can get it to work.

SamuelBrucksch commented 1 year ago

@yunikkk , I got a bug report, where should i send it to? It's from one of our users, so i do not want to share it publicly.

Here however is the crash from that file already, maybe that helps already:

05-10 16:52:10.354 10033 15319 15319 F DEBUG   : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
05-10 16:52:10.354 10033 15319 15319 F DEBUG   : Build fingerprint: 'POCO/surya_eea/surya:12/SKQ1.211019.001/V14.0.4.0.SJGEUXM:user/release-keys'
05-10 16:52:10.354 10033 15319 15319 F DEBUG   : Revision: '0'
05-10 16:52:10.354 10033 15319 15319 F DEBUG   : ABI: 'arm64'
05-10 16:52:10.354 10033 15319 15319 F DEBUG   : Timestamp: 2023-05-10 16:52:09.850841315+0200
05-10 16:52:10.354 10033 15319 15319 F DEBUG   : Process uptime: 0s
05-10 16:52:10.355 10033 15319 15319 F DEBUG   : Cmdline: com.iternio.abrpapp
05-10 16:52:10.355 10033 15319 15319 F DEBUG   : pid: 15082, tid: 15169, name: TileStoreFileSo  >>> com.iternio.abrpapp <<<
05-10 16:52:10.355 10033 15319 15319 F DEBUG   : uid: 10033
05-10 16:52:10.355 10033 15319 15319 F DEBUG   : signal 7 (SIGBUS), code 1 (BUS_ADRALN), fault addr 0x77ec739e43
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :     x0  00000077c4343540  x1  00000077c4342858  x2  0000000000000001  x3  b4000077e2483f60
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :     x4  00000077c4343540  x5  00000077f237dcc4  x6  fefeff37f3f49b0a  x7  7f7f7f7fffffff7f
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :     x8  00000077ec739e43  x9  0000000000000003  x10 0000000000004001  x11 0000000000000000
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :     x12 0000000000000000  x13 0000000000000001  x14 ffffffffffffffff  x15 00000077eef25000
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :     x16 00000077ecbd8a48  x17 0000007917eb84c0  x18 00000077be9e0000  x19 00000077c4342858
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :     x20 00000077c4343540  x21 00000077c4344000  x22 0000000000000001  x23 00000077c4343540
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :     x24 0000000000000000  x25 00000000644e0eee  x26 0000000000000000  x27 0000000000001000
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :     x28 00000000032f00ff  x29 00000077c4342830
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :     lr  00000077f238223c  sp  00000077c4342830  pc  00000077ec739e43  pst 0000000000000000
05-10 16:52:10.355 10033 15319 15319 F DEBUG   : backtrace:
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #00 pc 00000000000a7e43  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-maps.so (BuildId: 91dfb63eed72861c)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #01 pc 00000000000e8238  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libc++_shared.so (BuildId: fcc246cbb373c5edee634b117c4b4564cc9becf3)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #02 pc 00000000000e7e6c  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libc++_shared.so (BuildId: fcc246cbb373c5edee634b117c4b4564cc9becf3)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #03 pc 00000000000e3f50  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libc++_shared.so (BuildId: fcc246cbb373c5edee634b117c4b4564cc9becf3)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #04 pc 00000000000e3da4  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libc++_shared.so (__gxx_personality_v0+224) (BuildId: fcc246cbb373c5edee634b117c4b4564cc9becf3)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #05 pc 0000000000222044  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-maps.so (BuildId: 91dfb63eed72861c)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #06 pc 000000000022254c  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-maps.so (BuildId: 91dfb63eed72861c)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #07 pc 0000000000508834  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-maps.so (BuildId: 91dfb63eed72861c)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #08 pc 0000000000509f1c  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-maps.so (BuildId: 91dfb63eed72861c)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #09 pc 00000000005097a0  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-maps.so (BuildId: 91dfb63eed72861c)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #10 pc 0000000000509624  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-maps.so (BuildId: 91dfb63eed72861c)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #11 pc 00000000004f97f8  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-maps.so (BuildId: 91dfb63eed72861c)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #12 pc 000000000050054c  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-maps.so (BuildId: 91dfb63eed72861c)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #13 pc 00000000001633f8  /data/app/~~jGNae3olsg8NhM3Q4IEYBg==/com.iternio.abrpapp-vVH385-rKjo2GojM1jYGCQ==/base.apk!libmapbox-common.so (BuildId: 75d973c3f4d8c598)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #14 pc 00000000000f0df4  /apex/com.android.runtime/lib64/bionic/libc.so (__pthread_start(void*)+264) (BuildId: 2f84be24a19d511a358a9050af5b3974)
05-10 16:52:10.355 10033 15319 15319 F DEBUG   :       #15 pc 000000000008d63c  /apex/com.android.runtime/lib64/bionic/libc.so (__start_thread+68) (BuildId: 2f84be24a19d511a358a9050af5b3974)

Couldn't see any Java specific information related to mapbox, so no Java Exception before or any other helpful information, so let me know if you still need the bug report.

Another observation: When i invited that user to our internal test version with something i thought could workaround that crash, it worked for the user. When we then pushed it as release, it didn't anymore. So it could be related to Cache somehow, however the user also said he cleared cache and it didn't help.

So it looks like it is somehow related to Tiles Store...

darrellbutt commented 1 year ago

@SamuelBrucksch

So it could be related to Cache somehow, however the user also said he cleared cache and it didn't help.

We have seen similar behavior, our production users reported that clearing cache had no effect, BUT wiping data / re installing resolved the issue.

@yunikkk unfortunately, we have been unable to source a device failing still. I hoping our decreasing trend is users re installing the app.

image
yunikkk commented 1 year ago

@SamuelBrucksch you could it send it to my mapbox email dmitry.yunitski@mapbox.com, we'll take a look and maybe will see some hints.

So it looks like it is somehow related to Tiles Store...

Yes, from the decoded stacktrace it seems that sqlite query originating from the filesource fails for some reason, from your description it seems that it happens after app updates. Worst thing is that we don't see the error code from the native stacktrace, but again - maybe full bugreport will have clues.

SamuelBrucksch commented 1 year ago

I forwarded the bugreport a while ago, any progress here?

I can also confirm, that reinstalling the app seems to resolve the issue for the users.

yunikkk commented 1 year ago

@SamuelBrucksch unfortunately I haven't been able to find anything useful in the report either.

There's another report about sqlite db corruption https://github.com/mapbox/mapbox-maps-android/issues/2087, maybe they are related.

yunikkk commented 1 year ago

@SamuelBrucksch @darrellbutt by the way which version of ndk/libc++shared do you use? From the stacktrace - buildId == fcc246cbb373c5edee634b117c4b4564cc9becf3 and it weirdly does not match with any libc++shared I have.

darrellbutt commented 1 year ago

@yunikkk Our application uses NDK version: 23.1.7779620

yunikkk commented 1 year ago

@darrellbutt I believe this is the problem then. In our products 21.4.7075529 is used and it seems its incompatible with libc++shared from 23.1.7779620, crashing on stack unwinding when c++ code tries to throw-catch exception. Is there an option to switch to 21.4.7075529 on your end?

darrellbutt commented 1 year ago

@yunikkk hmmm... regarding the compatibility issue between NDK versions, we initially used v21.4.7075529 but updated to v23.1.7779620 upon react-native's (v0.71.6) update guidelines. Users who reported the crash were able to reinstall the app to completely resolved the issue for them. However, I feel downgrading the NDK version might reintroduce the crash. Is there an alternative solution we can explore?

yunikkk commented 1 year ago

@darrellbutt hi, which crash are you talking about downgrading the NDK version might reintroduce the crash - not one discussed here, right? I can reliably reproduce the crash on my end in our test apps replacing 21.4.7075529 with 23.1.7779620. Every time c++ exception is thrown (inside try-catch) it crashes in stack unwinding in libc++. I'm not sure there's anything we can do except using 21.4.7075529 for now until we bump NDK on our end.

Also, https://github.com/mapbox/mapbox-navigation-android/issues/6929 seems to be exactly the same issue, cc @mapbox/navigation-android .

SamuelBrucksch commented 1 year ago

We also use React-Native and recently updated, did not compare the NDK version yet though, but sounds like the same issue then. Weird still is, that the majority of users does not seem to experience the issue. For example on my Pixel 6 i never had any issues. And then again our users also report that reinstalling fixes it.

yunikkk commented 1 year ago

We also use React-Native and recently updated, did not compare the NDK version yet though, but sounds like the same issue then.

Should be 0.71 version of RN it seems where NDK got updated https://github.com/facebook/react-native/pull/35066. And actually there's even similar crash with other RN dependency and description of the problem with stack unwinding https://github.com/facebook/react-native/commit/a232decbb1252ade0247a352f887ca4d97ee273c.

Weird still is, that the majority of users does not seem to experience the issue. For example on my Pixel 6 i never had any issues. And then again our users also report that reinstalling fixes it.

Well it will crash if any c++ exception is thrown internally. In this specific example it's sqlite db error that should be an env issue (lack of space of smth) and thus goes away if app is reinstalled (== db cleared). But also for instance adding same style layers multiple times (as in Nav issue) or referencing missing resources will try to throw-catch internally and thus crash when NDK 23+ is used.

spaceod commented 1 year ago

Are there any alternative workarounds or solutions to make things work for React Native version 0.71.x?

yunikkk commented 1 year ago

Are there any alternative workarounds or solutions to make things work for React Native version 0.71.x?

I dont think there are, NDK 21/23 c++ exceptions are incompatible so the only safe option is to use compatible Maps/RN versions. We have plans to bump our NDK dependency but there's no specific timeline yet. We also updated the docs stating that NDK 21 is required to build with Mapbox SDKs.

JDM8 commented 1 year ago

darrellbutt

Hey Darrell @darrellbutt, did this decreasing trend end up being something you did or users reinstalling? Thanks

JDM8 commented 1 year ago

@yunikkk, I'm seeing native crashes like alexbranti and SamuelBrucksch, with: /apex/com.android.runtime/lib64/bionic/libc.so (abort+168)

You mentioned this is a different issue, any thoughts? Appreciate it.

yunikkk commented 1 year ago

@JDM8 could you share the full stacktrace? Or, even better, file a separate ticket since this one is already large enough and original crash was solved.

JDM8 commented 1 year ago

@yunikkk I'm on 9.7.2, so I probably shouldn't open a ticket in the new SDK git? However, it seems to be the same crash the others have reported here.

Here's a stack trace: Thread terminating with uncaught exception of type jni::PendingJavaException


pid: 0, tid: 14590 >>> com.wavve.boating.gps <<<

backtrace:

00 pc 0x0000000000052654 /apex/com.android.runtime/lib64/bionic/libc.so (abort+168)

01 pc 0x0000000000373d7c /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

02 pc 0x0000000000373eec /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

03 pc 0x00000000003714ac /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

04 pc 0x0000000000370ad8 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

05 pc 0x0000000000370a34 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so (__cxa_throw+112)

06 pc 0x00000000000947a0 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

07 pc 0x00000000000af0b0 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

08 pc 0x0000000000115d54 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

09 pc 0x00000000001c3bd4 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

10 pc 0x00000000001c3650 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

11 pc 0x00000000001c5e78 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

12 pc 0x0000000000221a38 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

13 pc 0x00000000000fb64c /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

14 pc 0x000000000021b380 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

15 pc 0x000000000021abec /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

16 pc 0x000000000021acb8 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

17 pc 0x0000000000219ee0 /data/app/~~J_-uY8TDWYxHme4NoKpGXw==/com.wavve.boating.gps-PwiTUEHcDRv0JwW8BpedqA==/base.apk!libmapbox-gl.so

18 pc 0x0000000000018028 /system/lib64/libutils.so (android::Looper::pollInner(int)+1064)

19 pc 0x0000000000017b9c /system/lib64/libutils.so (android::Looper::pollOnce(int, int, int, void**)+116)

20 pc 0x00000000001680cc /system/lib64/libandroid_runtime.so (android::android_os_MessageQueue_nativePollOnce(_JNIEnv, _jobject, long, int)+48)

21 pc 0x00000000002ec504 /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (art_jni_trampoline+116)

22 pc 0x0000000000ad3d38 /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (android.os.MessageQueue.next+312)

23 pc 0x0000000000ad0108 /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (android.os.Looper.loopOnce+104)

24 pc 0x0000000000acff6c /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (android.os.Looper.loop+1148)

25 pc 0x00000000007d94d8 /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (android.app.ActivityThread.main+1480)

26 pc 0x0000000000457e00 /apex/com.android.art/lib64/libart.so (art_quick_invoke_static_stub+576)

27 pc 0x000000000048c038 /apex/com.android.art/lib64/libart.so (_jobject art::InvokeMethod<(art::PointerSize)8>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject, _jobject, _jobject, unsigned long)+1560)

28 pc 0x000000000048b9f8 /apex/com.android.art/lib64/libart.so (art::Method_invoke(_JNIEnv, _jobject, _jobject, _jobjectArray) (.__uniq.165753521025965369065708152063621506277)+48)

29 pc 0x00000000002f2148 /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (art_jni_trampoline+120)

30 pc 0x0000000000a37c80 /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run+144)

31 pc 0x0000000000a42af4 /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (com.android.internal.os.ZygoteInit.main+3604)

32 pc 0x0000000000457e00 /apex/com.android.art/lib64/libart.so (art_quick_invoke_static_stub+576)

33 pc 0x000000000058bbc4 /apex/com.android.art/lib64/libart.so (art::JValue art::InvokeWithVarArgs<_jmethodID>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject, _jmethodID*, std::__va_list)+912)

34 pc 0x0000000000609af8 /apex/com.android.art/lib64/libart.so (art::JNI::CallStaticVoidMethodV(_JNIEnv, _jclass, _jmethodID*, std::__va_list)+172)

35 pc 0x00000000000c1c04 /system/lib64/libandroid_runtime.so (_JNIEnv::CallStaticVoidMethod(_jclass, _jmethodID, ...)+124)

36 pc 0x00000000000ce470 /system/lib64/libandroid_runtime.so (android::AndroidRuntime::start(char const*, android::Vector const&, bool)+856)

37 pc 0x0000000000002570 /system/bin/app_process64 (main+1304)

38 pc 0x000000000004a7d4 /apex/com.android.runtime/lib64/bionic/libc.so (__libc_init+100)

yunikkk commented 1 year ago

@yunikkk I'm on 9.7.2, so I probably shouldn't open a ticket in the new SDK git? However, it seems to be the same crash the others have reported here.

Ah, then indeed it's the wrong repo and we do not provide support for v9 unfortunately. Also, it doesn't seem like the same crash with the ones mentioned in this ticket. terminating with uncaught exception of type jni::PendingJavaException should mean the real issue was some java exception that happened when java code was called from c++. You can try to check the log before the crash happens, it might give a clue.

JDM8 commented 1 year ago

@yunikkk Wouldn't that be java code called from the Mapbox SDK c++ then, given the crash originates in libmapbox-gl.so?

yunikkk commented 1 year ago

@yunikkk Wouldn't that be java code called from the Mapbox SDK c++ then, given the crash originates in libmapbox-gl.so?

Yes, it can be java code from the mapbox sdk or some external java listener that was added on your end. Anyway full logs should have some hints in it.

darrellbutt commented 1 year ago

darrellbutt

Hey Darrell @darrellbutt, did this decreasing trend end up being something you did or users reinstalling? Thanks

@JDM8 Apologies for the late reply was on leave.

We assumed that re installing resolved this issue, but latest feedback suggests that after X amount of usage it returns.

@yunikkk I should mention, we have downgraded the NDK back to 21 on our beta track, but i can still see crashes in GooglePlayConsole and Chrashlytics.

see trace from google play console:

*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
pid: 0, tid: 27557 >>> <package-name> <<<

backtrace:
  Unknown
  #01  pc 0x00000000000e8238  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libc++_shared.so
  #02  pc 0x00000000000e7e6c  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libc++_shared.so
  #03  pc 0x00000000000e3f50  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libc++_shared.so
  #04  pc 0x00000000000e3da4  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libc++_shared.so (__gxx_personality_v0+224)
  #05  pc 0x0000000000237044  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #06  pc 0x000000000023754c  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #07  pc 0x00000000004641f8  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #08  pc 0x000000000046466c  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #09  pc 0x000000000046186c  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #10  pc 0x00000000002ba728  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #11  pc 0x00000000002900a0  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #12  pc 0x000000000011e7c0  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.odex (art_jni_trampoline+144)
  #13  pc 0x000000000020b0d4  /apex/com.android.art/lib64/libart.so (nterp_helper+7636)
  #14  pc 0x0000000000a6a16e  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (com.mapbox.maps.NativeMapImpl.addStyleSource+24)
  #15  pc 0x000000000020b074  /apex/com.android.art/lib64/libart.so (nterp_helper+7540)
  #16  pc 0x0000000000a6b372  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (com.mapbox.maps.Style.addStyleSource+34)
  #17  pc 0x000000000020b074  /apex/com.android.art/lib64/libart.so (nterp_helper+7540)
  #18  pc 0x0000000000a6d266  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (com.mapbox.maps.extension.style.sources.Source.bindTo+26)
  #19  pc 0x000000000020b074  /apex/com.android.art/lib64/libart.so (nterp_helper+7540)
  #20  pc 0x0000000000a6d142  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (com.mapbox.maps.extension.style.sources.SourceUtils.addSource+20)
  #21  pc 0x0000000000209334  /apex/com.android.art/lib64/libart.so (nterp_helper+52)
  #22  pc 0x0000000000446f2c  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (<package-name>.mapbox.RNTMapBoxManager.addRainLayers$lambda-15+114)
  #23  pc 0x0000000000209334  /apex/com.android.art/lib64/libart.so (nterp_helper+52)
  #24  pc 0x0000000000446de4  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (<package-name>.mapbox.RNTMapBoxManager.$r8$lambda$d5jX8hXe0UUuLMoWbY5rpqV3CJA)
  #25  pc 0x0000000000209334  /apex/com.android.art/lib64/libart.so (nterp_helper+52)
  #26  pc 0x00000000004469e2  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (<package-name>.mapbox.RNTMapBoxManager$$ExternalSyntheticLambda2.onStyleLoaded+8)
  #27  pc 0x000000000020b074  /apex/com.android.art/lib64/libart.so (nterp_helper+7540)
  #28  pc 0x0000000000a69dec  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (com.mapbox.maps.MapboxMap.getStyle+36)
  #29  pc 0x000000000020a254  /apex/com.android.art/lib64/libart.so (nterp_helper+3924)
  #30  pc 0x000000000044708e  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (<package-name>.mapbox.RNTMapBoxManager.addRainLayers+52)
  #31  pc 0x000000000020a254  /apex/com.android.art/lib64/libart.so (nterp_helper+3924)
  #32  pc 0x00000000004475b6  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (<package-name>.mapbox.RNTMapBoxManager.setupMapboxMap$lambda-5$lambda-3+68)
  #33  pc 0x0000000000209334  /apex/com.android.art/lib64/libart.so (nterp_helper+52)
  #34  pc 0x0000000000446e08  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (<package-name>.mapbox.RNTMapBoxManager.$r8$lambda$sB5To4RDvLADj1jbtVceseii_9c)
  #35  pc 0x0000000000209334  /apex/com.android.art/lib64/libart.so (nterp_helper+52)
  #36  pc 0x000000000044699a  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/oat/arm64/base.vdex (<package-name>.mapbox.RNTMapBoxManager$$ExternalSyntheticLambda0.onStyleLoaded+4)
  #37  pc 0x000000000200e5b4  /memfd:jit-cache (com.mapbox.maps.NativeObserver.notify+5796)
  #38  pc 0x000000000045836c  /apex/com.android.art/lib64/libart.so (art_quick_invoke_stub+556)
  #39  pc 0x00000000004edd28  /apex/com.android.art/lib64/libart.so (art::JValue art::InvokeVirtualOrInterfaceWithVarArgs<art::ArtMethod*>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, art::ArtMethod*, std::__va_list)+856)
  #40  pc 0x00000000005ed5c8  /apex/com.android.art/lib64/libart.so (art::JNI<false>::CallVoidMethodV(_JNIEnv*, _jobject*, _jmethodID*, std::__va_list)+184)
  #41  pc 0x000000000023c4a0  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #42  pc 0x000000000023c470  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #43  pc 0x0000000000276170  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #44  pc 0x00000000002b1ef8  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #45  pc 0x00000000004bd790  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-maps.so
  #46  pc 0x000000000018cdb8  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-common.so (mapbox::common::platform::processTask(std::__ndk1::function<void ()> const&)+32)
  #47  pc 0x000000000018b370  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-common.so
  #48  pc 0x000000000018bad0  /data/app/~~h9QXU5S9YSNhgaKc_vz7pQ==/<package-name>-ZJQUvgTw2SU9RUq0Yf2EvQ==/split_config.arm64_v8a.apk!libmapbox-common.so
  #49  pc 0x0000000000018028  /system/lib64/libutils.so (android::Looper::pollInner(int)+1064)
  #50  pc 0x0000000000017b9c  /system/lib64/libutils.so (android::Looper::pollOnce(int, int*, int*, void**)+116)
  #51  pc 0x00000000001689ac  /system/lib64/libandroid_runtime.so (android::android_os_MessageQueue_nativePollOnce(_JNIEnv*, _jobject*, long, int)+48)
  #52  pc 0x00000000002ec504  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (art_jni_trampoline+116)
  #53  pc 0x0000000000ad48c8  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (android.os.MessageQueue.next+312)
  #54  pc 0x0000000000ad0c98  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (android.os.Looper.loopOnce+104)
  #55  pc 0x0000000000ad0afc  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (android.os.Looper.loop+1148)
  #56  pc 0x00000000007d9ef8  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (android.app.ActivityThread.main+1480)
  #57  pc 0x0000000000458600  /apex/com.android.art/lib64/libart.so (art_quick_invoke_static_stub+576)
  #58  pc 0x000000000048b39c  /apex/com.android.art/lib64/libart.so (_jobject* art::InvokeMethod<(art::PointerSize)8>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, _jobject*, _jobject*, unsigned long)+1560)
  #59  pc 0x000000000048ad5c  /apex/com.android.art/lib64/libart.so (art::Method_invoke(_JNIEnv*, _jobject*, _jobject*, _jobjectArray*) (.__uniq.165753521025965369065708152063621506277)+48)
  #60  pc 0x00000000002f2148  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (art_jni_trampoline+120)
  #61  pc 0x0000000000a38a20  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run+144)
  #62  pc 0x0000000000a438c4  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (com.android.internal.os.ZygoteInit.main+3604)
  #63  pc 0x0000000000458600  /apex/com.android.art/lib64/libart.so (art_quick_invoke_static_stub+576)
  #64  pc 0x0000000000589dfc  /apex/com.android.art/lib64/libart.so (art::JValue art::InvokeWithVarArgs<_jmethodID*>(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, _jmethodID*, std::__va_list)+912)
  #65  pc 0x0000000000606de4  /apex/com.android.art/lib64/libart.so (art::JNI<true>::CallStaticVoidMethodV(_JNIEnv*, _jclass*, _jmethodID*, std::__va_list)+160)
  #66  pc 0x00000000000c1c04  /system/lib64/libandroid_runtime.so (_JNIEnv::CallStaticVoidMethod(_jclass*, _jmethodID*, ...)+124)
  #67  pc 0x00000000000ce470  /system/lib64/libandroid_runtime.so (android::AndroidRuntime::start(char const*, android::Vector<android::String8> const&, bool)+856)
  #68  pc 0x0000000000002570  /system/bin/app_process64 (main+1304)
  #69  pc 0x00000000000854ec  /apex/com.android.runtime/lib64/bionic/libc.so (__libc_init+100)
SamuelBrucksch commented 11 months ago

Hi, anything new on this? We can't downgrade to 21 due to react-native, and it still works for most users, but we still randomly see crashes after an update.

yunikkk commented 11 months ago

@SamuelBrucksch unfortunately no updates yet - but Maps v11 will be shipped with the updated NDK 23 compatible with newer react native, v10 is only compatible with NDK 21.

it still works for most users

It will work fine for users until any c++ exception is raised internally - then it crashes since exceptions are incompatible between NDK 21/23.

The solution for now is to either stick with older ReactNative, wait for Maps v11 or, alternatively - rebuild it from source, seems it is supported https://reactnative.dev/contributing/how-to-build-from-source.