简体   繁体   English

应用程序崩溃但没有TestFlight崩溃报告

[英]App Crashes But No TestFlight Crash Report

I have one user (with an iPhone 5) reporting that my app crashes on launch about 15 seconds after the screen goes black (the splash screen is black). 我有一个用户(带有iPhone 5)报告我的应用程序在屏幕变黑(闪屏为黑色)后大约15秒内在启动时崩溃。 The user downloaded a TestFlight build where I included checkpoints in the App delegate, but I don't get evidence that those checkpoints are crossed, and I never get a crash report. 用户下载了TestFlight构建,其中我在App委托中包含了检查点,但是我没有得到证据证明这些检查点已经过了,我从未收到过崩溃报告。

I changed the entry point on the storyboard to a blank view controller, and now I can see that the checkpoints are being crossed. 我将故事板上的入口点更改为空白视图控制器,现在我可以看到检查点正在交叉。 It's occurred to me that Watchdog is suspending the app due to storyboard resources taking too long to load, but all the images are built in real-time as needed, with the exception of four tiny tab-bar icons. 我发现Watchdog暂停了应用程序,因为故事板资源需要很长时间才能加载,但所有图像都是根据需要实时构建的,除了四个小的标签栏图标。 There are several audio files but they are loaded on demand. 有几个音频文件,但它们是按需加载的。 I can't think of any other resources that could be causing a delay. 我想不出任何可能造成延误的其他资源。 No one else has reported this problem, and I'm stumped. 没有人报告过这个问题,我很难过。

Any insight appreciated, especially as to why I'm not seeing a crash report or checkpoints from TestFlight. 有任何见解,特别是我没有看到来自TestFlight的崩溃报告或检查点的原因。

Your assumption is correct, the watchdog killed the app. 你的假设是正确的,看门狗杀死了应用程序。 This is because the app doesn't start up properly and either the main thread is blocked or no user interaction is possible since no UI is loaded. 这是因为应用程序无法正常启动,主线程被阻止或无法进行用户交互,因为没有加载UI。

As I understand your description, you are creating the resources while loading? 据我了解您的描述,您在加载时创建资源? And probably doing this on the main thread? 并且可能在主线程上执行此操作? You should try to offload resource hungry code into a background thread instead of doing this on the main thread where older/slower devices could take much longer than expected. 您应该尝试将资源饥饿的代码卸载到后台线程中,而不是在主线程上执行此操作,其中较旧/较慢的设备可能需要比预期更长的时间。 The UI should always be responsive, the main thread should never ever to tasks that could get anywhere close to one second of processing. UI应始终具有响应性,主线程永远不应该处理任何可能接近一秒处理的任务。

Another reason could be that the link between the storyboard and the view controller is broken and it actually never loads on that device type. 另一个原因可能是故事板和视图控制器之间的链接被破坏,实际上它从未在该设备类型上加载。

But without more details it is impossible to say what exactly is going on. 但如果没有更多细节,就不可能说明到底发生了什么。

In general: If the app is killed by the iOS system, eg by the watchdog due to startup time exceeding or due to allocating too much memory, then only iOS can generate a crash report. 一般情况下:如果应用程序被iOS系统杀死,例如由于启动时间超过或由于分配过多内存而被监视程序杀死,那么只有iOS可以生成崩溃报告。

The problem is that the app gets killed and in that case the process is killed. 问题是应用程序被杀死,在这种情况下,进程被终止。 And that cannot be detected by any code running inside that process. 并且在该进程内运行的任何代码都无法检测到这一点。 And since crash reports on iOS, other than the iOS system based crash reporter, do run inside the same app process that is being killed, they cannot report or write any crash report. 而且,由于iOS上的崩溃报告(除了基于iOS系统的崩溃记者)在同一个被杀死的应用程序进程内运行,因此无法报告或编写任何崩溃报告。

The following page gives some more details on this: http://support.hockeyapp.net/kb/how-tos-faq/which-types-of-crashes-can-be-collected-on-ios-and-os-x (Though with context to PLCrashReporter, which is not used by Testflight. But the general statements are identical) 以下页面提供了更多详细信息: http//support.hockeyapp.net/kb/how-tos-faq/which-types-of-crashes-can-be-collected-on-ios-and-os- x (虽然有PLCrashReporter的上下文,Testflight没有使用它。但是一般语句是相同的)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM