How to symbolicate crash log Xcode?
Ok I realised that you can do this:
Xcode > Window > Devices, select a connected iPhone/iPad/etc top left.
- View Device Logs
- All Logs
You probably have a lot of logs there, and to make it easier to find your imported log later, you could just go ahead and delete all logs at this point... unless they mean money to you. Or unless you know the exact point of time the crash happened - it should be written in the file anyway... I'm lazy so I just delete all old logs (this actually took a while).
- Just drag and drop your file into that list. It worked for me.
How to symbolicate crash log with Xcode 8?
Try using these steps:
1) create a new folder ,lets say "Universe" , to hold the stuff.
2) use the Go to Folder utility from Finder . Use the path /Applications/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/Resources/
Find "symbolicatecrash" file and you can manually copy and paste this file to your Universe folder
3) Place your crash and Archive of your app in your folder ( Archive will hold all the dysm files. Alternatively you can place all your dYsm files )
4) CD to your "Universe" folder directory . Now run this command
5)run the symbolicate command on your crash
./symbolicatecrash myCrash.crash > SymbolicatedM.crash
Voila!! you have your symbolicated crash log.
PS : The added advantage of this is that the above setup is a one time setup and is reusable .All that is required is just replace your crash file and dysm file , then just repeat step 5 each time you want a new crash symbolicated. Bye bye complicated commands!
Symbolicate crashlog of locally built iOS App
Open Project Settings. Go to your Target and set the Debug Information Format to DWARF with dSYM File for Debug. Do the same for the Project
Symbolicate crash log - Xcode 8 / macOS app
Finally, I found how to symbolicate my crashlog for macOS app!
I've followed the instruction in the gist below and obtained human-readable lines.
How to symbolize OSX crash logs -gist
Thus, briefly speaking, for instance for this line:
0 com.MY_DOMAIN.MY_APP 0x000000010febce85 0x10fdc1000 + 1031813
run the following line in Terminal:
atos -o MY_APP.app/Contents/MacOS/MY_APP -arch x86_64 -l 0x10fdc1000 0x000000010febce85
then you'll get the readable line:
Document.init() -> Document (in MY_APP) (DefaultKey.swift:85)
Can't symbolicate crash logs
The good news that it is crashing in your code, not in Operating Systems or Library code, so you have a good chance to debug it. Your code that is crashing is running off a timer. Sometimes these bugs are seen because in testing, you are just testing the app. But in the real world, those timers fire when you are not expecting them.
For example, someone ran your app, then put it into the background when using another app, or for example they received a phone call whilst using the app. If you attach the full contents of the
.crash file, it will give more information on the cause of the crash.
Another thing you can do is place asserts into your code, such as in your timer callback functions for each object you are relying on being non-null.
You may find that your app is trying to draw onto the screen but is in the background. This is a common reason for a crash seen in the field for games that use timers. That may sound like a generalisation but it is a suggestion to try and make you think differently about the real world environment your customers face which can the reason for the failure.
Why aren't the crashlogs from Testflight symbolicating in Xcode?
Apparently this is a bug that started happening when Apple started accepting bitcode. Not all of the dSYMs are downloaded when you click on 'Download dSYMs…' in the Xcode organizer. Here's how I fixed it:
- Manually downloaded the dSYMs from the build page in iTunes Connect
- Right-clicked on the crash log in Xcode and opened it in Finder
- The xcrashpoint file you'll find is an archive, so right-click and show package contents
- Drill down to your .crash file(s)
- Copy the .crash file(s) to a different directory, for instance the desktop
- Copy the dSYMs folder you downloaded to the same directory
- Open Terminal, cd to the folder
- In terminal, set the developer dir path:
- Then symbolicate the files with (replace your paths and filenames here):
/Applications/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/Resources/symbolicatecrash name_of_crashfile.crash name_of_downloaded_dSYMs_dir/ > output.log
And voila! You have your symbolicated crash log.