apache / incubator-weex

Apache Weex (Incubating)
https://weex.apache.org
Apache License 2.0
13.75k stars 1.82k forks source link

[iOS] -[WXBridgeManager _runLoopThread] [NSThread main] occasionally Crash after init where weex version is 0.26.0 #3119

Open ChenMengqi opened 4 years ago

ChenMengqi commented 4 years ago

[WXBridgeManager _runLoopThread] [NSThread main] occasionally Crash after init in iOS13 . It happened when I use Weex in version 0.18.0. And after I update to version 0.26.0. The crash is still there.

And I try to change the time of [WXSDKEngine initSDKEnvironment]. It happens more crash when init just before the first time using weex than init after app launch.

here's the fabric crash stack:

Crashed: com.taobao.weex.backup.bridge 0 libsystem_pthread.dylib 0x1992d0168 pthread_mutex_lock$VARIANT$armv81 + 102 1 CoreFoundation 0x199531e2c CFRunLoopSourceSignal + 56 2 Foundation 0x19999fa2c performQueueDequeue + 504 3 Foundation 0x19999f1b0 NSThreadPerformPerform + 108 4 CoreFoundation 0x199534a00 CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION + 24 5 CoreFoundation 0x199534958 CFRunLoopDoSource0 + 80 6 CoreFoundation 0x199534140 CFRunLoopDoSources0 + 260 7 CoreFoundation 0x19952f23c CFRunLoopRun + 1080 8 CoreFoundation 0x19952eadc CFRunLoopRunSpecific + 464 9 Foundation 0x19986e7f4 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 228 10 MyApp 0x1032bcd04 -[WXBridgeManager _runLoopThread] + 93 (WXBridgeManager.m:93) 11 Foundation 0x19999f0a4 NSThreadstart__ + 848 12 libsystem_pthread.dylib 0x1992d1d8c _pthread_start + 156 13 libsystem_pthread.dylib 0x1992d576c thread_start + 8

Crashed: com.taobao.weex.backup.bridge 0 libsystem_pthread.dylib 0x1948cafb4 pthread_mutex_lock + 102 1 CoreFoundation 0x194b344e4 CFRunLoopSourceSignal + 60 2 (Missing) 0x0 (Missing) 3 (Missing) 0x1e179d8194fb0c00 (Missing) 4 (Missing) 0x0 (Missing) 5 (Missing) 0x491b470194b37000 (Missing) 6 (Missing) 0x0 (Missing) 7 (Missing) 0x753cc8194b317c0 (Missing) 8 (Missing) 0x0 (Missing) 9 (Missing) 0x157a5d8194e76400 (Missing) 10 (Missing) 0xc08ef010365cd00 (Missing) 11 Foundation 0x194e75034 -[NSThread main] + 40 12 (Missing) 0x5d3e2e0194fb0c00 (Missing) 13 (Missing) 0x0 (Missing) 14 (Missing) 0x0 (Missing)

It happens in version 0.18.0 to version 0.26.0...

These 2 crash mostly happen in iOS 13.

please help.

ChenMengqi commented 4 years ago

Crashed: com.taobao.weex.component EXC_BAD_ACCESS KERN_INVALID_ADDRESS 0x000073ad67c535b0

Crashed: com.taobao.weex.component 0 libsystem_pthread.dylib 0x1a515fecc pthread_mutex_lock$VARIANT$mp + 126 1 CoreFoundation 0x1a53c5e2c CFRunLoopSourceSignal + 56 2 Foundation 0x1a5833a2c performQueueDequeue + 504 3 Foundation 0x1a58331b0 NSThreadPerformPerform + 108 4 CoreFoundation 0x1a53c8a00 CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION + 24 5 CoreFoundation 0x1a53c8958 CFRunLoopDoSource0 + 80 6 CoreFoundation 0x1a53c8140 CFRunLoopDoSources0 + 260 7 CoreFoundation 0x1a53c323c CFRunLoopRun + 1080 8 CoreFoundation 0x1a53c2adc CFRunLoopRunSpecific + 464 9 Foundation 0x1a57027f4 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 228 10 MyApp 0x1062145c0 -[WXComponentManager _runLoopThread] + 180 (WXComponentManager.mm:180) 11 Foundation 0x1a58330a4 NSThreadstart__ + 848 12 libsystem_pthread.dylib 0x1a5165d8c _pthread_start + 156 13 libsystem_pthread.dylib 0x1a516976c thread_start + 8

similar crash in WXComponentManager.mm line 180 -[WXComponentManager _runLoopThread]

also iOS 13 only

bravegogo commented 4 years ago

我也遇到这个crash了

cnryb commented 4 years ago

Does the same problem exist in v0.28.0?

ChenMengqi commented 4 years ago

Does the same problem exist in v0.28.0?

I don't Konw. We get rid of Weex now.

bravegogo commented 4 years ago

Does the same problem exist in v0.28.0?

0.28 exist the same problem ,too