Open KristjanESPERANTO opened 1 year ago
This isn't necessarily a relation issue. It is an issue with adding multiple geometries to a single task.
Try this for your geometry: "geometry": {"type": "GeometryCollection", "geometries": [{"type": "LineString", "coordinates": [[-58.7810037, -27.5199102], [-58.7809956, -27.5199463], [-58.7812341, -27.5203813], [-58.7812558, -27.5204126], [-58.7813054, -27.5204831], [-58.7816364, -27.5211127]]}, {"type": "Point", "coordinates": [-58.78144588, -27.5207503]}, {"type": "LineString", "coordinates": [[-58.7802055, -27.5187263], [-58.7822493, -27.5220613]]}]}
Here is a full line: {"type": "FeatureCollection", "features": [{"type": "Feature", "properties": {"highway": "residential", "identifier": "w1088492002@2", "osmIdentifier": "way/1088492002", "instructions": "Way 1088492002 intersects with 1055973572 at POINT (-58.78144587552386 -27.520750300573482) without a shared node."}, "geometry": {"type": "GeometryCollection", "geometries": [{"type": "LineString", "coordinates": [[-58.7810037, -27.5199102], [-58.7809956, -27.5199463], [-58.7812341, -27.5203813], [-58.7812558, -27.5204126], [-58.7813054, -27.5204831], [-58.7816364, -27.5211127]]}, {"type": "Point", "coordinates": [-58.78144588, -27.5207503]}, {"type": "LineString", "coordinates": [[-58.7802055, -27.5187263], [-58.7822493, -27.5220613]]}]}}]}
I don't have the time to adapt it to my use case at the moment. But it looks promising. Thanks!
I think it would be nice if we improve the documentation on this: https://learn.maproulette.org/documentation/line-by-line-geojson/
I can now successfully create challenges via line-by-line GeoJSON file with nodes and ways. But I can't figure out how to handle relations.
I treat nodes as a point:
I treat ways as a LineString:
I tried to import relations as
GeometryCollections
,MultiLineStrings
and also asLineString
, but it didn't work.What am I missing?