How to get proguard errors at android studio

1.9k views Asked by At

I enable proguard for release and got the following error:

Execution failed for task ':app:transformClassesAndResourcesWithProguardForFlavorQuaRelease'.
    [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] > Job failed, see logs for details
    [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] 
    [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] * Try:
    [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]  Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

How can i see the errors?

1

There are 1 answers

0
MiguelSlv On BEST ANSWER

Find no posts at the time that guide someone through first proguard errors. This what i did.

First i enabled the debug on settings:

enter image description here

Then toggle view button at build window: enter image description here

There should be an errors resume near the bottom, looking like this:

Note: there were 1 references to unknown classes.
      You should check your configuration for typos.
      (http://proguard.sourceforge.net/manual/troubleshooting.html#unknownclass)
Note: there were 2 references to unknown class members.
      You should check your configuration for typos.
Note: there were 128 unkept descriptor classes in kept class members.
      You should consider explicitly keeping the mentioned classes
      (using '-keep').
      (http://proguard.sourceforge.net/manual/troubleshooting.html#descriptorclass)
Note: there were 62 unresolved dynamic references to classes or interfaces.
      You should check if you need to specify additional program jars.
      (http://proguard.sourceforge.net/manual/troubleshooting.html#dynamicalclass)
Warning: there were 4 unresolved references to classes or interfaces.
         You may need to add missing library jars or update their versions.
         If your code works fine without the missing classes, you can suppress
         the warnings with '-dontwarn' options.
         (http://proguard.sourceforge.net/manual/troubleshooting.html#unresolvedclass)
Warning: there were 1 unresolved references to program class members.
         Your input classes appear to be inconsistent.
         You may need to recompile the code.
         (http://proguard.sourceforge.net/manual/troubleshooting.html#unresolvedprogramclassmember)

Not all kind of errors need to be fixed in order to compile. Yet, some may cause crash after, so it is advisable to read the Proguard documentation as suggested.