mapbox / mapbox/mapbox-navigation-ios
[Bug]: Alternative route line partially missing when overlapping with main route
Nobody has claimed this yet.
- Dominant language
- Swift
- Stars
- 918
- Forks
- 326
- Avg merge
- 1h 16m
- Merged PRs (30d)
- 3
Description
Mapbox Navigation SDK version
3.10.2
Steps to reproduce
Platform: iOS
SDK version: 3.10.2
Device: iPhone 14 Pro Max(iOS 18.6 / iOS 26)
Map style: mapbox://styles/mapbox/dark-v11
When displaying a long-distance route (hundreds of kilometers) that includes alternative routes, parts of the alternative route line are not rendered on the map.
The issue only occurs for alternative routes, not for the main route.
[REPRODUCE]
-
Request a long-distance route (e.g. 600+ km) with alternatives enabled.
-
Let the SDK render both the main and alternative routes automatically after DirectionsResponse.4.
-
Observe the map view:- Some sections of the alternative route are missing.
- Switching the same route to become the main route makes the missing parts appear correctly.
- The missing segment typically corresponds to the portion that overlaps with the main route.
-
Adjust the zoom level:
- When zooming in, the missing segments gradually appear.
- When zooming out, the same segments disappear again.
Expected behavior
All routes (main and alternatives) should be rendered completely and consistently, including the overlapping sections, regardless of zoom level or route role.
Actual behavior
Only alternative routes have missing segments.
Missing sections correspond exactly to the overlapping area with the main route.
Switching that alternative to become the main route causes it to render correctly.
The visibility of missing sections changes dynamically with zoom level — visible when zoomed in, missing when zoomed out.
Is this a one-time issue or a repeatable issue?
repeatable
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.
Research direction
Reproduce the issue on iOS 18.6 or iOS 26 with Mapbox Navigation SDK 3.10.2, a 600+ km route, alternatives enabled, and the dark-v11 style. Start by tracing the route rendering path for alternative routes and their overlapping segments. Done means main and alternative routes render completely and consistently at every zoom level.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ios, swift
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100