Skip to content

Calling members(shallow=False) on a relation with nodes results in a 404 #81

@am0s

Description

@am0s

The problem occurs when it tries to fetch the node. It appends /full at the end of the URL which then fails.

The exception is:

Exception: ('The requested data could not be downloaded. HTTP Error 404: Not Found', <HTTPError 404: 'Not Found'>)

Reproducible case:

from OSMPythonTools import cachingStrategy
from OSMPythonTools.overpass import Overpass

overpass = Overpass()
overpass_query = """
rel(52.85140,-1.35540,53.06546,-0.98999)["type"="route"]["route"="tram"]->.routes;
.routes out body;
way(r.routes)["railway"="tram"]->.route_ways;
.route_ways out body;
"""
overpass_data = overpass.query(overpass_query)

osm_relations = overpass_data.relations()
for rel_el in osm_relations:
    rel_members = list(rel_el.members(shallow=False))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions