Replies: 2 comments 1 reply
-
{can i have your proguard rule file} when u minifyenabled = true u have to add Proguard rules and u have to use ignore case inside that for your retrofit package and java file |
Beta Was this translation helpful? Give feedback.
-
Hello Andymarch, Here are my proguard rules, there are only rules related to retrofit. //#------------------------------------------------------------------------------------------------------------------------- //# Retrofit does reflection on generic parameters. InnerClasses is required to use Signature and //# Retrofit does reflection on method and parameter annotations. //# Keep annotation default values (e.g., retrofit2.http.Field.encoded). //# Retain service method parameters when optimizing. //# Ignore annotation used for build tooling. //# Ignore JSR 305 annotations for embedding nullability information. //# Guarded by a NoClassDefFoundError try/catch and only used when on the classpath. //# Top-level functions that can only be used by Kotlin. //# With R8 full mode, it sees no subtypes of Retrofit interfaces since they are created with a Proxy //# Keep inherited services. //# With R8 full mode generic signatures are stripped for classes that are not //# R8 full mode strips generic signatures from return types if not kept. //# With R8 full mode generic signatures are stripped for classes that are not kept. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
i've searched nearly two days for an answer but nothing helps.
I want to implement retrofit in my project because of the deprecated AsyncTask function.
Now i have the following problem:
I have to use minifyenabled = true in my release, there is no option to disable it.
But when I enable this feature I get always the following Exception:
java.lang.IllegalArgumentException: Unable to create call adapter for interface retrofit2.Call for method TCWebserviceApi.logout
Thats my Configurations/Code:
Gradle.Bundle:
implementation 'com.squareup.retrofit2:retrofit:2.9.0'
implementation 'com.squareup.retrofit2:converter-scalars:2.9.0'
My Interface:
My RestClient:
I dont use any converters, need only string as result to do further work...
Gradle Version 8.5
I've tried to add the retrofit2.pro, add some rules to the proguard-rules.pro but nothing helps.
How can i solve the problem?
Beta Was this translation helpful? Give feedback.
All reactions