-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Android: crash when using library that also uses Lost for location #8639
Comments
I've noticed that this only triggers if I invoke |
@chen-factual thank you for reaching out and reporting your issue. You can follow along progress on this ticket in the upstream issue in lostzen/lost#173. Another issue related to this is found in mapbox/mapbox-java#401. The workaround for now is not to start location request in another thread. I'm going to remove release blocker label as this isn't an Mapbox Android SDK issue. Will be closing this when we upgrade to a newer version of our LOST dependency. |
This has now been fixed upstream, I'm adding the release blocker tag hoping we can include the fix before 5.1 final (we're depending on LOST releasing 2.3 on time). |
We'd also like to update our MAS dependency to the next release, where we also plan to update LOST. Work is tracked on mapbox/mapbox-java#401. |
This crash is now fixed in the latest Lost 2.3 SNAPSHOT. Please note this is not a small set of changes to the library that will require a bit of testing plus there are a few other issues we want to have resolved in version 2.3. No release date has been set as of yet but we are working to get it released as quickly as possible. Thanks for everyone's patience! |
Capturing from #8999 that this issue is resolved. Closing. |
I'm writing an application that uses MapView. I'm using a library that also uses the Lost API under the hood, and the location updates being requested of that library is crashing MyLocationView:
This can be replicated by starting a separate Lost listener on another thread. Here's snippets from a minimal reproducing example (sorry for stuffing all the Lost stuff in one function :-/), based largely off of the example app. The
initializeLocation()
andinitializeMap()
calls are basically code from the example app that sets upLocationEngineListener
andMapView
.I spin up a new thread and wait a few seconds to let MapView get set up, then I go ahead and register a second Lost listener independent of anything in the Mapbox SDK. When
LocationSource.onLocationChanged
picks up the updates from this separate thread you should crash and see the stacktrace above.The text was updated successfully, but these errors were encountered: