Closed fdhsdrdark closed 2 years ago
You use malformed JSON.
@martijn00 Thanks for getting back on this so fast. It turns out that the downloaded json file had tabs and whitespaces that make version 4.2.2 crash. Removed them, made the file single line - all working as expected. Just shared the info in case someone stumbles up on this.
🐛 Bug Report
On version upgrade from 3.0.6 version to 4.2.2 the attached Lottie animation causes application crash. It a free working animation retrieved from https://lottiefiles.com/341-watch-progress
Expected behavior
Play Animation
Reproduction steps
Use the attached animation with version 4.2.2.
The exception I get is: java.lang.IllegalStateException: Unable to parse composition at com.airbnb.lottie.LottieAnimationView$1.onResult(LottieAnimationView.java:79) at com.airbnb.lottie.LottieAnimationView$1.onResult(LottieAnimationView.java:72) at com.airbnb.lottie.LottieAnimationView$3.onResult(LottieAnimationView.java:96) at com.airbnb.lottie.LottieAnimationView$3.onResult(LottieAnimationView.java:89) at com.airbnb.lottie.LottieTask.notifyFailureListeners(LottieTask.java:162) at com.airbnb.lottie.LottieTask.access$200(LottieTask.java:28) at com.airbnb.lottie.LottieTask$1.run(LottieTask.java:137) at android.os.Handler.handleCallback(Handler.java:883) at android.os.Handler.dispatchMessage(Handler.java:100) at android.os.Looper.loop(Looper.java:237) at android.app.ActivityThread.main(ActivityThread.java:8167) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:496) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1100) Caused by: com.airbnb.lottie.parser.moshi.JsonEncodingException: Use JsonReader.setLenient(true) to accept malformed JSON at path $
Configuration
No particular configuration
Version: 4.2.2 - Android Version 10
Platform: Xamarin Android clock_animation.txt