De obfuscation not working with android studio 3.0

Viewed 510

I have my code obfuscated with proguard that runs when a release version is build and during the publish of the APK in the play console, I upload the mapping.txt file in "Vitals" section.

When an exception raises I can read clear code in stacktraces (in crashlytics and in Play console).

With previous version of Android studio (<= 2.3.3) all works regulary, now after the upgrade to Android studio 3.0 the same process will not de obfuscate stacktraces anymore.

I came across the migration of gradle plugin introducing the needed modifies

build.gradle (app):

    flavorDimensions "mode"
        productFlavors {
        full {
        dimension "mode"
        }
    }
    ...
    buildTypes {
    release {
        multiDexEnabled true
        minifyEnabled true
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        signingConfig signingConfigs.config
    }
    debug {
        ext.enableCrashlytics = false
        versionNameSuffix "-DEBUG"
        }
    }

What's wrong in the configuration? The mapping.txt file is correctly uploaded and accepted by Play Console. Any hint?

1 Answers

It's new in android, when you upload the mapping file, it Deobfuscate your code so you can understand the stack trace. This is the documentation link, it says:

If you use ProGuard to optimize and obfuscate your APK files, you can upload a ProGuard mapping file for each version of your app on the Play Console to deobfuscate your crash stack traces and help you better analyze your app's crashes.

Related