我想尝试和象征我的iPhone应用程序的崩溃报告。

我从iTunes Connect上找到了崩溃报告。我有提交给App Store的应用程序二进制文件,我有作为构建的一部分生成的dSYM文件。

我将所有这些文件放在一个目录中,该目录以spotlight为索引。

现在该做什么?

我试着引用:

symbolicatecrash crashreport.crash myApp.app.dSYM

它只输出与崩溃报告开始时相同的文本,没有符号。

我做错什么了吗?


当前回答

我更喜欢一个脚本,将象征我的所有崩溃日志。

先决条件

创建一个文件夹,放4样东西:

symbolicatecrash perl script - there are many SO answers that tells it's location The archive of the build that match the crashes (from Xcode Organizer. simple as Show in Finder and copy) [I don't sure this is necessery] All the xccrashpoint packages - (from Xcode Organizer. Show in Finder, you may copy all the packages in the directory, or the single xccrashpoint you would like to symbolicate) Add that short script to the directory: #!/bin/sh echo "cleaning old crashes from directory" rm -P *.crash rm -P *.xccrashpoint rm -r allCrashes echo "removed!" echo "" echo "--- START ---" echo "" mkdir allCrashes mkdir symboledCrashes find `ls -d *.xccrashpoint` -name "*.crash" -print -exec cp {} allCrashes/ \; cd allCrashes for crash in *.crash; do ../symbolicatecrash $crash > ../symboledCrashes/V$crash done cd .. echo "" echo "--- DONE ---" echo ""

这个脚本

运行脚本时,将得到两个目录。

allCrashes -所有来自所有xccrashpoint的所有崩溃都会在那里。 symboledCrashes -相同的崩溃,但现在有了所有的符号。 你不需要在运行脚本之前从旧的崩溃中清理目录。它会自动清洗。好运!

其他回答

我在我的应用程序中使用Airbrake,它在远程错误记录方面做得相当不错。

下面是我如何用atos来表示它们,如果回溯需要的话:

In Xcode (4.2) go to the organizer, right click on the archive from which the .ipa file was generated. In Terminal, cd into the xcarchive for instance MyCoolApp 10-27-11 1.30 PM.xcarchive Enter the following atos -arch armv7 -o 'MyCoolApp.app'/'MyCoolApp' (don't forget the single quotes) I don't include my symbol in that call. What you get is a block cursor on an empty line. Then I copy/paste my symbol code at that block cursor and press enter. You'll see something like: -[MyCoolVC dealloc] (in MyCoolApp) (MyCoolVC.m:34) You're back to a block cursor and you can paste in other symbols.

能够在不重新进入第一个位的情况下回溯一个项目是一个很好的节省时间的方法。

享受吧!

在最新版本的Xcode(3.2.2)中,你可以拖拽任何崩溃报告到Xcode管理器的设备日志部分,它们会自动为你标记。我认为如果你使用Build & Archive(也是Xcode 3.2.2的一部分)构建那个版本的应用程序,这是最好的工作方式

我更喜欢一个脚本,将象征我的所有崩溃日志。

先决条件

创建一个文件夹,放4样东西:

symbolicatecrash perl script - there are many SO answers that tells it's location The archive of the build that match the crashes (from Xcode Organizer. simple as Show in Finder and copy) [I don't sure this is necessery] All the xccrashpoint packages - (from Xcode Organizer. Show in Finder, you may copy all the packages in the directory, or the single xccrashpoint you would like to symbolicate) Add that short script to the directory: #!/bin/sh echo "cleaning old crashes from directory" rm -P *.crash rm -P *.xccrashpoint rm -r allCrashes echo "removed!" echo "" echo "--- START ---" echo "" mkdir allCrashes mkdir symboledCrashes find `ls -d *.xccrashpoint` -name "*.crash" -print -exec cp {} allCrashes/ \; cd allCrashes for crash in *.crash; do ../symbolicatecrash $crash > ../symboledCrashes/V$crash done cd .. echo "" echo "--- DONE ---" echo ""

这个脚本

运行脚本时,将得到两个目录。

allCrashes -所有来自所有xccrashpoint的所有崩溃都会在那里。 symboledCrashes -相同的崩溃,但现在有了所有的符号。 你不需要在运行脚本之前从旧的崩溃中清理目录。它会自动清洗。好运!

在我的例子中,我直接将崩溃报告从Mail拖到Organizer。出于某种原因,这阻止了坠机报告被符号化(我很想知道为什么)。

首先将崩溃报告复制到桌面,然后将它们从桌面拖动到管理器,这样它们就被正确地符号化了。

我知道,这是非常具体的案例。但以防万一,还是分享一下吧。

为了表示崩溃,Spotlight必须能够找到与您提交给Apple的二进制文件同时生成的. dsym文件。由于它包含符号信息,如果它不可用,那么您就不走运了。