问题
We are getting following error with Firebase and R8.
[CIRCULAR REFERENCE:java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: Multiple entries with same key: Method com.google.firebase.iid.FirebaseInstanceId.zza Proto LLL com.google.android.gms.tasks.Task java.lang.String java.lang.String=Encoded method Method com.google.firebase.iid.FirebaseInstanceId.zza Proto LLL com.google.android.gms.tasks.Task java.lang.String java.lang.String and Method com.google.firebase.iid.FirebaseInstanceId.zza Proto LLL com.google.android.gms.tasks.Task java.lang.String java.lang.String=Encoded method Method com.google.firebase.iid.FirebaseInstanceId.zza Proto LLL com.google.android.gms.tasks.Task java.lang.String java.lang.String]
Please help me with any further pointers to debug this. Let me know if more logs are required to debug this.
EDIT: Its fixed 3.4.0-beta02 onwards.
回答1:
I've had this error as well in the latest Android Studio 3.5. Fixed it by following the links to the Google Issue Tracker, and by just adding this line in my Proguard rules :
-keep class com.google.firebase.iid.FirebaseInstanceId { zza(...); }
回答2:
This issue popped up for me today aswell. It's reported here, seems they're working on it.
回答3:
This should be fixed in R8 version 1.5.25, see https://issuetracker.google.com/132575649#comment8 how to use that, or wait for Andriod Studio 3.4.0-beta02 which should have the fix included.
来源:https://stackoverflow.com/questions/56108316/circular-reference-error-in-firebase-with-r8