Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

java.lang.RuntimeException: Missing type parameter [closed]

Tags:

java

android

gson

My project encountered this error:

enter image description here

I tried to fix it using this link

but I can not because I do not really understand the answer. Please tell me how to fix it. Thanks

like image 418
Tâm Lê Avatar asked Nov 23 '25 19:11

Tâm Lê


1 Answers

I faced the same issue with Gson library and searched for the solution a lot but none of them work for me then I read the R8 full mode true changes and added this three-line in proguard and it worked fine for me.

if someone face the same issue, you can try this:

-keep class com.google.gson.reflect.TypeToken
-keep class * extends com.google.gson.reflect.TypeToken
-keep public class * implements java.lang.reflect.Type
like image 150
Deluar Hossen Avatar answered Nov 26 '25 09:11

Deluar Hossen