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

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

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

现在该做什么?

我试着引用:

symbolicatecrash crashreport.crash myApp.app.dSYM

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

我做错什么了吗?


当前回答

我不得不对symbolicatecrash脚本进行大量的修改,以使其正常运行。

据我所知,symbolicatcrash现在要求.app和.dsym在同一个目录下。它将使用.dsym来定位.app,但不会使用dsym来查找符号。

在尝试这些补丁之前,你应该复制你的符号化崩溃,这将使它看起来在dsym:

getSymbolPathFor_dsymUuid函数的第212行左右

212     my @executablePath = grep { -e && ! -d } glob("$dsymdir" . "/Contents/Resources/DWARF/" . $executable);

matchesUUID函数的第265行左右

265             return 1;

其他回答

这是另一个问题,我有符号化崩溃-它不会与应用程序有空间在他们的捆绑(即。“测试App.app”)。注意,我不认为你在提交时可以在他们的名字中有空格,所以你应该删除这些,但如果你已经有需要分析的崩溃,就像这样修补符号崩溃(4.3 GM):

240c240
<         my $cmd = "mdfind \"kMDItemContentType == com.apple.application-bundle && kMDItemFSName == $exec_name.app\"";
---
>         my $cmd = "mdfind \"kMDItemContentType == com.apple.application-bundle && kMDItemFSName == '$exec_name.app'\"";
251c251
<             my $cmd = "find \"$archive_path/Products\" -name $exec_name.app";
---
>             my $cmd = "find \"$archive_path/Products\" -name \"$exec_name.app\"";

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

先决条件

创建一个文件夹,放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的一部分)构建那个版本的应用程序,这是最好的工作方式

我喜欢使用Textwrangler来精确定位原始应用程序上传二进制拒绝中的错误。(崩溃数据将在你的itunesConnect账户中找到。)使用上面萨钦的方法,我复制了原文。崩溃到TextWrangler,然后复制符号崩溃文件,我已经创建到另一个TextWrangler文件。比较这两个文件可以发现不同之处。符号崩溃文件将有差异,指出文件和行数的问题。