mapbox / mapbox/mapbox-navigation-ios
[Bug]: Maneuver arrows mirror via imageOrientation only, so CarPlay draws left turns pointing right
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.25.1
### Steps to reproduce
1. Show CarPlay maneuvers the way `CarPlayNavigationViewController` does, by assigning
`CPManeuver.symbolSet `from `VisualInstruction.maneuverImageSet(side:visualInstruction:)`,
or `CPManeuver.symbolImage` from an equivalent `ManeuverView` snapshot.
2. Navigate a route containing a left turn, in a country that drives on the right.
3. Look at the maneuver symbol in the CarPlay guidance card.
Measured on a physical head unit, iOS 26, SDK 3.25.1.
### Expected behavior
The CarPlay maneuver symbol points in the direction of the maneuver.
For a `VisualInstruction` with `maneuverDirection == .left`, the arrow in the
CarPlay guidance card points left.
### Actual behavior
The arrow points right. Left and right are swapped for every maneuver that `ManeuverView` renders by mirroring:
- .left / .slightLeft / .sharpLeft
- U-turns where drivingSide == .right
- roundabouts and rotaries where drivingSide == .left
Right turns, straight-ahead and arrivals are unaffected.
The map, the banner text and the spoken instruction are all correct at the same
time. Only the CarPlay symbol is wrong, which makes it easy to miss: the driver
is told "turn left", the route line turns left, and the icon in the corner
points right.
Only the snapshot path is affected. The in-app banner uses `ManeuverView` as a
live subview and looks correct. The CarPlay symbol comes from a `UIImage`
snapshot of the same view, and that is where the mirroring is lost.
### 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
Start at CarPlayNavigationViewController and trace VisualInstruction.maneuverImageSet(side:visualInstruction:) into the CPManeuver symbol snapshot path, comparing it with the live ManeuverView behavior. Reproduce a left turn and the listed driving-side cases on CarPlay, then verify that snapshot symbols point in the same direction as the maneuver and that unaffected symbols remain unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ios, swift
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 70/100