-
Notifications
You must be signed in to change notification settings - Fork 126
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
[BUG] updateMyLocationEnabled()
call on style load causes a crash
#534
Labels
bug
Something isn't working
Comments
Received maybe a bit better stack trace:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Platforms
android
Version of flutter maplibre_gl
0.20.0
Bug Description
In specific cases that I'm yet to determine the call to
updateMyLocationEnabled()
inonStyleLoadedCallback
causes an app crash due to unhandledLocationComponentNotInitializedException
.Here's a stack trace of such crash:
Steps to Reproduce
I'm unsure about the absolute root cause, but this bug started happening when I wired
myLocationEnabled
to location availability stream. It's likely that there is a race condition withmyLocationEnabled
value being changed before map view initialization is finished.You can see an example of the setup in the code sample below.
Expected Results
Location manager is initialized without a crash.
Actual Results
Location manager initialization fails and causes an app crash.
Code Sample
The text was updated successfully, but these errors were encountered: