Moving to build tools 1.3.0 found a new build with proguard enabled

Our background is that we turned off obfuscation [-dontobfuscate] in proguard. And in our build.gradle file we minifyEnabled are true. Everything worked fine until we switched to build tools 1.3.0.

classpath 'com.android.tools.build: gradle: 1.0.0'

Now the assembly breaks because it cannot find the map.txt file, which should only be generated when obfuscation is enabled. Here is the exception I get

Execution failed for task ':app_name:uploadArchives'.
    10:49:57.642 [ERROR] [org.gradle.BuildExceptionReporter] > Could not publish configuration 'archives'
    10:49:57.642 [ERROR] [org.gradle.BuildExceptionReporter]    > Cannot publish artifact 'app.map (app_name:1.2.3)’ (/Users/build_area/build/outputs/mapping/release/mapping.txt) as it does not exist.

So for some reason, uploadArchives thinks obfuscation is on. Also, to indicate if I turn on obfuscation, everything works fine, and the build works great.

Is something broken or am I doing it wrong?

+4
source share

Source: https://habr.com/ru/post/1610477/


All Articles