Symbolicate crash file with dSYM and .ipa file - xcode

Is there any concreate way to symbolicate crash logs from my app, i have following things
dSYM file
.ipa Application file
myapp.crash
-
I have tried symbolicatecrash script but it does not work somehow
Xcode does not work also i have Xcode 4.3
I even tried system 'atos' command but it gives me some c or c++ file
I dont have build file in my archive is it because of that, because app was build in different machine ?

This may be too late.. but i saw the method in another link that i am now trying to find :P
Rename your .ipa file to .zip
Open the zip file to extract the app
now run symbolicatecrash script or delete the .symbolicated folder
and restart xcode
if not helpful to you, hope this helps others.
Edit: found the place Symbolicating iPhone App Crash Reports

Aside from xcode's tools, you can use atos: https://stackoverflow.com/a/4954949/312725
Be sure to take slide into account as well: https://stackoverflow.com/a/13576028/312725

Related

How to symbolicate for Xamarin.iOS on Windows

I submitted an iOS app which failed review due to a crash. I was given the crash report which unfortunately for me, was useless because I didn't keep the dSYM files and .app file that I apparently needed to decipher the crash report.
First question -
I've built a new release and I've stored the dSYMs folder away for safe keeping, but I can't find the .app file that I apparently need. this link here suggested that I could change the .ipa file to a zip and then get the .app from unzipping it but there was nothing in the zipped folder once I changed its extension to .zip How to symbolicate crash/error logs from a Xamarin Forms iOS project?
Second question - How do I symbolicate on windows? I've seen guides like this one, but it only shows you how to do it on a MAC. The problem I have is that the project is entirely built on my windows machine which is networked to a MAC. https://jmillerdev.com/symbolicating-ios-crash-files-xamarin-ios/
I was able to symbolicate the crash reports given by apple from the review by using this guide:
https://jmillerdev.com/symbolicating-ios-crash-files-xamarin-ios/
or
How to symbolicate crash/error logs from a Xamarin Forms iOS project?
Basically what you need to do:
Get the .dSYM and .app file from the archived release folder and put it on your MAC in a folder some where. Additionally, put the crash report in the same folder. (The crash report on App Store Connect will be a .txt file. Change it to .crash) Open up the terminal and change the current working directory to that folder I just mentioned. e.g. cd /Applications/crashFolder
Run the following terminal commands
alias symbolicate="/Applications/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/Resources/symbolicatecrash -v"
export DEVELOPER_DIR="/Applications/Xcode.app/Contents/Developer"
Symbolicate your .crash file with this terminal command:
symbolicate -o "symbolicatedCrash1.txt" "crash1.crash" "MyApp.app"

Programmatic Symbolication of Crash Logs

I am attempting to symbolicate crash logs that I have automatically sent to a server. My app's crash logs and dSYM files are sent to the server upon my app crashing. The issue I am having is symbolicating them. I would like to do this programmatically so that the process can be automated. Thus I am trying to use the symbolicatecrash terminal command as a subprocess in a python script. But before I even try to implement that, I need to get symbolicatecrash working properly. entering the following command is unsuccessful;
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/PrivateFrameworks/DTDeviceKitBase.framework/Versions/A/Resources/symbolicatecrash -o /Users/aj/Documents/symbolicatedcrash.crash com.COMPANYNAME.TEST_APP.crash TEST_APP.app.dSYM
I use the -o option to write the output to a file. Entering this code does not return an error. The output file is created, the crash log is just not symbolicated.
From researching peoples' similar questions, I've found that downloading the .ipa file and unzipping it can help. I have done so and found that the symbolicatecrash command does indeed symbolicate if the .app file is on the server.
My issue is that I do not want to download the .ipa file. Downloading it every time there is a new crash (or at least a new build) would be inefficient for the server. I would just like to download the dSYM and crash file itself upon each app crash.
My question is ultimately then: Can I symbolicate a crash log by using just the dSYM file? If so, can it be done with the symbolicatecrash terminal command?
Thanks
after further experimentation, I found that you indeed need the .ipa file or the archived app binaries to fully symbolicate the crash log.
you do not need to include those files in the terminal command though; The example I gave in the question works if you have the app binaries anywhere on your computer. The command will use spotlight to find the app binaries, and then return a fully symbolicated crash log.
note: it important that your binaries/crash log/dSYM files all come from the same build to have a fully symbolicated log.

Can you create Mac .app distribution from the command-line instead of from within Xcode?

Is it possible to go from an .xcarchive bundle to an .app bundle without using the Xcode Organizer? I'd like to create an automated build and get the final .app file that I can distribute. Using xcodebuild with the archive target works great for getting the .xcarchive file, but not for the final app.
With the iOS SDK, there's a PackageApplication tool you can use with xcrun, but this doesn't appear to exist with the OS X SDK.
I'd also like to do this so I can hopefully get more diagnostics from the Distribution process, which is failing for me right now with the infamous 100021 OS error code.
Have you looked inside the .xcarchive bundle? It's just a folder. Your .app targets should be inside, in a Products subfolder.
In Finder, right-click the archive and click Show Package Contents. in Terminal, use cd.
Try the -exportArchive flag in the xcodebuild command:
xcodebuild -exportArchive -exportFormat app -archivePath <path to .xcarchive> -exportPath "My App.app" -exportSigningIdentity "Developer ID Application: My Software Company"
This command is present in Xcode 5.0.1. See the man page for more details on the optional arguments. This example exports a Developer ID signed application.
Here is what I have discovered about this issue:
As previously suggested, the xcodebuild's archive buildaction is good for getting the .xcarchive, but there does not appear to be an actual way to perform the validate or distribution commands from the command-line. I hope this eventually turns out to be false.
I was able to trick the validation tool by removing the embedded symbolic links in the embedded framework directories. This works, but after discussing with Apple support it turns out this is tricking the tool and not actually producing a valid result.
Apple support says they see this error code if one of the .plist files in an embedded framework is invalid. It turns out, in my example, I had 3 embedded frameworks and 1 of them had an empty .plist file, likely from me hand-building the project. After fixing that, the build would continue happily.

App name does not exist in Instruments dSYM Locations

I'm trying to re-symbolize my project in instruments since it's not showing functions name under TimeProfiler. But I'm not able to find my App under the dSYM Locations.
I don't know why, but for some reason the profiling schema under xcode had 'release' config instead of 'debug'!! changing that back to debug solved the problem.
This is a bug with spotlight and Lion.
Unfortunately "mdimport ." command does not work in all situations ( this command should tell where to look for the dsym files, if you were in the dsym folder it must work)
So i end up locating manually in instruments the files under: /Users/YOUR_USER_HERE/Library/Developer/Xcode/DerivedData/YOUR_APP_HERE/Build/Products and then select the appropriate folder and DSym files.
To be able to select Library folder you need to write this command: chflags nohidden ~/Library/

OSX Package not running executable

I am new to development on OSX and am having an issue that is confusing me.
I am using xcode for work and I everything works when I debug from xcodes debugger.
However, when I am running the package manually, it doesn't seem to run the executable in the packages MacOS.
Basically, in xcode, is there something I need to set so that it knows where and how to run the executable in the MacOS directory?
I already changed the plist to have the executable set to the correct name. I am stuck as to even where to start looking for the issue.
Thanks in advance for any help you can give, developing for the mac has been a crash course for me :P
-Bear
Archive the project (Product->Archive) and then open the Organizer (Window->Organizer), select the archived version and click on "Distribute" and select "Export as Application".

Resources