Project uses one of the Lottie animations. There was a need to upgrade to AndroidX libraries and Xamarin.Android 11.
**com.airbnb.lottie.parser.moshi.JsonReader.syntaxError**
com.airbnb.lottie.parser.moshi.JsonEncodingException: Use JsonReader.setLenient(true) to accept malformed JSON at path $
com.airbnb.lottie.parser.moshi.JsonReader.syntaxError JsonReader.java:249
com.airbnb.lottie.parser.moshi.JsonUtf8Reader.checkLenient JsonUtf8Reader.java:951
com.airbnb.lottie.parser.moshi.JsonUtf8Reader.doPeek JsonUtf8Reader.java:347
com.airbnb.lottie.parser.moshi.JsonUtf8Reader.beginObject JsonUtf8Reader.java:136
com.airbnb.lottie.parser.LottieCompositionMoshiParser.parse LottieCompositionMoshiParser.java:57
Expected behavior
Support for UTF-8 with BOM encoded json files as it was before version 3.4.0. For instance, Lottie NuGet 3.0.6 worked fine with UTF-8 with BOM files.
Reproduction steps
Just simply try to play animation.
Looks like it has something to do with "UTF-8 with BOM" encoding. UTF-8 encoded file works just fine.
There are two json files in the archive for test purposes: "UTF-8" and "UTF-8 with BOM".
utf8_bom.zip
🐛 Bug Report
Project uses one of the Lottie animations. There was a need to upgrade to AndroidX libraries and Xamarin.Android 11.
Expected behavior
Support for UTF-8 with BOM encoded json files as it was before version 3.4.0. For instance, Lottie NuGet 3.0.6 worked fine with UTF-8 with BOM files.
Reproduction steps
Just simply try to play animation.
Looks like it has something to do with "UTF-8 with BOM" encoding. UTF-8 encoded file works just fine. There are two json files in the archive for test purposes: "UTF-8" and "UTF-8 with BOM". utf8_bom.zip
Configuration
Xamarin.Android 11
Version: 3.5.0
Platform: