Gson: new Proguard errors

Created on 19 Oct 2017  Â·  6Comments  Â·  Source: google/gson

Warning: library class com.google.gson.Gson$6 extends or implements program class com.google.gson.TypeAdapter
Warning: library class com.google.gson.Gson$6 depends on program class com.google.gson.stream.JsonWriter
Warning: library class com.google.gson.Gson$6 depends on program class com.google.gson.stream.JsonReader
Warning: library class com.google.gson.Gson$6 depends on program class com.google.gson.stream.JsonReader
Warning: library class com.google.gson.Gson$6 depends on program class com.google.gson.stream.JsonWriter

And this is with using the proguard suggested in
https://github.com/google/gson/blob/master/examples/android-proguard-example/proguard.cfg

Most helpful comment

-dontwarn com.google.gson.Gson$6

All 6 comments

it's funny that it is also the same error for us with $6.
-dontwarn works for us.

Are you guys using android gradle plugin 3.0? I got the same error with 3.0-RC2 and -dontwarn works

What exactly does your -dontwarn look like?

-dontwarn com.google.gson.Gson$6

I now face the same issue after upgrading the gradle plugin to ‘3.0.0’ and support Lib to 27 on Android studio . The suggested solution did not work for me . @ncapdevi , any solutions which helped you ?

I was replacing compile with implementation and api, i ran into this issue with release build, too. -dontwarn com.google.gson.Gson$6 works for me

Was this page helpful?
0 / 5 - 0 ratings

Related issues

GoogleCodeExporter picture GoogleCodeExporter  Â·  16Comments

priyankajagtap18 picture priyankajagtap18  Â·  14Comments

GoogleCodeExporter picture GoogleCodeExporter  Â·  17Comments

GoogleCodeExporter picture GoogleCodeExporter  Â·  31Comments

GoogleCodeExporter picture GoogleCodeExporter  Â·  20Comments