32

The new Xcode 7 "Crashes" tab in the organizer shows a handful of crashes from the AppStore for my app. According to the documentation, there should be a stack trace. However, none of the 6 crashes have symbolicated stack traces: enter image description here

I've tried clicking "Open in Project" but it's just as useless: enter image description here

Of course, I included the dsym and debug info when I submitted to the store. I still have the submission build in my organizer, so the dsyms are still present on my machine. How can I get a proper stack trace on this?

Cœur
  • 37,241
  • 25
  • 195
  • 267
Zane Claes
  • 14,732
  • 15
  • 74
  • 131
  • 2
    I'm having the same issue. – dmarnel Oct 22 '15 at 23:26
  • I'm having the same issue with two of my projects. Different publishers, one is Swift with bitcode disabled, the other one is pure ObjC. Both are submitted with dSYMs. I'll file a bug – mspasov Jan 21 '16 at 11:30
  • I'm considering the possibility that a common library shared between my two projects could be causing this. Updated Google AdMob and StartApp libraries are the common ingredient. Crashes for older versions for both apps have symbols resolved. – mspasov Jan 21 '16 at 11:57

4 Answers4

21

Not ideal, but if you right-click an .xccrashpoint file, select "Show Package Contents", you can navigate its folder structure to find the actual .crash file which you can extract and then symbolicate through the command line using steps described here:

Run

/Applications/Xcode.app/Contents/SharedFrameworks/DTDeviceKitBase.framework/Versions/A/Resources/symbolicatecrash

Ensure that DEVELOPER_DIR is set:

export DEVELOPER_DIR=/Applications/Xcode.app/Contents/Developer
Community
  • 1
  • 1
esilver
  • 27,713
  • 23
  • 122
  • 168
5

Short Story:

In Xcode 9.0: "The Crashes Organizer symbolicates unsymbolicated logs, if they are selected, using a local .dSYM indexed by Spotlight. (22550064)"

You can check out more on this in Xcode's Documentation.

Long Story:

When Xcode builds an .xcarchive for a machine code app it generates .dSYM files that are being indexed by Spotlight by default. For an app uploaded with bitcode you can use the Archives organizer to download dSYMs where they are being indexed by Spotlight by default.

If you choose not to include symbol information when uploading your app to the App Store, the crash logs downloaded by the Crashes Organizer will be unsymbolicated. If you have the appropriate .dSYM files that were generated for the app version that crashed, Xcode will automatically symbolicate the crash when you click on the crash to view it. This functionality exists in Xcode 9.0+. You may manually invoke a re-symbolication by right-clicking on the log detail view and clicking "symbolicate".

  • 1
    This is the right answer for Xcode 9, unless OP's main purpose is perform symbolication from command line, etc. It's also possible to symbolicate crash reports received directly just using Xcode: https://developer.apple.com/library/content/technotes/tn2151/_index.html#//apple_ref/doc/uid/DTS40008184-CH1-SYMBOLICATEWITHXCODE Only sad thing here is: the UI is too unintuitive… – ppm Dec 15 '17 at 11:02
  • "Symbolicate" is grayed out – Hogdotmac Jan 25 '18 at 11:28
  • i am not able to trace any crash log in xcode crash organizer ,accoding to apple documentation i have also logged with the agent creds but i am unable to trace i have only .dSYM file how to proceed – Shakti Oct 01 '18 at 14:01
  • Perfect! This explains my issue and downloading and unzipping the .dSYM files to whatever location to allow spotlight to index fixed the issue. I use two different computers for development and sometimes I build on one or the other so this makes total sense! Such bad implementation by Apple. – Jona Feb 25 '19 at 15:23
  • Ah yeah, except this is wrong. We upload our dSYM files, I even have it locally as well, but it doesn't symbolicate. Clearly Apple Bug #1230981023. –  Dec 03 '21 at 08:02
1

I'm doing this for the first time in Xcode 10. Right clicking on my crash log and selecting Symbolicate was having no effect. I selected the build in the Archives section of the Organizer window and clicked the "Download Debug Symbols" button in the right-side pane. This didn't seem to do anything, but when I went back to Crashes and told Xcode to symbolicate the same crash again, this time it worked.

janineanne
  • 585
  • 7
  • 17
  • I had to restart XCode 11 before symbolicate started to work. Otherwise the above worked for me. – JonLord Feb 08 '20 at 13:21
0

You need to have the app's dsyms local. If this was a build uploaded from say, a build box, you won't have them. Head to App Store Connect, click the Activity tab, find your relevant build, and tap into it. The version details screen includes a link to download the dSYMs - do so, and expand the .zip file they download as.

Now back to your crashes in Xcode - they will symbolicate successfully.

Sanity tip: ensure your local source is at the same commit as the crashing release. Otherwise, if the source file has changed since the release, Xcode can dump you on the incorrect line. e.g. line 127 of your source has now moved to line 129 since you added two lines recently... and the crashes view has no idea about those changes. It'll show you line 127 crashing where the crashing code is actually on line 129.

Graham Perks
  • 23,007
  • 8
  • 61
  • 83