简体   繁体   English

在 IOS 上设置 Firebase Crashlytics

[英]Set up Firebase Crashlytics on IOS

I never setted crashlytics before and when i follow officials instructions https://firebase.google.com/docs/crashlytics/get-started?platform=ios&authuser=0#add-sdk i get stuck in the run script part crashlytics version 4.6.2在我按照官方说明https://firebase.google.com/docs/crashlytics/get-started?platform=ios&authuser=0#add-sdk之前和之后,我从未设置过 crashlytics 我陷入了运行脚本部分 crashlytics 4.6 版。 2 在此处输入图片说明

in the output i get a confirmation that crashlytics is setted but in the dashboard i see nothing在输出中,我确认设置了 crashlytics,但在仪表板中我什么也没看到在此处输入图片说明

To test this you can force a crash..要对此进行测试,您可以强制崩溃..

What you can do is...你能做的是...

  • Add a button on view and implement its touchupInside event.在视图上添加一个按钮并实现其touchupInside事件。
  • in that method just write fatalError()在该方法中只需编写fatalError()
  • Run your app and click on that button.(You app will crash here so it will be close)运行您的应用程序并单击该按钮。(您的应用程序将在此处崩溃,因此它将关闭)
  • Now open app again( Do not run app. Just open it by taping on app icon )现在再次打开应用程序(不要运行应用程序。只需通过点击应用程序图标打开它

So the crash report will be send to firebase and you can see the result on firebase dashboard with in 5 minutes(as per their doc.).因此崩溃报告将发送到 firebase,您可以在 5 分钟内在 firebase 仪表板上看到结果(根据他们的文档)。

Also you need to set this flag in build setting of your project to generate dsym file for debug mode.您还需要在项目的构建设置中设置此标志以生成用于调试模式的 dsym 文件。

在此处输入图片说明

Also this has to be set in build phase这也必须在构建阶段设置

在此处输入图片说明

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

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