Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Animation stopped working on Android #383

Open
2 of 7 tasks
tomh4 opened this issue May 23, 2022 · 3 comments
Open
2 of 7 tasks

Animation stopped working on Android #383

tomh4 opened this issue May 23, 2022 · 3 comments

Comments

@tomh4
Copy link

tomh4 commented May 23, 2022

馃敊 Regression

We had animations loading on Android and iOS, and somehow (maybe with Android 12? Not sure!) They stopped working on Android, but still work on iOS.

Old (and correct) behavior

Displaying the animation on both platforms

Current behavior

Crashing on Android

Java.Lang.NullPointerException: Attempt to invoke virtual method 'com.airbnb.lottie.animation.keyframe.BaseKeyframeAnimation com.airbnb.lottie.model.animatable.AnimatableFloatValue.createAnimation()' on a null object reference
  at java.lang.NullPointerException: Attempt to invoke virtual method 'com.airbnb.lottie.animation.keyframe.BaseKeyframeAnimation com.airbnb.lottie.model.animatable.AnimatableFloatValue.createAnimation()' on a null object reference
  at at com.airbnb.lottie.animation.content.TrimPathContent.<init>(TrimPathContent.java:24)
  at at com.airbnb.lottie.model.content.ShapeTrimPath.toContent(ShapeTrimPath.java:69)
  at at com.airbnb.lottie.animation.content.ContentGroup.contentsFromModels(ContentGroup.java:37)
  at at com.airbnb.lottie.animation.content.ContentGroup.<init>(ContentGroup.java:68)
  at at com.airbnb.lottie.model.layer.ShapeLayer.<init>(ShapeLayer.java:26)
  at at com.airbnb.lottie.model.layer.BaseLayer.forModel(BaseLayer.java:55)
  at at com.airbnb.lottie.model.layer.CompositionLayer.<init>(CompositionLayer.java:56)
  at at com.airbnb.lottie.LottieDrawable.buildCompositionLayer(LottieDrawable.java:322)
  at at com.airbnb.lottie.LottieDrawable.setComposition(LottieDrawable.java:221)
  at at com.airbnb.lottie.LottieAnimationView.setComposition(LottieAnimationView.java:586)
  at at com.airbnb.lottie.LottieAnimationView$2.onResult(LottieAnimationView.java:85)
  at at com.airbnb.lottie.LottieAnimationView$2.onResult(LottieAnimationView.java:83)
  at at com.airbnb.lottie.LottieTask.notifySuccessListeners(LottieTask.java:148)
  at at com.airbnb.lottie.LottieTask.access$100(LottieTask.java:28)
  at at com.airbnb.lottie.LottieTask$1.run(LottieTask.java:135)
  at at android.os.Handler.handleCallback(Handler.java:938)
  at at android.os.Handler.dispatchMessage(Handler.java:99)
  at at android.os.Looper.loop(Looper.java:223)
  at at android.app.ActivityThread.main(ActivityThread.java:7656)
  at at java.lang.reflect.Method.invoke(Native Method)
  at at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
  at at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)

Reproduction steps

Load the attached animation on Xamarin.Forms deployed to Android

Configuration

Version: 4.1.0

Platform:

  • 馃摫 iOS
  • 馃 Android
  • 馃弫 WPF
  • 馃寧 UWP
  • 馃崕 MacOS
  • 馃摵 tvOS
  • 馃悞 Xamarin.Forms
@tomh4
Copy link
Author

tomh4 commented May 23, 2022

anim.txt

@deelw
Copy link

deelw commented May 31, 2022

I have the same problem..

@deelw
Copy link

deelw commented Jun 3, 2022

@tomh4 I added Com.Airbnb.Android.Lottie to my Android project and now it works like a charm!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants