问题
I am having issues using dexguard when it comes to flexjson library. I keep getting the following error when trying to deserialize using JSONDeserializer.
**09-15 20:46:10.271 10901-11552/** **A/art: sart/runtime/class_linker.cc:3430] Check failed: klass->IsProxyClass()**
Does anyone have the proper rules for flexjson to work properly after obfuscation in android release apks?
Something similar to gson lib.
回答1:
Chances are that this is on a Samsung device -- a few device models and Android versions have problems with some UTF-8 encoded unicode characters. You should try updating DexGuard to the latest version. Otherwise, you can also try working around it by using a simple obfuscation dictionary:
-classobfuscationdictionary empty.txt
where empty.txt is an empty file.
回答2:
We've had the same issue on a few Samsung devices (Galaxy J1 and J5 on Android 5.1.1). The application just wouldn't start.
There is no information about the issue in Crashlytics nor in Google Play. Eventually we've had contact with GuardSquare who told us to update to the fresh DexGuard 8.0.06. This version includes a new dictionary which solves the ANR on these devices.
Using the line below as Eric mentioned works as well. Although this will only use ASCII chars as a collegae of him mentioned. I've just asked if there is any downside on using this. Cause it might avoid future issues.
-classobfuscationdictionary empty.txt
来源:https://stackoverflow.com/questions/39522351/flexjson-and-dexguard-proguard