Crashlytics 不显示崩溃 [英] Crashlytics does not show crashes

查看:16
本文介绍了Crashlytics 不显示崩溃的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚使用

AppDelegate:

Fabric.sharedSDK().debug = trueFabric.with([Crashlytics.self])

为了模拟我使用的崩溃

Crashlytics.sharedInstance().crash()

var ggg: Int!打印(ggg)

Crashlitics 收集有关会话的一些信息.例如它更新捆绑版本信息:

所以与 Crashlitics 的联系是有效的.但是崩溃信息为空:

我正在使用 XCode 8 和 iOS 9/10.我做错了什么?

我已经在没有 XCode 调试器连接的模拟器和设备上对其进行了测试(即从 sumulator/device 屏幕启动)

在崩溃发生 7-8 小时后,我终于收到了一些 Crashlytics 报告.我早就预料到了,因为根据

如果是,则执行以下步骤

  1. 右键单击您的存档 -> 在 Finder 中显示 -> 右键单击​​文件并单击显示包内容
  2. 右键单击dSYM文件->显示包内容->内容->资源-> DWARF(在终端中打开)
  3. 运行命令 dwarfdump --uuid "你在 dwarf 文件夹中看到的文件名"

这将显示所有关联的 UUID,如果任何列出的 UUID 与缺少 dSYM id 中提到的匹配,则只需压缩 dSYM 文件夹并将其上传到 crashlytics Missing dSYM 段.

这一步很重要,因为有时我们从管理器中提取的 dSYM 文件不包含正确的 UUID.在上传错误的之后,我们等待它的更新.因此,最好确保您上传的是正确的 dSYM 文件.

除上述内容外,Build Settings 中的 Bitcode 属性和 Debug Information Format 也会影响崩溃报告.

I have just installed Crashlitycs using this official instruction.

I have set Debug Information Format is "DWARF with dSYM File" for both Debug and Release and disabled Bitcode (some people wrote that it could help):

AppDelegate:

Fabric.sharedSDK().debug = true
Fabric.with([Crashlytics.self])

To simulate a crash I use

Crashlytics.sharedInstance().crash()

and

var ggg: Int!
print(ggg)

Crashlitics collects some information about sessions. For example it updates bundle versions info:

So connection with Crashlitics works. However crash information is empty:

I am using XCode 8 and iOS 9/10. What I am doing wrong?

EDIT:

I have tested it on simulator and device without XCode debugger connection (i.e. launching from sumulator/device screen)

Finally I have received some Crashlytics reports after 7-8 hours after crashes. I expected them earlier because according to documentation:

Within a few minutes, you should see the crash appear on your Fabric Dashboard.

However I did not receive all crashes I was waiting for. During my experiments I have tried different ways to initialise Crashlytics:

Fabric.with([Crashlytics.self])
and
Fabric.with([Crashlytics.self()])

Could it be the reason? I have also found the similar unanswered question.

解决方案

Checked the following terms,

  1. Make sure Crashlytics SDK line is after all other 3rd-party SDK lines. (it needs to be last one called in your appDidFinishLaunching method.)

  2. Force a crash and then relaunch the app. Xcode must be disconnected to stop it from intercepting the crash report. To disconnect Xcode, follow the instructions here.

  3. If you're using [Crashlytics sharedInstance] crash]; to test crashing, make sure it's not in the appDidFinishLaunching method.

These are already mentioned in support section, Here is additional ones -

  1. Check in organization -> Your App -> Missing dSYM, Is it showing any missing dSYM file

if yes, Then do the following step

  1. Right Click on your archive -> Show in Finder -> Right click on file and click on Show package contents
  2. Right click on dSYM file - > Show package contents -> Contents -> Resources -> DWARF (Open in terminal)
  3. Run command dwarfdump --uuid "file name you saw there in dwarf folder"

This will show all the associated UUID, And if any listed UUID matched with the one mentioned in missing dSYM id then just compress the dSYM folder and upload it on crashlytics Missing dSYM segment.

This step is important cause sometimes the dSYM file we extract from organizer doesn't contain correct UUID. And after uploading the wrong one we wait for its updations. So it's better to make sure you are uploading the right dSYM file.

Other than aforementioned things, Bitcode property and Debug Information Format in Build Settings also affect the crash reporting.

这篇关于Crashlytics 不显示崩溃的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