分析Apple崩溃报告

时间:2016-05-02 19:04:29

标签: ios swift crash

我的应用在评论期间被拒绝,我收到了崩溃报告。

他们说App会在启动时崩溃。

我用Xcode 7标记了崩溃报告。

我找不到错误。有人能帮助我吗?

Incident Identifier: 7F51C648-88CD-4140-8AEA-08E9738BC080
CrashReporter Key:   26c02c90683f836314c526cecc4cd8fa6f92528c
Hardware Model:      xxx
Process:             MyApp [594]
Path:                /private/var/containers/Bundle/Application/DCA01744-B65D-4F46-BF63-6B55C050E90E/MyApp.app/MyApp
Identifier:          any.MyApp
Version:             7 (6.5)
Code Type:           ARM-64 (Native)
Parent Process:      launchd [1]

Date/Time:           2016-04-16 12:43:47.47 -0700
Launch Time:         2016-04-16 12:43:45.45 -0700
OS Version:          iOS 9.3.1 (13E238)
Report Version:      105

Exception Type:  EXC_BREAKPOINT (SIGTRAP)
Exception Codes: 0x0000000000000001, 0x0000000100036910
Triggered by Thread:  0

Filtered syslog:
None found

Thread 0 name:  Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0   MyApp                           0x0000000100036910 0x100024000 + 76048
1   MyApp                           0x00000001000300a0 0x100024000 + 49312
2   MyApp                           0x0000000100030198 0x100024000 + 49560
3   UIKit                           0x0000000187778b40 -[UIViewController loadViewIfRequired] + 996
4   UIKit                           0x0000000187839118 -[UINavigationController _layoutViewController:] + 72
5   UIKit                           0x0000000187838ff0 -[UINavigationController _updateScrollViewFromViewController:toViewController:] + 416
6   UIKit                           0x0000000187838238 -[UINavigationController _startTransition:fromViewController:toViewController:] + 144
7   UIKit                           0x0000000187837ddc -[UINavigationController _startDeferredTransitionIfNeeded:] + 868
8   UIKit                           0x0000000187837a04 -[UINavigationController __viewWillLayoutSubviews] + 60
9   UIKit                           0x000000018783796c -[UILayoutContainerView layoutSubviews] + 208
10  UIKit                           0x00000001877740e4 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 656
11  QuartzCore                      0x000000018511aa28 -[CALayer layoutSublayers] + 148
12  QuartzCore                      0x0000000185115634 CA::Layer::layout_if_needed(CA::Transaction*) + 292
13  QuartzCore                      0x00000001851154f4 CA::Layer::layout_and_display_if_needed(CA::Transaction*) + 32
14  QuartzCore                      0x0000000185114b24 CA::Context::commit_transaction(CA::Transaction*) + 252
15  QuartzCore                      0x000000018511486c CA::Transaction::commit() + 512
16  QuartzCore                      0x000000018510ddd8 CA::Transaction::observer_callback(__CFRunLoopObserver*, unsigned long, void*) + 80
17  CoreFoundation                  0x00000001825ec7b0 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 32
18  CoreFoundation                  0x00000001825ea554 __CFRunLoopDoObservers + 372
19  CoreFoundation                  0x0000000182514d30 CFRunLoopRunSpecific + 416
20  UIKit                           0x00000001877e7834 -[UIApplication _run] + 460
21  UIKit                           0x00000001877e1f70 UIApplicationMain + 204
22  MyApp                           0x000000010006a5ec 0x100024000 + 288236
23  libdyld.dylib                   0x00000001820b28b8 start + 4

Thread 1 name:  Dispatch queue: com.apple.libdispatch-manager
Thread 1:
0   libsystem_kernel.dylib          0x00000001821d14d8 kevent_qos + 8
1   libdispatch.dylib               0x00000001820947d8 _dispatch_mgr_invoke + 232
2   libdispatch.dylib               0x0000000182083648 _dispatch_source_invoke + 0

Thread 2:
0   libsystem_kernel.dylib          0x00000001821d0b48 __workq_kernreturn + 8
1   libsystem_pthread.dylib         0x0000000182299530 _pthread_wqthread + 1284
2   libsystem_pthread.dylib         0x0000000182299020 start_wqthread + 4

