[openstreetmap/openstreetmap-website] add bulk_upload (#1995)

mmd notifications at github.com
Mon Oct 15 15:43:28 UTC 2018


There's another issue with backwards compatibility: the current implementation assumes that every operations occurs from top to bottom. This way, you cannot reference objects which occur only later in the file. Although your implementation is not incorrect from a technical point of view, it allows for scenarios, which are forbidden in the current implementation. If we ever need to switch back to the current implementation, this will no longer be possible.

Here's an example:


```
<?xml version="1.0" encoding="UTF-8"?>
<osmChange version="0.6" generator="iD">
  <create>
    <node id="-1" lat="1" lon="2" changeset="1251"/>
    <way id="-1"  changeset="1251">
        <nd ref="-1"/>
        <nd ref="-2"/>
    </way>
    <node id="-2" lat="1" lon="2" changeset="1251"/>
    </create>
</osmChange>
```

Expected result:

HTTP 400 - Placeholder node not found for reference -2 in way -1

Actual result:

HTTP 200 OK

```
<?xml version="1.0" encoding="UTF-8"?>
<diffResult version="0.6" generator="OpenStreetMap server" copyright="OpenStreetMap and contributors" attribution="http://www.openstreetmap.org/copyright" license="http://opendatacommons.org/licenses/odbl/1-0/">
    <node old_id="-1" new_id="5003081852" new_version="1"/>
    <node old_id="-2" new_id="5003081853" new_version="1"/>
    <way old_id="-1" new_id="4000212054" new_version="1"/>
</diffResult>
```

Furthermore, due to the internal resorting of objects, the `diffResult` result message no longer shows the object in the exact same sequence as they occured in the `osmChange` message. I also consider this to be a breaking change which needs to be corrected.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/1995#issuecomment-429906614
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20181015/eb24be47/attachment.html>


More information about the rails-dev mailing list