-
-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: java.lang.StackOverflowError: stack size 8MB #1298
Comments
+1 |
@namkazt @shenghaiyang Can you attach a sample project that reproduces this? |
@gpeal I think it relates to Lottie not release or pause when invisible or something. It did not happen on my device but 1 user. I just got some crash report about it. |
I got the same issue recently on Lottie 3.0.7, but all cases on Android 4.x . Any solution for this? @gpeal I can send the sample animations, but only via email because it's a closed sourced app of the office. Note that this didn't occur on older version of Lottie that we used (3.0.3) , and I don't think we added more animations since we used the other version. @namkazt on which version of Lottie did you have this?
|
the latest version I guess. I just start using Lottie recently |
@namkazt Well you can try v3.0.3 for now, perhaps. |
Sadly going to v3.0.3 causes this issue: |
@namkazt @AndroidDeveloperLB What are the steps to reproduce this? |
@gpeal sorry, I never got this on my side. Just report from Crashlytic that crash happens on some users devices. but is it look like this |
@gpeal It's all reported by hundreds of crashes on Crashlytics. One issue is on Android 4.x and another issue is on Android 8.0. We have only 2 json files for Lottie. If you wish, I can send you via email and you could check them out. The use case is just showing AnimationView with the animation on the raw folder. I hope that putting them into the assets folder will fix it. |
@namkazt @AndroidDeveloperLB I don't think that will fix it. If you are able to repro it, that would be great. I just tested an animation on KitKat and it worked fine. You can use animations from Lottiefiles if you don't want to share your own. |
@gpeal I don't mind to share mine. But I don't own them. The company does. And so I said I can send you via email instead. And it's actually 2 bugs. One on the old version (3.0.3) of Lottie, and one on the new one (3.0.7). |
@AndroidDeveloperLB I never said it didn't exist. I just need to be able to reproduce it to fix it. |
@gpeal Recently I got a lot of messages from Google similar to "We can't reproduce it so we close this issue". In any case, I already offered you the animation files. |
Everything works well. But when I change fragment while the animation is running my app gets crashed.
|
@Smarpit-Singh Can you create a sample project that reproduces this? That would be super helpful. |
Thank you for your response but I already solve this. This exception has arrived when I close the |
@Smarpit-Singh This sounds like a workaround that you shouldn't need to use at all. |
An update: This seems to help a lot, but not in 100% of the times. I hope it's indeed helping and not just me being optimistic. I wonder if the same trick could help with 3.0.7. Can anyone try it too? |
@AndroidDeveloperLB Any help reproing this would be appreciated. As soon as I have a repro, I'll fix it and push an update. |
@gpeal I already told you multiple times: I can help you with whatever you wish. Just ask. I do not know how to reproduce it, because of this reason . Anyway, currently the situation is as such: So the only check that is left is: Sadly I'm in no position to make this kind of test on millions of users. If anyone here tries it, please let me know. EDIT: seems this didn't help. The crash still occurs for many |
for now I'm using |
I've tried now on Xiaomi "Mi Phone" which has Android 4.4.4, and succeeded getting the crash! I'm will try to make a POC that will show the issue. Hopefully I will be able to reproduce it on the POC too. |
Got a POC to reproduce the issue. It was caused when switching to its container via ViewAnimator:
It occurs even when I give the LottieAnimationView a simple VectorDrawable. Attached here the POC. Please check it out. Note that it occurs only on 4.4, but succeeded to reproduce it even on emulator, so you don't need to use a device. As I wrote, it doesn't even need an animation file to play, to reproduce the crash. Here's a video showing that indeed this is the cause for it, on 4.4 emulator: Possible workaround is to set visibility instead of switching views. |
@namkazt @shenghaiyang @AndroidDeveloperLB 3.1.0-SNAPSHOT will be up with this fix any minute. |
Thank you @AndroidDeveloperLB, the repro was helpful 😄 |
@gpeal Can you please explain why this happened? |
@gpeal Thanks 😄 |
@namkazt I hope this is the only cause for this issue. |
I'm not able to test it yet but i will. |
@AndroidDeveloperLB |
@gpeal I mean what to put in the dependency. |
@AndroidDeveloperLB repositories {
/** ... **/
// this is for lottie SNAPSHOT
maven { url "https://oss.sonatype.org/content/repositories/snapshots" }
} Then, use SNAPSHOT version in deps: implementation 'com.airbnb.android:lottie:3.1.0-SNAPSHOT' |
@rimmer |
@AndroidDeveloperLB |
@rimmer Other than the sample I've shown, have you tried similar cases? switching between different LottieAnimationView instances, for example? Maybe while one is playing? |
@AndroidDeveloperLB No known issues with the latest snapshot |
So far, I haven't got any crashes. Didn't thoroughly testing however
вт, 20 авг. 2019 г., 20:26 Gabriel Peal <notifications@github.com>:
… @AndroidDeveloperLB <https://github.com/AndroidDeveloperLB> No know
issues with the latest snapshot
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1298?email_source=notifications&email_token=AALPLAWQ7DDKUQSCEOIHEG3QFQZO3A5CNFSM4H4XSGR2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD4XHKHY#issuecomment-523138335>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AALPLATF6NGBQX5XKTMMJJLQFQZO3ANCNFSM4H4XSGRQ>
.
|
@AndroidDeveloperLB Not sure. It's there though |
@gpeal I know. The POC works fine, but in the large project, which contains various modules, I had to add it to one of the modules which is more independent . I never did such a thing, I think... |
Is the 3.1.0 available now? Somehow Android Studio told me it, but I don't see it mentioned here: https://mvnrepository.com/artifact/com.airbnb.android/lottie |
@AndroidDeveloperLB It is. |
Weird. I didn't see it there . |
@gpeal Also here now: |
I think 3.1.0 doesn't have this issue. Thank you for fixing! |
I'm not really sure why it happens but maybe i'm not releasing my fragment ( there is 3 fragment on top and each of it has 1 Lottie animation view )
Device: P6 android 5.0
The text was updated successfully, but these errors were encountered: