[OSM-dev] why does api not return nodes that are referenced from ways?

Timo Lindfors timo.lindfors at iki.fi
Tue Feb 5 23:08:31 GMT 2008


while trying to use pyroute I noticed it died with

Handling event route:clicked
Traceback (most recent call last):
  File "gui.py", line 349, in <lambda>
    event_box.connect("button_release_event", lambda w,e: self.released(e))
  File "gui.py", line 390, in released
    self.mapWidget.click(event.x, event.y)
  File "gui.py", line 196, in click
  File "/home/lindi/tmp/pyroute/overlay.py", line 39, in handleClick
  File "/home/lindi/tmp/pyroute/overlayArea.py", line 154, in handleClick
  File "/home/lindi/tmp/pyroute/events.py", line 142, in handleEvent
  File "/home/lindi/tmp/pyroute/events.py", line 93, in handle_route
    router.setStartLL(ownpos['lat'], ownpos['lon'], transport)
  File "/home/lindi/tmp/pyroute/routeOrDirect.py", line 17, in setStartLL
    self.route['startnode'] = self.data.findNode(lat,lon,transport)
  File "/home/lindi/tmp/pyroute/loadOsm.py", line 253, in findNode
    n = self.nodes[id]
KeyError: 94153236

It seems that 


contains a way

  <way id='10660210' timestamp='2007-10-31T21:45:41Z'>^M
    <nd ref='20576167'/>^M
    <nd ref='20576168'/>^M
    <nd ref='20576169'/>^M
    <nd ref='20576171'/>^M
    <nd ref='20576172'/>^M
    <nd ref='20576173'/>^M
    <nd ref='20576174'/>^M
    <nd ref='94155556'/>^M
    <nd ref='20576175'/>^M
    <nd ref='20576199'/>^M
    <nd ref='20576212'/>^M
    <nd ref='20576213'/>^M
    <nd ref='20576215'/>^M
    <nd ref='94159182'/>^M
    <nd ref='20576216'/>^M
    <nd ref='20576218'/>^M
    <nd ref='20576219'/>^M
    <nd ref='20576220'/>^M
    <nd ref='20576221'/>^M
    <nd ref='20576224'/>^M
    <nd ref='20576225'/>^M
    <nd ref='20576226'/>^M
    <nd ref='20576227'/>^M
    <nd ref='20576229'/>^M
    <nd ref='20576231'/>^M
    <nd ref='20576232'/>^M
    <nd ref='20576234'/>^M
    <nd ref='20576235'/>^M
    <nd ref='20576236'/>^M
    <nd ref='20576238'/>^M
    <nd ref='20576239'/>^M
    <nd ref='20576241'/>^M
    <nd ref='20576242'/>^M
    <nd ref='20576243'/>^M
    <nd ref='20576246'/>^M
    <nd ref='94153261'/>^M
    <nd ref='94153262'/>^M
    <nd ref='94153263'/>^M
    <nd ref='94153236'/>^M
    <nd ref='94154318'/>^M
    <nd ref='94154319'/>^M
    <nd ref='94154321'/>^M
    <tag k='highway' v='tertiary'/>^M
    <tag k='name' v='Fairchildes Road'/>^M

that references node 94153236 but that node is not defined in the
reply. The specification at


howevery says that it'd return

"any nodes outside the bounding box that the ways may reference."

Is osmxapi.hypercube.telascience.org breaking the specification or am
I (or pyroute) doing something wrong?

best regards,
Timo Lindfors

More information about the dev mailing list