hotosm / tasking-manager

Tasking Manager - The tool to team up for mapping in OpenStreetMap
https://wiki.openstreetmap.org/wiki/Tasking_Manager
BSD 2-Clause "Simplified" License
504 stars 271 forks source link

Accept LineStrings to outline task area with Import #2285

Open bikeoid opened 4 years ago

bikeoid commented 4 years ago

When creating a task area from .OSM format, the recommended geojson.io converts a .OSM closed area to a LineString in GeoJson. This is rejected by tasking manager Import button "Error: The AOI contains geometries which are not polygons or multipolygons".

I would expect a closed .OSM area to be accepted by tasking manager.

BudgieInWA commented 2 years ago

The upload for definding the area of interest (AOI) is very picky; I wasn't able to get it to work for an admin boundary until I manually edited a .geojson file so that it had exactly one feature that was a polygon, and nothing else.

A good improvement would be to simply ignore non-polygon geometry in the file, so that a stray way or POI doesn't cause the whole process to fail. Stitching together LineStrings to create a closed polygon would be super cool too, but I'm more interested in being able to use a polygon that I have created, but without having to be so pedantic about the file.

The error messages when the file is not well formed are very cryptic and didn't really help me make progress towards creating a well formed file. Another way to improve the situation would be to document in that upload dialogue, what needs to be present in each file type for it to be accepted. As well as a quick recommendation for how to get from Overpass or JOSM or iD to a well formed file.