Unable to calculate the hash .. \ app \ build \ intermediates \ classes-proguard \ ....">

Error: execution completed for the task ": app: packageRelease".> Unable to calculate the hash .. \ app \ build \ intermediates \ classes-proguard \ .. \ release \ classes.jar

The following error message appears when I include Proguard from the gradle file and create the release build file.

An exception occurred while processing the java.io.IOException task: proguard.ParseException: Waiting for the type and name instead of " " before '(' on line 169 of the file 'S: \ workstation \ Projects .. \ application \ assembly \ intermediate \ ProGuard rules. . \ issue \ aapt_rules.txt 'in com.android.build.gradle.tasks.AndroidProGuardTask $ 1.run (AndroidProGuardTask.java:117) in com.android.builder.tasks.Job.runTask (Job.java:48) at com.android.build.gradle.tasks.SimpleWorkQueue $ EmptyThreadContext.runTask (SimpleWorkQueue.java:41) at com.android.builder.tasks.WorkQueue.run (WorkQueue.java:227) in java.lang.Thread.run ( Thread.java:745) Error: proguard.ParseException: Waiting for type and name instead of " " before '(' on line 169 of file 'S: \ workstation \ Projects .. \ application \ assembly \ intermediate \ ProGuard rules .. \ release \ a apt_rules.txt 'in proguard.ConfigurationParser.parseMemberSpecificationArguments (ConfigurationParser.java:908) in proguard.ConfigurationParser.parseClassSpecificationArguments (ConfigurationParser.java:748) in proguard.ConfigurationParserparerparerparerparerparerparerparerparerparerparerparerparerparerparcerparcerparcerpearmspearparcerpearmspearparcerpearmservice ConfigurationParser.java:165) in proguard.gradle.ProGuardTask.getConfiguration (ProGuardTask.java:1142) in proguard.gradle.ProGuardTask.proguard (ProGuardTask.java:1074) in com.android.build.gradle.tasks.AndroidProuardardinarddo (AndroidProGuardTask.java:139) in com.android.build.gradle.tasks.AndroidProGuardTask $ 1.run (AndroidProGuardTask.java:115) ... 4 more Error: execution completed for task ': app: packageProRelease'. > It is not possible to calculate the hash S: \ workspace \ Projects \ application \ assemblies \\ intermediate classes-ProGuard \ Pro \ release \ classes.jar

I use the following code codes:

  • AndroidScanLib.jar
  • apache-mime4j-core-0.7.jar
  • HttpClient-4.1.2.jar
  • httpmime-4.2.3.jar
  • libGoogleAnalyticsServices.jar
  • MobileImagingEngine.jar
  • MobileImagingEngine_Doc.jar
  • SmartScan.jar
  • sqlcipher.jar
+6
source share
2 answers

A strange workaround: disable minifyEnabled (minifyEnabled false), generate a signed APK and then turn it on again (minifyEnabled true) and generate a signed APK again. Hope this works.

+6
source

In my case, I used the custom library that I created, and I set minifyEnabled true, and in the dependent module, I again made the same minifyEnabled true. leaving this in only one place, my problem has been resolved. The same could be the case with libraries other than your own!

+2
source

All Articles