Thread 3:
0   libsystem_kernel.dylib          0x00000001821d0b48 __workq_kernreturn + 8
1   libsystem_pthread.dylib         0x0000000182299530 _pthread_wqthread + 1284
2   libsystem_pthread.dylib         0x0000000182299020 start_wqthread + 4

Thread 4:
0   libsystem_kernel.dylib          0x00000001821d0b48 __workq_kernreturn + 8
1   libsystem_pthread.dylib         0x0000000182299530 _pthread_wqthread + 1284
2   libsystem_pthread.dylib         0x0000000182299020 start_wqthread + 4

Thread 5 name:  com.apple.coremedia.player.async
Thread 5:
0   libsystem_kernel.dylib          0x00000001821b5014 semaphore_wait_trap + 8
1   libdispatch.dylib               0x00000001820923e8 _dispatch_semaphore_wait_slow + 244
2   MediaToolbox                    0x00000001885ad6d0 fpa_AsyncMovieControlThread + 1948
3   CoreMedia                       0x00000001849eeda0 figThreadMain + 272
4   libsystem_pthread.dylib         0x000000018229bb28 _pthread_body + 156
5   libsystem_pthread.dylib         0x000000018229ba8c _pthread_body + 0
6   libsystem_pthread.dylib         0x0000000182299028 thread_start + 4

Thread 6:
0   libsystem_kernel.dylib          0x00000001821d0b48 __workq_kernreturn + 8
1   libsystem_pthread.dylib         0x0000000182299530 _pthread_wqthread + 1284
2   libsystem_pthread.dylib         0x0000000182299020 start_wqthread + 4

Thread 0 crashed with ARM Thread State (64-bit):
    x0: 0x0000000000000000   x1: 0x0000000000000000   x2: 0x00000001566207f8   x3: 0x0000000156548400
    x4: 0x0000000000000007   x5: 0x0000000000000000   x6: 0x0000000000000000   x7: 0x0000000000000830
    x8: 0x0000000000000000   x9: 0x00000001a08300e0  x10: 0x000001a1a083a289  x11: 0x000000150000001f
   x12: 0x0000000156508940  x13: 0x000021a1a083a289  x14: 0x0000000000000010  x15: 0x0000000073935b34
   x16: 0x0000000181cb5ef0  x17: 0x0000000181cb68dc  x18: 0x0000000000000000  x19: 0x000000015654e3e0
   x20: 0xa00000000352e363  x21: 0x0000000156505ea0  x22: 0x00000001000b7e00  x23: 0x00000001000b6000
   x24: 0x0000000156548400  x25: 0x0000000100321600  x26: 0x0000000100321600  x27: 0x0000000100321600
   x28: 0xa00000000352e363  fp: 0x000000016fdd9df0   lr: 0x00000001000366ac
    sp: 0x000000016fdd9d90   pc: 0x0000000100036910 cpsr: 0x60000000

2 个答案:

答案 0 :(得分:2)

表格Apple文档:

  

跟踪陷阱[EXC_BREAKPOINT // SIGTRAP]

     

与异常退出类似,此异常旨在提供   附加调试器有机会在特定的情况下中断进程   指出它的执行。您可以从自己的触发器中触发此异常   代码使用__builtin_trap()函数。如果没有附加调试器,   该流程终止,并生成崩溃报告。

     

如果是,Swift代码将使用此异常类型终止程序   在运行时检测到意外情况,例如:

     

非可选类型,其nil值为强制类型转换失败   查看崩溃线程的Backtrace以确定其中的位置   遇到意外情况。可能有其他信息   也已登录到设备的控制台。

Sourse:https://developer.apple.com/library/ios/technotes/tn2151/_index.html

希望这会对你有所帮助。

答案 1 :(得分:1)

这些行是你的崩溃:

Thread 0 name:  Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0   MyApp                           0x0000000100036910 0x100024000 + 76048
1   MyApp                           0x00000001000300a0 0x100024000 + 49312
2   MyApp                           0x0000000100030198 0x100024000 + 49560

问题是您的崩溃日志没有符号化。您可以使用在构建提交存档时创建的DSYM文件重新进行符号化。如果此DSYM位于Spotlight搜索路径中,则可以在“管理器”或“设备”窗口(将崩溃拖动到设备上)或命令行上重新进行符号化。

Stack Overflow上讨论了here命令行重新符号化。