[Bug]: Route line is missing while in navigation
Mapbox Navigation SDK version
Mapbox navigation 2.18.4
Steps to reproduce
We are using .gpx file to simulate user location update from 22 Bellios Lane to 9 Boon Keng Rd
- We start trip first time and simulate user location to destination using .gpx file
- When user reach to the destination we stop navigation
- After that we reset user location using the same .gpx file
- When we start the second trip to the same destination again, using same .gpx file, at this time the route line is missing in navigation
I have a question:
- Is there any caching data from Mapbox sdk that recorded user already reached to destination . And after that if user start the same trip to the same destination Mapbox will immediately updated user is on arrive destination ?
- If we have caching data like that, how can we clean it up to start the second trip normally ?
Expected behavior
When we start the second trip at step 4 the route line should be shown normally while app is in navigation
Actual behavior
Route line is missing in second trip navigate to the same location
Is this a one-time issue or a repeatable issue?
repeatable
Hi @santoso8118
Thank you for your report. Could you please provide additional details, like screenshots? From what I understood, the problem is not that the route is not displayed on the second simulation, but it should be rather that the user location simulation remains at the destination from the previous navigation.
For simulation scenarios, my recommendation is to recreate MapboxNavigationProvider instance to clear the previous navigation location state.
As for the Nav SDK v2 version, you will need to recreate MapboxNavigationService instance.