我在使用Xamarin Forms应用程序时在iOS上遇到问题,在我使用它时突然崩溃。
我注意到崩溃主要发生在我' m:
使用多个选择器(填写一些表单数据)
快速浏览网页(这是一份调查问卷,因此用户应该快速向前导航)。
这是我在HockeyApp上捕获的崩溃报告的一些部分:
Hardware Model: iPad6,11
...
Parent Process: ??? [1]
Date/Time: 2017-06-30T11:54:16Z
Launch Time: 2017-06-30T11:42:03Z
OS Version: iPhone OS 10.3.2 (14F90)
Report Version: 104
Exception Type: SIGSEGV
Exception Codes: SEGV_ACCERR at 0x10
Crashed Thread: 15
Application Specific Information:
Selector name found in current argument registers: configureAnimation:forLayer:forKey:
...
我还注意到,在使用OS 10.3时,这种崩溃只发生在我身上 我将我的Xamarin.Forms更新为2.3.4.247,但没有任何改变。
这是我在Visual Studio 2017上使用模拟器进行调试时获得的Native stacktrace
MIRE_v2.iOS 0x0000000101b195c1 mono_handle_native_crash + 257
MIRE_v2.iOS 0x0000000101b255c0 mono_sigsegv_signal_handler + 288
libsystem_platform.dylib 0x000000010ea23b3a _sigtramp + 26
??? 0x00007fdc4f00163c 0x0 + 140584194938428
UIKit 0x00000001025934c8 -[UIViewAnimationState actionForLayer:forKey:forView:] + 99
UIKit 0x00000001025be87e +[UIView(Animation) _defaultUIViewActionForLayer:forKey:] + 111
UIKit 0x0000000102d9d3e4 -[UIView(UIKitManual) actionForLayer:forKey:] + 119
QuartzCore 0x00000001086014bc -[CALayer actionForKey:] + 437
QuartzCore 0x00000001085fcade _ZL12actionForKeyP7CALayerPN2CA11TransactionEP8NSString + 76
QuartzCore 0x00000001085fca6c _ZN2CA5Layer12begin_changeEPNS_11TransactionEjRP11objc_object + 140
QuartzCore 0x00000001085fce04 _ZN2CA5Layer6setterEj12_CAValueTypePKv + 164
QuartzCore 0x0000000108608351 -[CALayer setOpacity:] + 43
MIRE_v2.iOS 0x0000000101cc9d79 xamarin_dyn_objc_msgSend + 217
??? 0x00000001269fc8f4 0x0 + 4942973172
??? 0x0000000126b13b4d 0x0 + 4944116557
??? 0x00000001266a291c 0x0 + 4939458844
MIRE_v2.iOS 0x0000000101b28525 mono_jit_runtime_invoke + 1301
MIRE_v2.iOS 0x0000000101bd9b58 do_runtime_invoke + 88
MIRE_v2.iOS 0x0000000101c1b4da start_wrapper + 538
MIRE_v2.iOS 0x0000000101c9cdcd inner_start_thread + 189
libsystem_pthread.dylib 0x000000010ea3593b _pthread_body + 180
libsystem_pthread.dylib 0x000000010ea35887 _pthread_body + 0
libsystem_pthread.dylib 0x000000010ea3508d thread_start + 13
这是运行模拟器的Mac崩溃日志中的一小部分(崩溃的线程,日志很长):
Thread 10 Crashed:: tid_7327
0 libsystem_kernel.dylib 0x000000010ea00d42 __pthread_kill + 10
1 libsystem_pthread.dylib 0x000000010ea38457 pthread_kill + 90
2 libsystem_c.dylib 0x000000010e79288f abort + 127
3 com.sf.rf 0x0000000101b19737 mono_handle_native_crash + 631 (mini-exceptions.c:2560)
4 com.sf.rf 0x0000000101b255c0 mono_sigsegv_signal_handler + 288 (mini-runtime.c:2870)
5 libsystem_platform.dylib 0x000000010ea23b3a _sigtramp + 26
6 ??? 0x00007fdc4f00163c 0 + 140584194938428
7 com.apple.UIKit 0x00000001025934c8 -[UIViewAnimationState actionForLayer:forKey:forView:] + 99
8 com.apple.UIKit 0x00000001025be87e +[UIView(Animation) _defaultUIViewActionForLayer:forKey:] + 111
9 com.apple.UIKit 0x0000000102d9d3e4 -[UIView(UIKitManual) actionForLayer:forKey:] + 119
10 com.apple.QuartzCore 0x00000001086014bc -[CALayer actionForKey:] + 437
11 com.apple.QuartzCore 0x00000001085fcade actionForKey(CALayer*, CA::Transaction*, NSString*) + 76
12 com.apple.QuartzCore 0x00000001085fca6c CA::Layer::begin_change(CA::Transaction*, unsigned int, objc_object*&) + 140
13 com.apple.QuartzCore 0x00000001085fce04 CA::Layer::setter(unsigned int, _CAValueType, void const*) + 164
14 com.apple.QuartzCore 0x0000000108608351 -[CALayer setOpacity:] + 43
15 com.sf.rf 0x0000000101cc9d79 xamarin_dyn_objc_msgSend + 217 (.trampolines-x86_64-objc_msgSend-post.inc:3)
16 ??? 0x00000001269fc8f4 0 + 4942973172
17 ??? 0x0000000126b13b4d 0 + 4944116557
18 ??? 0x00000001266a291c 0 + 4939458844
19 com.sf.rf 0x0000000101b28525 mono_jit_runtime_invoke + 1301 (mini-runtime.c:2533)
20 com.sf.rf 0x0000000101bd9b58 do_runtime_invoke + 88 (object.c:2860)
21 com.sf.rf 0x0000000101c1b4da start_wrapper + 538 (threads.c:847)
22 com.sf.rf 0x0000000101c9cdcd inner_start_thread + 189 (mono-threads.c:1172)
23 libsystem_pthread.dylib 0x000000010ea3593b _pthread_body + 180
24 libsystem_pthread.dylib 0x000000010ea35887 _pthread_start + 286
25 libsystem_pthread.dylib 0x000000010ea3508d thread_start + 13
有关此行为原因的任何想法?或者如何处理它?</ p>
谢谢。
修改
这是另一份可能提供更多信息的报告:
Thread 11 Crashed:: tid_9017
0 libobjc.A.dylib 0x000000010c116acb objc_msgSend + 11
1 com.apple.UIKit 0x0000000100d427a6 -[UIViewAnimationState animationForLayer:forKey:forView:] + 1164
2 com.apple.UIKit 0x0000000100d434c8 -[UIViewAnimationState actionForLayer:forKey:forView:] + 99
3 com.apple.UIKit 0x0000000100d6e87e +[UIView(Animation) _defaultUIViewActionForLayer:forKey:] + 111
4 com.apple.UIKit 0x000000010154d3e4 -[UIView(UIKitManual) actionForLayer:forKey:] + 119
5 com.apple.QuartzCore 0x0000000106e4d4bc -[CALayer actionForKey:] + 437
6 com.apple.QuartzCore 0x0000000106e48ade actionForKey(CALayer*, CA::Transaction*, NSString*) + 76
7 com.apple.QuartzCore 0x0000000106e48a6c CA::Layer::begin_change(CA::Transaction*, unsigned int, objc_object*&) + 140
8 com.apple.QuartzCore 0x0000000106e48e04 CA::Layer::setter(unsigned int, _CAValueType, void const*) + 164
9 com.apple.QuartzCore 0x0000000106e54351 -[CALayer setOpacity:] + 43
10 com.sf.rf 0x0000000100479d79 xamarin_dyn_objc_msgSend + 217 (.trampolines-x86_64-objc_msgSend-post.inc:3)
11 ??? 0x0000000125584af4 0 + 4921510644
12 ??? 0x000000012645f2fd 0 + 4937085693
13 ??? 0x0000000125373c8c 0 + 4919344268
14 com.sf.rf 0x00000001002d8525 mono_jit_runtime_invoke + 1301 (mini-runtime.c:2533)
15 com.sf.rf 0x0000000100389b58 do_runtime_invoke + 88 (object.c:2860)
16 com.sf.rf 0x00000001003cb4da start_wrapper + 538 (threads.c:847)
17 com.sf.rf 0x000000010044cdcd inner_start_thread + 189 (mono-threads.c:1172)
18 libsystem_pthread.dylib 0x000000010d1e593b _pthread_body + 180
19 libsystem_pthread.dylib 0x000000010d1e5887 _pthread_start + 286
20 libsystem_pthread.dylib 0x000000010d1e508d thread_start + 13
注意:
我还注意到,当我点击一些分配了触发器的按钮(点击时改变它们的外观)时就会发生崩溃。