No items found.
January 16, 2015

Retrace stacktraces in Android with ProGuard support

Bugsnag has long-supported symbolicating iOS stacktraces, and now we can also retrace Android stacktraces with ProGuard.

ProGuard has become an important part of developing an Android app. It reduces the sizeof your code, and makes it harder for people to reverse engineer it. The only difficulty is that it can make it harder to debug problems in your code.

To fix this you can upload your ProGuard mapping file to Bugsnag, and we’ll undo the obfuscation to retrace your stacktraces. You’ll see a complete stacktrace with file names and line numbers, giving you better context on errors happening in your Android apps.

It’s easy to set up:

1. Make sure you’re keeping line numbers

Bugsnag uses line numbers to de-duplicate crashes, so you need to configure ProGuard to keep line numbers and source files. You can do this by adding the following line to your [CODE]proguard.prg[/CODE]:

-- CODE language-groovy --
-keepattributes LineNumberTable,SourceFile

2. Upload using Gradle

Bugsnag integrates with the Android Gradle build system to automatically upload ProGuardfiles when you rebuild your app. To do this, add the following to your [CODE]build.gradle[/CODE]

-- CODE language-groovy --
buildscript {
   repositories {
   dependencies {
       classpath 'com.bugsnag:bugsnag-android-gradle-plugin:+'

apply plugin: 'bugsnag'

3. Upload using the API

If you’re not using the gradle plugin, or you need a more custom process, you can upload a ProGuard file using our API.


Any questions for us? Reach us on Twitter! For more details, read about Bugsnag’s Android Crash Reporting.

BugSnag helps you prioritize and fix software bugs while improving your application stability
Request a demo