-
Notifications
You must be signed in to change notification settings - Fork 509
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
Fix flutter 3.x crashes #1293
Fix flutter 3.x crashes #1293
Conversation
@srmanc please take a look as well |
That's great! I'll test it out ASAP. |
We did a partial roll out with this fix and have yet to see a crash (19 users active users today) |
@felix-ht To me it looks good, our tests have also shown no crashes. Great work! |
Bigger roll out - two days no more crashes seems like its gone :) |
👏 Now let's focus on some other PRs as well. ;) |
altho this runs fine on real android device. but it throw lots of error on my android simulator |
This reverts commit 9eef30d.
hello i have same problem, im still can't understand what is the solution, my current flutter version is 3.16.0-2.0.pre.20 and mapbox_gl: ^0.16.0 so, my app is still crashed when i put myLocationEnabled to true. |
This finally seems to fix the crashes we were getting with version 3.x of flutter - i only tested with version 3.7.8 - but it might be fine on lower versions as well.
I could also remove the delayed disposal hack.
I found this by checking the how the new offical mapbox flutter lib was doing the map onDestroy. Turns out they call the onStop before the onDestory
https://github.com/mapbox/mapbox-maps-flutter/blob/47e0ec050aac30f7052e1090a61c5a8d5295d01e/android/src/main/kotlin/com/mapbox/maps/mapbox_maps/MapboxMapController.kt#L78-L79