Uploaded image for project: 'Qt Mobility'
  1. Qt Mobility
  2. QTMOBILITY-1809

Requesting a rout via QGeoRoutingManager fails with language set to QLocale::C

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Reported
    • Priority: Not Evaluated
    • Resolution: Unresolved
    • Affects Version/s: 1.2.x
    • Fix Version/s: None
    • Component/s: Location
    • Labels:
      None
    • Environment:
      N950

      Description

      Requesting a rout via QGeoRoutingManager fails with language set to QLocale::C.
      This might no be a Qt specific bug but a bug I the navteq service used by the routing plugin.

      Resulting example request url:
      http://prd.lbsp.navteq.com/routing/6.2/calculateroute.xml?referer=qtlocationapi&token=152022572f0e44e07489c35cd46fa246&waypoint0=50.8211708069,19.0568447113&waypoint1=50.7222747803,19.0116100311&mode0=fastestNow;car&alternatives=0&linkattributes=sh,le&maneuverattributes=po,tt,le,di,li&routeattributes=sm,sh,bb,lg&legattributes=links,maneuvers&departure=2011-08-11T13:15:35Z&instructionformat=text&language=C

      Resulting error:
      <e:Error xmlns:e="http://www.navteq.com/lbsp/Errors/1" type="ApplicationError" subtype="InvalidInputData">
      <Details>
      Expected format: a single language subtag composed of 2 or 3 letters potentially followed by extended language subtag separated by hyphen and composed of 2 or 3 letters
      </Details>
      <AdditionalData key="language">C</AdditionalData>
      </e:Error>

      A simple workaround:
      if(m_routingManager->locale().language() == QLocale::C)
      m_routingManager->setLocale(QLocale(QLocale::English));

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            hagaj Hanna Gaj
            Reporter:
            kkrzewniak Krzysztof Krzewniak
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:

                Gerrit Reviews

                There are no open Gerrit changes