maproulette3: Trying to create challenge fails without obvious reason (due to [out:json][timeout:3600] header)
problems tracked down in https://github.com/maproulette/maproulette3/issues/1892#issuecomment-1360286738 and https://github.com/maproulette/maproulette3/issues/1908
original report below
creating project works fine - https://maproulette.org/admin/project/50406
trying to create challenge fails with
Unable to save your changes{details}
Unable to retrieve latest challenge data from server.
I supplied
dead wikipedia tags in Germany
as name and
[out:xml][timeout:3600];
(
node(101409102)['wikipedia'='de:Roth (Lahn)'];
node(1018918855)['wikipedia'='de:Charlottenhof (Passow)'];
node(117178037)['wikipedia'='de:Brombach (Schmitten)'];
); out meta;
as an overpass query and
dead wikipedia tags in Germany
as description
About this issue
- Original URL
- State: open
- Created 2 years ago
- Comments: 17 (4 by maintainers)
That’s a good project idea… I took a quick look and the code’s parsing of overpass queries does not handle various orderings of the “Settings” statement. And the code adds additional settings when it thinks those are missing, so if the query is misinterpreted the other settings may be injected and essentially corrupts the query.
A few overpass Settings examples and how it influences the settings used in the query sent to overpass:
[out:json];works fine, and[timeout:X];works fine (although it is changed to[out:json][timeout:X];)[out:json][timeout:X]works fine[out:json];(space at the front) breaks, resulting in[out:json][timeout:Y]; [out:json];[out:json][timeout:X];(whitespace) is broken, resulting in[out:json][timeout:Y]; [out:json][timeout:X];[timeout:X][out:json];is technically broken with the result being[out:json][timeout:X][out:json];[out:xml];breaks, resulting in[out:json][timeout:Y];[out:xml];I created https://maproulette.org/browse/challenges/37135 with that query but leaving out the top statements:
So MapRoulette gets confused by those. We need to make that clearer. I opened a project to collect all the open tickets (and future ones) that have to do with improving the Overpass experience for challenge makers: https://github.com/orgs/maproulette/projects/1