Overview of iOS Crash Reporting Tools: Part 1/2

Learn how crash reporting works on iOS, how to automatically get and diagnose crash logs, and which crash reporting tool is best for you. By Cesare Rocchi.

1 (1) · 1 Review

Save for later
Share
You are currently viewing page 3 of 5 of this article. Click here to view the first page.

Crashlytics

Recently bought by Twitter, Crashlytics is pretty famous in the iOS community. It’s used by well-known companies such as Path and Yammer. It is a full-stack service, meaning that the framework provides both client-side and server-side parts. At the moment, Crashlytics supports only iOS, although the website does indicate that Android support is coming soon.

Crashlytics Setup and Dashboard

Once you have logged into the Crashlytics site, you’ll be prompted to download a Mac application. This application will guide you through the process of configuring your iOS application to work with the Crashlytics service. The application works like a wizard. It first asks you to pick an Xcode project on your disk. Next, it will install the Crashlytics framework, and finally, it will add a step to the building phase of your project.

Any crashes captured will appear on the Crashlytics back-end. Just login, select the application you’re interested in, and you’ll see something like this:

The Dashboard on Crashlytics

The data is definitely well-organized. At a glance, you can see the issues reported, number of crashes, and the number of users affected. On the right, a graph shows the distribution of crashes over time. Each crash is classified by application version to avoid any confusion.

Crashlytics Reports

Crashlytics displays the list of crashes at the bottom, already symbolicated, and you can immediately see the line generating the crash. In the example above, you can quickly see that line 343 in SMEngine.m was where the crash occurred.

If you click on a crash entry, further details are displayed, as shown in the screenshot below:

A Log Report on Crashlytics

At the top of the report, there are contextual details about the average environment where the crash occurred, like the free space on the device, which is handy if you are caching data on disk; RAM, which is handy if you are caching data in memory; and whether the device is jailbroken, along with other juicy details.

At the bottom, you’ll see a stack trace with the sequence of calls that occurred right before the app crashed. As noted, it is very likely some of your code is causing the crash, so you should look for the names of your classes and methods. In this example, the crash is in getHourlyForecast, which is called by parseResultForConnection, which in turn is called by connectionDidFinishLoading.

Once you have fixed the bug and deployed the new version of the app, you can mark the issue as closed, using the control shown below:

Close an Issue on Crashlytics

Once an issue is closed, it won’t appear again in the list of crashes that require your attention.

Crashlytics 3rd Party Integration

You can integrate Crashlytics with third party bug trackers and project management tools, including the following:

Simply enter your credentials for the above services, and Crashlytics servers will forward crash log data to the appropriate service. Cool! :]

For those developers who love to craft their own solution, you can even set up a web hook. This is a custom URL where Crashlytics will send you data in JSON format, and you’re then free to manipulate the data as you like.

The logging functions that Crashlytics provides are worth mentioning as well. Once you have configured your project for Crashlytics, you can quickly set up a macro to log events, actions and most importantly, the values of variables, which can be helpful while hunting for the source of a crash.

This is the equivalent of using NSLog statements, except instead of logging to the console, the lines are sent to Crashlytics. How many times have you wished you could see the console output as your customers use your app in the real world? That’s a reality now! :]

You can also set up notifications via email to receive messages about crashes either as they are received, or as a daily email digest.

Crashlytics Usage Tiers

Previously, Crashlytics had two usage tiers: a free tier, as well as a paid enterprise tier. However, the enterprise tier is now free as well. Thanks Twitter!

To go back to the restaurant analogy, Crashlytics is a good restaurant with a proficient kitchen (symbolication). The food is good and the wait staff are attentive (browsability and usability of logs on the server). Unfortunately, there is not much variety in the menu (just iOS). There is also a wait list, much like a very good restaurant, which means you may have to wait to be seated. However the wait time at the moment doesn’t appear to be very long and you are often seated within minutes.

Crittercism

Crittercism is another full-stack tool to keep track of your crash logs. It has been adopted by companies such as Netflix, Eventbrite and Linkedin. It provides support for iOS, as well as Android, HTML5 and Windows 8 (which is in beta at the moment).

Crittercism Setup and Dashboard

Setup is pretty simple. You create an account, create an application on the server, download an SDK, add it to your project, and initialize it. Then you’re ready to rock!

The screenshot below shows the dashboard view of Crittercism, along with a symbolicated crash log:

An example of Crittercism log

With Crittercism, not every detail is available at first glance. For example, to view the application version or contextual data, you have to navigate through the tabbed menu in the middle of the page.

The “breadcrumbs” feature of Crittercism allows you to place log statements throughout your code to get contextual information about what happened before the crash, as shown below:

Log statements on crittercism

Note: Breadcrumbs is a paid enterprise feature of Crittercism, but it’s included in the trial period if you want to get a feel for how it works.

Like other tools, you can mark a crash log as “known” or “solved”. Finally, the SDK includes the possibility to schedule a “Rate My App” popup via the backend, with the ability to customize when the popup appears, as well as the message displayed.

Crittercism Incident Mapping

Another interesting feature of Crittercism is the map that shows you where your logs were recorded, as shown below:

Distribution on log on a map on Crittercism

Personally, I have some concern about this, since the user is never asked for permission to calculate a user’s current position. You can use your own judgment call on this.

You can receive email notifications when a crash log is uploaded to the server, and you can set up alarms to receive SMS or email messages when crash counts pass a given threshold.

Crittercism 3rd Party Integration

As far as third party integration goes, you can hook Crittercism up to HelpShift or Uservoice. Both are customer support help-desk applications.

Crittercism Pricing Tiers

There are different tiers for pricing for Crittercism, based on whether you’re making consumer or enterprise apps. For full details, check out their pricing page.

When you sign up, you are offered a 30-day free trial which includes enterprise level features like breadcrumbs and phone support.

Crittercism is an interesting restaurant. The menu is very rich (offering iOS, Android, HTML5 and Windows 8 in beta) but the wait staff is not really friendly (requiring manual upload of dSYM files, and the usability of the website isn’t the best).