Project-OSRM / osrm-text-instructions

Text instructions from OSRM route responses
BSD 2-Clause "Simplified" License
90 stars 63 forks source link

Redundant maneuver modifiers in Danish #258

Closed 1ec5 closed 5 years ago

1ec5 commented 6 years ago

Per mapbox/mapbox-navigation-android#1101, some instructions in the Danish localization include redundant directional modifiers:

In Danish, when the voice instructs you to turn left (or right), it says "Drej til venstresving" - literally, "Turn left turn" where it should be "Drej til venstre" (Turn left). Same goes with "Drej til højresving" -> "Drej til højre".

This is evident from our test fixtures:

https://github.com/Project-OSRM/osrm-text-instructions/blob/7a0cef33f1b0f669384cd9d8f4862cec721b92f3/test/fixtures/v5/merge/left_default.json#L11

The affected maneuver types are roundabout_turn, fork, new_name, merge, notification, off ramp (“Take exit 123 on the left turn”), end_of_road, turn, and continue.

Part of the problem is that the generic words for “left”, “sharp left”, etc. have been translated as “left turn”, “sharp left turn”, etc.

https://github.com/Project-OSRM/osrm-text-instructions/blob/e21d464584de6ebdf038ecd551ecace417cf88b9/languages/translations/da.json#L30-L35

Some localizations have done this intentionally because there’s no way to isolate the word “left” but insert it into a sentence after the fact. I’m not sure if this is the case for Danish; we might be able to just simplify the modifier translations. Ideally, common maneuvers would never have to insert the modifier entries. However, we’re currently relying on those entries in a few too many cases: #240.

/cc @danesfeder @cmahopper