mapbox / mapbox/mapbox-navigation-ios
Preserve user's historic route progress upon rerouting
Open
@frederoni is already working on this.
Since Dec 10, 2018.
feature
jira-sync-complete
platform parity
- Dominant language
- Swift
- Stars
- 918
- Forks
- 326
- Avg merge
- 1h 16m
- Merged PRs (30d)
- 3
Description
Currently, when a user is navigating a route and a re-route event occurs the visual history of the route traveled is removed when the new route is set.
Instead we should merge the new route onto the historic route traveled, so that the user's end-to-end journey is displayed. It should also be the case that the user's fractionTraveled is preserved so that end-to-end progress calculations take the full route/journey into consideration.
As a driver navigating a route, when I stray from the route and obtain a new route, my historic progress should still be displayed, so that I can see where I have been.
A few things need to happen for this to work correctly (acceptance criteria):
- Route line is spliced
- (implementation detail) last step the user was on needs to have its distance truncated when joined to the beginning of the new route
Waypoint indices remain sequential start-to-finishShould this be supported at the directions API or via client-side (AKA offline) routing or spliced client-side? (@mcwhittemore we should discuss). This is size:M if we can do this at the server, size:L otherwise.(to be moved to a subsequent ticket) - @akitchen
Merging previous steps - need to account for the last step before the re-route - we should denote the re-route point for debugging purposes.(needs verification)RouteProgress.fractionTraveledand other computed properties related to historic travel should correctly account for the historic distance traveled plus the distance remaining up the new remainder of the route
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.