在我的保障规则中,我有以下规则:
-verbose
-dontwarn java.lang.ClassValue
-#-ignorewarnings
-dontusemixedcaseclassnames
-dontwarn okio.**
-dontwarn javax.annotation.Nullable
-dontwarn javax.annotation.ParametersAreNonnullByDefault
-dontwarn org.joda.convert.**
-dontwarn org.slf4j.**
-dontwarn org.apache.log4j.**
-dontwarn org.apache.commons.logging.**
-dontwarn org.apache.commons.codec.binary.**
-dontwarn org.xmlpull.v1.**
-dontwarn javax.persistence.**
-dontwarn javax.lang.**
-dontwarn javax.annotation.**
-dontwarn javax.tools.**
-keepattributes *Annotation*
-keepattributes Signature
-keepattributes InnerClass
-keepattributes *DatabaseField*
-keepattributes *DatabaseTable*
-keepattributes *SerializedName*
-libraryjars libs/ormlite-android-4.41.jar
-libraryjars libs/ormlite-core-4.41.jar
-libraryjars libs/ksoap2-android-assembly-3.6.2-jar-with-dependencies.jar
-libraryjars libs/slf4j-android-1.6.1-RC1.jar
-libraryjars <java.home>/lib/rt.jar1
-keep public class com.google.vending.licensing.ILicensingService
-keep public class com.android.vending.licensing.ILicensingService
-keep class my.com.package.activity.ChangerMotDePasse
-keep class my.com.package.activity.SplashScreen{
void requestPermission();
void <init>();
private void showDossiers();
public void handleMessage(android.os.Message);
public void onPermissionGranted();
protected void createDBifNotExitsDB();
}
-keep class my.com.package.activity.QrCodeScanActivity
-keep class my.com.package.activity.StatutDeCompteActivity
-keep class my.com.package.AbstractMyDossierListFragment
-keep class my.com.package.Wizard
-keep class my.com.package.WizardPage1
-keep class my.com.package.WizardPage2
-keep class my.com.package.WizardPage3
-keep class my.com.package.WizardPageMandate
-keep class my.com.package.ComplementPageMandate
-keep class my.com.package.WizardPageMandatePhoto
-keep class my.com.package.ComplementPageMandatePhoto
-keep class my.com.package.PhotoActivity
-keep class my.com.package.ComplementPage1
-keep class my.com.package.ComplementPage2
-keep class my.com.package.ComplementPage3
-keep class my.com.package.DatePickerHelper
-keep class my.com.package.DossierAdapter
-keep class my.com.package.PhotoActivity
-keep class my.com.package.PhotoBaseActivity
-keep class my.com.package.PhotoPreview
-keep class my.com.package.RegisterIMActivity
-keep class my.com.package.authenticator.AuthenticatorActivity{ *; }
-keep class my.com.package.authenticator.AuthenticatorHomeActivity
-keep class my.com.package.authenticator.NetworkUtilities
-keep class my.com.package.authenticator.Authenticator
-keep class my.com.package.DossiersListMain
-keep class my.com.package.authenticator.AuthenticationService
-keep class com.sun.** {*;}
-keep class net.sqlcipher.** { *; }
-keep class net.sqlcipher.database.* { *; }
-keep class com.android.support.**{ *; }
-keepclassmembers class com.android.support.**{ *; }
-keep class javax.xml.**{ *; }
-keep class javax.security.**{ *; }
-keep class java.security.**{ *; }
-keep class java.beans.**{ *; }
-keep class com.android.**{ *; }
-keep class org.xmlpull.** { *; }
-keep class org.apache.httpcomponents.**{ *; }
-keep class net.zetetic.**{ *; }
-keep class com.github.tony19.**{ *; }
-keep class com.github.chrisbanes.photoview.**{ *; }
-keep class com.squareup.retrofit2.**{ *; }
-keep class com.squareup.okhttp3.**{ *; }
-keep class joda-time.**{ *; }
-keep interface joda-time.**{ *; }
-keep class me.dm7.barcodescanner.**{ *; }
-keep class com.google.zxing.**{ *; }
-keep class com.journeyapps.**{ *; }
-keep class javamail.** {*;}
-keep class javax.mail.** {*;}
-keep class javax.activation.** {*;}
-keep class com.sun.mail.dsn.** {*;}
-keep class com.sun.mail.handlers.** {*;}
-keep class com.sun.mail.smtp.** {*;}
-keep class com.sun.mail.util.** {*;}
-keep class mailcap.** {*;}
-keep class mimetypes.** {*;}
-keep class myjava.awt.datatransfer.** {*;}
-keep class org.apache.harmony.awt.** {*;}
-keep class org.apache.harmony.misc.** {*;}
-keep class org.slf4j.LoggerFactory {*;}
-keep class org.slf4j.Logger {*;}
-keep class okio.** {*;}
-keep class android.databinding.** { *; }
-keep class com.j256.ormlite.** { *; }
-keepclassmembers class com.j256.ormlite.** { *; }
-keep enum com.j256.ormlite.** { *; }
-keepclassmembers enum com.j256.ormlite.** { *; }
-keep interface com.j256.ormlite.** { *; }
-keepclassmembers interface com.j256.ormlite.**{ *; }
-keep class my.com.package.util.Utilitaire
-keepclassmembers class my.com.package.util.Utilitaire{
*;
}
-keepclassmembers class my.com.package.bean.** {
@com.j256.ormlite.field.DatabaseField <fields>;
@com.j256.ormlite.field.ForeignCollectionField <fields>;
}
-keep class my.com.package.bean.**{ *; }
-keepclassmembers class my.com.package.bean.** { *; }
-keep public class * extends android.view.View {
public <init>(android.content.Context);
public <init>(android.content.Context, android.util.AttributeSet);
public <init>(android.content.Context, android.util.AttributeSet, int);
public void set*(***);
}
-keepclasseswithmembers class * {
public <init>(android.content.Context, android.util.AttributeSet);
}
-keepclasseswithmembers class * {
public <init>(android.content.Context, android.util.AttributeSet, int);
}
-keepclassmembers class * implements android.os.Parcelable {
static android.os.Parcelable$Creator CREATOR;
}
-keepclassmembers class **.R$* {
public static <fields>;
}
-keep class * extends com.j256.ormlite.android.apptools.OrmLiteSqliteOpenHelper
-keepclassmembers class * extends com.j256.ormlite.android.apptools.OrmLiteSqliteOpenHelper {
public <init>(android.content.Context);
}
-keep @com.j256.ormlite.table.DatabaseTable class * {
@com.j256.ormlite.field.DatabaseField <fields>;
@com.j256.ormlite.field.ForeignCollectionField <fields>;
@com.j256.ormlite.field.DataType <fields>;
}
-keep @com.j256.ormlite.table.DatabaseTable class * {
@com.j256.ormlite.field.DatabaseField <fields>;
@com.j256.ormlite.field.DatabaseType <fields>;
@com.j256.ormlite.field.DataType <fields>;
@com.j256.ormlite.field.ForeignCollectionField <fields>;
<init>();
}
-keep @com.j256.ormlite.dao.Dao class * {
*;
}
-keep @com.j256.ormlite.dao.GenericRawResults class * {
*;
}
-keep @com.j256.ormlite.stmt.PreparedQuery class * {
*;
}
-keep @com.j256.ormlite.stmt.QueryBuilder class * {
*;
}
-keep class my.com.package.mailer.Mailer { *; }
-keep class my.com.package.debug.Debug { *; }
-keep class com.admob.**
-keep class org.xmlpull.v1.**
-keep class javax.security.** { *; }
-keep class javax.xml.** { *; }
-keep class org.apache.** { *; }
-keep class java.beans.** { *; }
-keep class java.security.** { *; }
-keep class java.awt.** { *; }
-keep class okhttp3.** { *; }
-keep class org.codehaus.** { *; }
-keep class org.joda.** { *; }
-keep class javax.annotation.** { *; }
-keep public class * extends android.app.Activity
-keep public class * extends my.com.package.AbstractMyActivity
-keep public class * extends android.app.Application
-keep public class * extends android.app.Service
-keep public class * extends android.content.BroadcastReceiver
-keep public class * extends android.content.ContentProvider
-keep public class * extends android.app.backup.BackupAgent
-keep public class * extends android.preference.Preference
-keep public class * extends android.support.v4.app.Fragment
-keep public class * extends android.support.v4.app.DialogFragment
-keep public class * extends android.app.Fragment
-keep public class com.android.vending.licensing.ILicensingService
-keep class android.support.v4.** { *; }
-keepclassmembers,allowshrinking,allowobfuscation interface * {
@retrofit2.http.* <methods>;
}
当我混淆我的代码时,当我生成签名的APK时,出现以下错误。
Warning: library class com.j256.ormlite.stmt.StatementExecutor$UserObjectRowMapper extends or implements program class com.j256.ormlite.stmt.GenericRowMapper
Warning: library class com.j256.ormlite.stmt.mapped.MappedQueryForId extends or implements program class com.j256.ormlite.stmt.mapped.BaseMappedQuery
Warning: library class com.sun.istack.internal.ByteArrayDataSource extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.bind.v2.runtime.unmarshaller.Base64Data$1 extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.messaging.saaj.packaging.mime.MultipartDataSource extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.messaging.saaj.packaging.mime.internet.MimeBodyPart$1 extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.messaging.saaj.packaging.mime.internet.MimePartDataSource extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.messaging.saaj.soap.AttachmentPartImpl$1 extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.messaging.saaj.soap.FastInfosetDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.messaging.saaj.soap.GifDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.messaging.saaj.soap.ImageDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.messaging.saaj.soap.JpegDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.messaging.saaj.soap.MessageImpl$1 extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.messaging.saaj.soap.MultipartDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.messaging.saaj.soap.SOAPPartImpl$1 extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.messaging.saaj.soap.StringDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.messaging.saaj.soap.XmlDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.org.jvnet.staxex.Base64Data$Base64DataSource extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.org.jvnet.staxex.StreamingDataHandler extends or implements program class javax.activation.DataHandler
Warning: library class com.sun.xml.internal.ws.encoding.DataHandlerDataSource extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.ws.encoding.ImageDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.ws.encoding.MIMEPartStreamingDataHandler$StreamingDataSource extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.ws.encoding.StringDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.ws.encoding.XmlDataContentHandler extends or implements program class javax.activation.DataContentHandler
Warning: library class com.sun.xml.internal.ws.encoding.xml.XMLMessage$XmlDataSource extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.ws.message.JAXBAttachment extends or implements program class javax.activation.DataSource
Warning: library class com.sun.xml.internal.ws.util.ByteArrayDataSource extends or implements program class javax.activation.DataSource
Warning: com.opencsv.ResultSetHelperService: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.ResultSetHelperService: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.ResultSetHelperService: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.ResultSetHelperService: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.ResultSetHelperService: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.ResultSetHelperService: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.bean.AbstractBeanField: can't find referenced class org.apache.commons.beanutils.PropertyUtilsBean
Warning: com.opencsv.bean.AbstractBeanField: can't find referenced class org.apache.commons.beanutils.PropertyUtilsBean
Warning: com.opencsv.bean.AbstractBeanField: can't find referenced class org.apache.commons.beanutils.PropertyUtilsBean
Warning: com.opencsv.bean.AbstractBeanField: can't find referenced class org.apache.commons.beanutils.PropertyUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.locale.LocaleConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.locale.LocaleConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.locale.LocaleConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.locale.LocaleConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConversionException
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.locale.LocaleConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConversionException
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.locale.LocaleConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConversionException
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.locale.LocaleConvertUtilsBean
Warning: com.opencsv.bean.BeanFieldPrimitiveTypes: can't find referenced class org.apache.commons.beanutils.ConversionException
Warning: com.opencsv.bean.HeaderColumnNameMappingStrategy: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.bean.HeaderColumnNameMappingStrategy: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.bean.HeaderColumnNameMappingStrategy: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.bean.HeaderColumnNameMappingStrategy: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.bean.HeaderColumnNameMappingStrategy: can't find referenced method 'java.lang.reflect.Field[] getAllFields(java.lang.Class)' in program class org.apache.commons.lang3.refle
ct.FieldUtils
Warning: com.opencsv.bean.HeaderColumnNameMappingStrategy: can't find referenced class org.apache.commons.text.StrBuilder
Warning: com.opencsv.bean.StatefulBeanToCsv: can't find referenced class org.apache.commons.collections.CollectionUtils
Warning: com.opencsv.bean.StatefulBeanToCsv: can't find referenced class org.apache.commons.collections.CollectionUtils
Warning: com.opencsv.bean.customconverter.ConvertGermanToBoolean: can't find referenced class org.apache.commons.beanutils.converters.BooleanConverter
Warning: com.opencsv.bean.customconverter.ConvertGermanToBoolean: can't find referenced class org.apache.commons.beanutils.converters.BooleanConverter
Warning: com.opencsv.bean.customconverter.ConvertGermanToBoolean: can't find referenced class org.apache.commons.beanutils.Converter
Warning: com.opencsv.bean.customconverter.ConvertGermanToBoolean: can't find referenced class org.apache.commons.beanutils.ConversionException
Warning: com.opencsv.bean.customconverter.ConvertGermanToBoolean: can't find referenced class org.apache.commons.beanutils.Converter
Warning: com.opencsv.bean.customconverter.ConvertGermanToBoolean: can't find referenced class org.apache.commons.beanutils.ConversionException
Warning: com.opencsv.bean.customconverter.ConvertGermanToBoolean: can't find referenced class org.apache.commons.beanutils.Converter
Warning: com.opencsv.bean.customconverter.ConvertGermanToBoolean: can't find referenced class org.apache.commons.beanutils.ConversionException
Warning: com.opencsv.bean.customconverter.ConvertGermanToBoolean: can't find referenced class org.apache.commons.beanutils.Converter
Warning: com.opencsv.bean.opencsvUtils: can't find referenced method 'java.lang.reflect.Field[] getAllFields(java.lang.Class)' in program class org.apache.commons.lang3.reflect.FieldUtils
Warning: okhttp3.logging.HttpLoggingInterceptor: can't find referenced class okhttp3.internal.http.HttpHeaders
Warning: okhttp3.logging.HttpLoggingInterceptor: can't find referenced class okhttp3.internal.http.HttpHeaders
Warning: okhttp3.logging.HttpLoggingInterceptor$Logger$1: can't find referenced class okhttp3.internal.platform.Platform
Warning: okhttp3.logging.HttpLoggingInterceptor$Logger$1: can't find referenced class okhttp3.internal.platform.Platform
Warning: okhttp3.logging.HttpLoggingInterceptor$Logger$1: can't find referenced class okhttp3.internal.platform.Platform`
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:transformClassesAndResourcesWithProguardForMSA_MGRelease'.
> Job failed, see logs for details
* Try:
Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Exception is:
org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':app:transformClassesAndResourcesWithProguardForMSA_MGRelease'.
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:100)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:70)
at org.gradle.api.internal.tasks.execution.OutputDirectoryCreatingTaskExecuter.execute(OutputDirectoryCreatingTaskExecuter.java:51)
at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:62)
at org.gradle.api.internal.tasks.execution.ResolveTaskOutputCachingStateExecuter.execute(ResolveTaskOutputCachingStateExecuter.java:54)
at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:60)
at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:97)
at org.gradle.api.internal.tasks.execution.CleanupStaleOutputsExecuter.execute(CleanupStaleOutputsExecuter.java:87)
at org.gradle.api.internal.tasks.execution.ResolveTaskArtifactStateTaskExecuter.execute(ResolveTaskArtifactStateTaskExecuter.java:52)
at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:52)
at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:54)
at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43)
at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:34)
at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker$1.run(DefaultTaskGraphExecuter.java:248)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:199)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:110)
at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:241)
at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:230)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.processTask(DefaultTaskPlanExecutor.java:123)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.access$200(DefaultTaskPlanExecutor.java:79)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:104)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:98)
at org.gradle.execution.taskgraph.DefaultTaskExecutionPlan.execute(DefaultTaskExecutionPlan.java:626)
at org.gradle.execution.taskgraph.DefaultTaskExecutionPlan.executeWithTask(DefaultTaskExecutionPlan.java:581)
at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.run(DefaultTaskPlanExecutor.java:98)
at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46)
at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55)
Caused by: java.lang.RuntimeException: Job failed, see logs for details
at com.android.build.gradle.internal.transforms.ProGuardTransform.transform(ProGuardTransform.java:196)
at com.android.build.gradle.internal.pipeline.TransformTask$2.call(TransformTask.java:221)
at com.android.build.gradle.internal.pipeline.TransformTask$2.call(TransformTask.java:217)
at com.android.builder.profile.ThreadRecorder.record(ThreadRecorder.java:102)
at com.android.build.gradle.internal.pipeline.TransformTask.transform(TransformTask.java:212)
at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:73)
at org.gradle.api.internal.project.taskfactory.IncrementalTaskAction.doExecute(IncrementalTaskAction.java:46)
at org.gradle.api.internal.project.taskfactory.StandardTaskAction.execute(StandardTaskAction.java:39)
at org.gradle.api.internal.project.taskfactory.StandardTaskAction.execute(StandardTaskAction.java:26)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter$1.run(ExecuteActionsTaskExecuter.java:121)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:199)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:110)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:110)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:92)
... 29 more
Caused by: java.io.IOException: Please correct the above warnings first.
at proguard.Initializer.execute(Initializer.java:473)
at proguard.ProGuard.initialize(ProGuard.java:233)
at proguard.ProGuard.execute(ProGuard.java:98)
at com.android.build.gradle.internal.transforms.BaseProguardAction.runProguard(BaseProguardAction.java:61)
at com.android.build.gradle.internal.transforms.ProGuardTransform.doMinification(ProGuardTransform.java:253)
at com.android.build.gradle.internal.transforms.ProGuardTransform.access$000(ProGuardTransform.java:63)
at com.android.build.gradle.internal.transforms.ProGuardTransform$1.run(ProGuardTransform.java:173)
at com.android.builder.tasks.Job.runTask(Job.java:47)
at com.android.build.gradle.tasks.SimpleWorkQueue$EmptyThreadContext.runTask(SimpleWorkQueue.java:41)
at com.android.builder.tasks.WorkQueue.run(WorkQueue.java:282)
* Get more help at https://help.gradle.org
BUILD FAILED in 14s
21 actionable tasks: 5 executed, 16 up-to-date
答案 0 :(得分:0)
在proguard中添加以下行。
-dontwarn com.opencsv。**
-dontwarn okhttp3.logging。**
-dontwarn com.j256。**
-dontwarn com.sun。**
尝试清理并重新生成签名的apk。