NPE at com.airbnb.lottie.model.layer.BaseLayer.intersectBoundsWithMask(BaseLayer.java:349)
See original GitHub issueChecklist
- Fork this repository into your account.
- Reproduce your issue in the issue-repro module. Issues without a repro in the issue-repro module may be auto-closed.
Link to fork with a repro in the issue-repro module
Describe the bug
Hello! This report is about a crash that is happening in production and, with a certain frequency, on the Play Store pre-launch reports too. Sadly I’ve never been able to reproduce it locally. Here’s the relevant stacktrace and please let me know if you would like to see more info about the audience of this crash.
java.lang.NullPointerException: Attempt to read from field 'boolean android.graphics.Path.isSimplePath' on a null object reference
at android.graphics.Path.set(Path.java:106)
at com.airbnb.lottie.model.layer.BaseLayer.intersectBoundsWithMask(BaseLayer.java:349)
at com.airbnb.lottie.model.layer.BaseLayer.draw(BaseLayer.java:266)
at com.airbnb.lottie.model.layer.CompositionLayer.drawLayer(CompositionLayer.java:120)
at com.airbnb.lottie.model.layer.BaseLayer.draw(BaseLayer.java:254)
at com.airbnb.lottie.model.layer.BaseLayer.draw(BaseLayer.java:300)
at com.airbnb.lottie.model.layer.CompositionLayer.drawLayer(CompositionLayer.java:120)
at com.airbnb.lottie.model.layer.BaseLayer.draw(BaseLayer.java:254)
at com.airbnb.lottie.model.layer.CompositionLayer.drawLayer(CompositionLayer.java:120)
at com.airbnb.lottie.model.layer.BaseLayer.draw(BaseLayer.java:254)
at com.airbnb.lottie.LottieDrawable.drawWithOriginalAspectRatio(LottieDrawable.java:1292)
at com.airbnb.lottie.LottieDrawable.drawInternal(LottieDrawable.java:403)
at com.airbnb.lottie.LottieDrawable.draw(LottieDrawable.java:393)
at android.widget.ImageView.onDraw(ImageView.java:1367)
at android.view.View.draw(View.java:19337)
at android.view.View.buildDrawingCacheImpl(View.java:18562)
at android.view.View.buildDrawingCache(View.java:18418)
at com.airbnb.lottie.LottieAnimationView.buildDrawingCache(LottieAnimationView.java:1085)
at android.view.View.draw(View.java:19044)
at android.view.ViewGroup.drawChild(ViewGroup.java:4301)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4085)
at androidx.constraintlayout.widget.ConstraintLayout.dispatchDraw(ConstraintLayout.java:1975)
at android.view.View.draw(View.java:19345)
at android.view.View.updateDisplayListIfDirty(View.java:18254)
at android.view.View.draw(View.java:19052)
at android.view.ViewGroup.drawChild(ViewGroup.java:4301)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4085)
at android.view.View.updateDisplayListIfDirty(View.java:18245)
at android.view.View.draw(View.java:19052)
at android.view.ViewGroup.drawChild(ViewGroup.java:4301)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4085)
at android.view.View.updateDisplayListIfDirty(View.java:18245)
at android.view.View.draw(View.java:19052)
at android.view.ViewGroup.drawChild(ViewGroup.java:4301)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4085)
at android.view.View.updateDisplayListIfDirty(View.java:18245)
at android.view.View.draw(View.java:19052)
at android.view.ViewGroup.drawChild(ViewGroup.java:4301)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4085)
at android.view.View.updateDisplayListIfDirty(View.java:18245)
at android.view.View.draw(View.java:19052)
at android.view.ViewGroup.drawChild(ViewGroup.java:4301)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4085)
at android.view.View.draw(View.java:19345)
at com.android.internal.policy.DecorView.draw(DecorView.java:792)
at android.view.View.updateDisplayListIfDirty(View.java:18254)
at android.view.ThreadedRenderer.updateViewTreeDisplayList(ThreadedRenderer.java:678)
at android.view.ThreadedRenderer.updateRootDisplayList(ThreadedRenderer.java:684)
at android.view.ThreadedRenderer.draw(ThreadedRenderer.java:792)
at android.view.ViewRootImpl.draw(ViewRootImpl.java:3164)
at android.view.ViewRootImpl.performDraw(ViewRootImpl.java:2964)
at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2502)
at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1482)
at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:7124)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1008)
at android.view.Choreographer.doCallbacks(Choreographer.java:804)
at android.view.Choreographer.doFrame(Choreographer.java:732)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:994)
at android.os.Handler.handleCallback(Handler.java:794)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:176)
at android.app.ActivityThread.main(ActivityThread.java:6662)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:547)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:873)
Steps To Reproduce Steps to reproduce the behavior: sadly they are unknown
Issue Analytics
- State:
- Created 2 years ago
- Comments:7
Top Results From Across the Web
BaseLayer.applyMasks NullPointerException #2096 - GitHub
My animation doesn't use any unsupported features. I know what part of my animation doesn't work. I have created a simplified version of...
Read more >Setting custom font into lottie android - Stack Overflow
Above screenshot is my fonts folder. But when I run the application, it gives error. java.lang.RuntimeException: Font asset not found fonts/Arial.ttf at android ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@matteinn You can use 4.2.1-SNAPSHOT now or wait for the next patch release which should be coming out soon. This is the safeMode API.
@gpeal where can I find the documentation about this “safe mode”? Is this a new feature about to be released? From what I see in https://github.com/airbnb/lottie-android/pull/1939 it looks like no changes will be required on consumer apps, besides upgrading to the next SDK version which will contain that PR