Closed 256p closed 8 months ago
Thanks, we will look into this issue.
@256p, add to proguard-user.txt:
-keep class com.google.android.ump.** { public *; }
@NVentimiglia, it would be useful to include a note about Proguard/R8 in the implementation documentation.
Thanks,
We will look into this.
Confirming the issue. If you use magnification please add a custom proguard file.
-keep class com.google.** { public *; }
@NVentimiglia .. there isn't a whole lot of point using minification if you're going to put rules like that into proguard. The purpose is to slim down your build by removing unneeded code. Can someone suggest a set of less inclusive proguard rules for using admob?
@batteredhedgehog you can try
-keep class com.google.android.ump.** { public *; }
[REQUIRED] Step 1: Describe your environment
[REQUIRED] Step 2: Describe the problem
Steps to reproduce:
Relevant Code:
https://github.com/256p/ump-class-not-found
The reason of the issue is that UMP's Java classes are accessed from C# through reflection, and these Java classes aren't added to the Proguard rules to preserve them from obfuscation. All class names (except
com.google.unity.ump.*
) listed here https://github.com/googleads/googleads-mobile-unity/blob/main/source/plugin/Assets/GoogleMobileAds/Ump/Platforms/Android/Utils.cs aren't accessible after obfuscation. Probably need to add native bridging UMP implementation to theandroid-library
.