I'm getting the below output in my code randomly (not related to any action that I can identify) when my application crashes. Can some one help me decipher what this logcat output means?
I've truncated a large portion of the text that seems to list out the various threads along with their States (waiting, timed-waiting, blocked, etc. . ) along with the stacktrace for the method calls on that thread.
07-31 14:39:40.455 942-947/com.salesrabbit.android.sales.universal A/art: art/runtime/jdwp/jdwp_event.cc:681] Check failed: threadId != 0u (threadId=0, 0u=0)
07-31 14:39:43.283 942-947/com.salesrabbit.android.sales.universal A/art: art/runtime/runtime.cc:422] Runtime aborting...
art/runtime/runtime.cc:422] Aborting thread:
art/runtime/runtime.cc:422] "Jit thread pool worker thread 0" prio=5 tid=2 WaitingForDebuggerSend (still starting up)
art/runtime/runtime.cc:422] | group="" sCount=0 dsCount=0 obj=0x0 self=0xa8617000
art/runtime/runtime.cc:422] | sysTid=947 nice=9 cgrp=default sched=0/0 handle=0xaf2a3920
art/runtime/runtime.cc:422] | state=R schedstat=( 8833095069 6087499776 14348 ) utm=557 stm=325 core=2 HZ=100
art/runtime/runtime.cc:422] | stack=0xaf1a5000-0xaf1a7000 stackSize=1022KB
art/runtime/runtime.cc:422] | held mutexes= "abort lock"
art/runtime/runtime.cc:422] native: #00 pc 00351069 /system/lib/libart.so (_ZN3art15DumpNativeStackERNSt3__113basic_ostreamIcNS0_11char_traitsIcEEEEiP12BacktraceMapPKcPNS_9ArtMethodEPv+128)
art/runtime/runtime.cc:422] native: #01 pc 00331729 /system/lib/libart.so (_ZNK3art6Thread9DumpStackERNSt3__113basic_ostreamIcNS1_11char_traitsIcEEEEbP12BacktraceMap+304)
art/runtime/runtime.cc:422] native: #02 pc 003247a1 /system/lib/libart.so (_ZNK3art10AbortState10DumpThreadERNSt3__113basic_ostreamIcNS1_11char_traitsIcEEEEPNS_6ThreadE+24)
art/runtime/runtime.cc:422] native: #03 pc 00324629 /system/lib/libart.so (_ZNK3art10AbortState4DumpERNSt3__113basic_ostreamIcNS1_11char_traitsIcEEEE+424)
art/runtime/runtime.cc:422] native: #04 pc 0031b351 /system/lib/libart.so (_ZN3art7Runtime5AbortEPKc+92)
art/runtime/runtime.cc:422] native: #05 pc 000b526b /system/lib/libart.so (_ZN3art10LogMessageD2Ev+1134)
art/runtime/runtime.cc:422] native: #06 pc 00240305 /system/lib/libart.so (_ZN3art4JDWP9JdwpState19SetWaitForJdwpTokenEy+708)
art/runtime/runtime.cc:422] native: #07 pc 0023fb51 /system/lib/libart.so (_ZN3art4JDWP9JdwpState24AcquireJdwpTokenForEventEy+76)
art/runtime/runtime.cc:422] native: #08 pc 0023f5e1 /system/lib/libart.so (_ZN3art4JDWP9JdwpState29SendRequestAndPossiblySuspendEPNS0_9ExpandBufENS0_17JdwpSuspendPolicyEy+180)
art/runtime/runtime.cc:422] native: #09 pc 0024301b /system/lib/libart.so (_ZN3art4JDWP9JdwpState16PostClassPrepareEPNS_6mirror5ClassE+914)
art/runtime/runtime.cc:422] native: #10 pc 000e4db5 /system/lib/libart.so (_ZN3art11ClassLinker11DefineClassEPNS_6ThreadEPKcjNS_6HandleINS_6mirror11ClassLoaderEEERKNS_7DexFileERKNS9_8ClassDefE+560)
art/runtime/runtime.cc:422] native: #11 pc 000e4a15 /system/lib/libart.so (_ZN3art11ClassLinker26FindClassInPathClassLoaderERNS_33ScopedObjectAccessAlreadyRunnableEPNS_6ThreadEPKcjNS_6HandleINS_6mirror11ClassLoaderEEEPPNS8_5ClassE+1016)
art/runtime/runtime.cc:422] native: #12 pc 000e55ef /system/lib/libart.so (_ZN3art11ClassLinker9FindClassEPNS_6ThreadEPKcNS_6HandleINS_6mirror11ClassLoaderEEE+658)
art/runtime/runtime.cc:422] native: #13 pc 000d2a3d /system/lib/libart.so (_ZN3art11ClassLinker11ResolveTypeERKNS_7DexFileEtNS_6HandleINS_6mirror8DexCacheEEENS4_INS5_11ClassLoaderEEE+132)
art/runtime/runtime.cc:422] native: #14 pc 001354bd /system/lib/libart-compiler.so (_ZNK3art19HInstructionBuilder25IsOutermostCompilingClassEt+528)
art/runtime/runtime.cc:422] native: #15 pc 00134e5b /system/lib/libart-compiler.so (_ZN3art19HInstructionBuilder16BuildNewInstanceEtj+626)
art/runtime/runtime.cc:422] native: #16 pc 0012ffe7 /system/lib/libart-compiler.so (_ZN3art19HInstructionBuilder21ProcessDexInstructionERKNS_11InstructionEj+3522)
art/runtime/runtime.cc:422] native: #17 pc 0012ece9 /system/lib/libart-compiler.so (_ZN3art19HInstructionBuilder5BuildEv+1176)
art/runtime/runtime.cc:422] native: #18 pc 00113b79 /system/lib/libart-compiler.so (_ZN3art13HGraphBuilder10BuildGraphEv+84)
art/runtime/runtime.cc:422] native: #19 pc 00157ea9 /system/lib/libart-compiler.so (_ZNK3art18OptimizingCompiler10TryCompileEPNS_14ArenaAllocatorEPNS_19CodeVectorAllocatorEPKNS_7DexFile8CodeItemEjNS_10InvokeTypeEtjP8_jobjectRKS5_NS_6HandleINS_6mirror8DexCacheEEEPNS_9ArtMethodEb+2452)
art/runtime/runtime.cc:422] native: #20 pc 00159ae3 /system/lib/libart-compiler.so (_ZN3art18OptimizingCompiler10JitCompileEPNS_6ThreadEPNS_3jit12JitCodeCacheEPNS_9ArtMethodEb+330)
art/runtime/runtime.cc:422] native: #21 pc 00108e1f /system/lib/libart-compiler.so (_ZN3art3jit11JitCompiler13CompileMethodEPNS_6ThreadEPNS_9ArtMethodEb+194)
art/runtime/runtime.cc:422] native: #22 pc 00250473 /system/lib/libart.so (_ZN3art3jit3Jit13CompileMethodEPNS_9ArtMethodEPNS_6ThreadEb+318)
art/runtime/runtime.cc:422] native: #23 pc 00251b97 /system/lib/libart.so (_ZN3art3jit14JitCompileTask3RunEPNS_6ThreadE+430)
art/runtime/runtime.cc:422] native: #24 pc 003445a1 /system/lib/libart.so (_ZN3art16ThreadPoolWorker3RunEv+44)
art/runtime/runtime.cc:422] native: #25 pc 003440d9 /system/lib/libart.so (_ZN3art16ThreadPoolWorker8CallbackEPv+64)
art/runtime/runtime.cc:422] native: #26 pc 00047093 /system/lib/libc.so (_ZL15__pthread_startPv+22)
art/runtime/runtime.cc:422] native: #27 pc 00019bdd /system/lib/libc.so (__start_thread+6)
art/runtime/runtime.cc:422] (no managed stack frames)
art/runtime/runtime.cc:422] Dumping all threads without appropriate locks held: thread list lock mutator lock
art/runtime/runtime.cc:422] All threads:
07-31 14:39:43.285 942-947/com.salesrabbit.android.sales.universal A/art: art/runtime/runtime.cc:422] DALVIK THREADS (470):
art/runtime/runtime.cc:422] "Jit thread pool worker thread 0" prio=5 tid=2 Runnable (still starting up)
art/runtime/runtime.cc:422] | group="" sCount=0 dsCount=0 obj=0x0 self=0xa8617000
art/runtime/runtime.cc:422] | sysTid=947 nice=9 cgrp=default sched=0/0 handle=0xaf2a3920
art/runtime/runtime.cc:422] | state=R schedstat=( 9523364645 6173422596 15193 ) utm=559 stm=392 core=0 HZ=100
art/runtime/runtime.cc:422] | stack=0xaf1a5000-0xaf1a7000 stackSize=1022KB
art/runtime/runtime.cc:422] | held mutexes= "abort lock" "mutator lock"(shared held)
art/runtime/runtime.cc:422] native: #00 pc 00351069 /system/lib/libart.so (_ZN3art15DumpNativeStackERNSt3__113basic_ostreamIcNS0_11char_traitsIcEEEEiP12BacktraceMapPKcPNS_9ArtMethodEPv+128)
art/runtime/runtime.cc:422] native: #01 pc 00331729 /system/lib/libart.so (_ZNK3art6Thread9DumpStackERNSt3__113basic_ostreamIcNS1_11char_traitsIcEEEEbP12BacktraceMap+304)
art/runtime/runtime.cc:422] native: #02 pc 0034382f /system/lib/libart.so (_ZN3art14DumpCheckpoint3RunEPNS_6T
I've truncated a bunch of other threads:
--------- beginning of crash
07-31 14:39:43.630 942-947/com.salesrabbit.android.sales.universal A/libc: Fatal signal 6 (SIGABRT), code -6 in tid 947 (Jit thread pool)
EDIT 1
I updated my android studio from 3.0.1 to 3.1.3 (as well as gradle) yesterday and the issue went away until today after lunch it randomly came back. I tried invalidating the cache and restating android studio but it did not have any affect. I still get this crash about 2 minutes after building/installing the app on a test device. It happens on all of our test devices.
EDIT 2
I just discovered that if I turned off all my breakpoints the crash goes away. If I put the break point back the crash come back. This is very annoying!
In the code below, if I put a break point on db.endTransaction()
, the app crashes. Why? How can I fix this?
return Single.just(page)
.map {
val db: Database = daoSession.database
db.beginTransaction()
. . . .
db.setTransactionSuccessful()
db.endTransaction()
return@map page
}
.map {
geoCodeAsNeeded(page.addressToGeoCode)
return@map page
}
.map {
return someMethod()
}
.subscribeOn(Schedulers.io())