Restoring lost information

So my colleague Mark Jaroski added the boundaries of Paris’ 19 arrondissements (districts) to OSM a while back. This is useful, accurate administrative information, and has the added benefit of letting us at Wikitravel Press easily crop the map data into single-arrondissment sections for printing.

But alas, now somebody has gone and deleted them.

  1. Is there any way to find out who did it and why?

  2. Is there any way to restore the data on the OSM side?

  3. If we have an XML dump of the data with the paths in question, is there any way to re-inject it into OSM?

Any tips would be appreciated.

  1. If you know the way id of the deleted boundary then you can lookup the history:
http://www.openstreetmap.org/api/0.5/way/<id>/history
  1. This would have to be done by one of the admins with direct database access. But option 3 is preferred.

  2. Well, if you give the ways an negative id using a text editor and open the file with JOSM then JOSM should be able to upload the ways as if they are new.

Thanks!

I’ve got the missing ways, but the thing is that I’d like to coordinate with whoever deleted them before uploading them again. People have the same ID on the forum as in the map, right?

thanks!

-mark

Apparently it was Skywave. They don’t seem to have actually been deleted, but rather set to visibility=“false”, and with all of the node data stripped out. Here’s an example:

http://www.openstreetmap.org/api/0.5/way/23383084/history

Now, I can see why somebody might want to do this. Having all-inclusive boundaries like this will cause any program which is rendering them all to effectively render each boundary twice. However it is useful to have these inclusive boundaries to work with.

If I could find a way to tag them which would prevent them from rendering in potlatch, and which would be acceptable then I would re-upload them.

-mark

Hmm, Skywave is a very experienced and active Dutch mapper. You should try to contact him using the messaging options on the ‘www’ site and try to find out why he ‘disabled’ the boundaries. Also, if you say that your boundaries are duplicates from already existing boundaries then why don’t you use those boundaries?

I didn’t use them because I needed something to completely enclose the area. Knitting the existing boundary fragments together isn’t something that’s easily accomplished in XSL, so if possible I’d like to keep the enclosing ones, but in a way which doesn’t annoy people who prefer the fragments.

I should also point out that the existing boundaries are horribly incomplete. Mine were complete.

Well, in that case just upload them again or set the visible tag to true again (don’t know how to though).

I believe that’s what happens when a way is deleted. Trying to access the way itself results in a http status of 410 Gone.
http://www.openstreetmap.org/api/0.5/way/23383084/ returns

Content-Type: text/html; charset=utf-8
Last-Modified: Sun, 06 Apr 2008 14:43:09 +0100
X-Runtime: 0.00236
Cache-Control: no-cache
Content-Length: 0
Date: Sun, 29 Jun 2008 19:35:39 GMT
Server: lighttpd/1.4.13

410 Gone

You should really ask the person who deleted it why they deleted, all the rest of us can really do is speculate as to why.

It could be a concern about the source of the data and if it can legally be added to OSM.

Duplicate data makes maintenance harder. All copies need to be kept in sync when changes are made.

Long ways can be a problem as when someone downloads the data for an area all the ways that have a node within that area and all the nodes these ways reference are downloaded. Long ways mean more data so the server takes longer to prepare the data, the data takes longer to download and the client software might get struggle under the load. As a result long ways tend to get split into smaller fragments.

Duplicate data will be merged/deleted, long ways will be split. Your tools need to deal with that if they want to use data from OSM directly.

Well, these weren’t that long, and had the advantage of being complete, where the existing ways are incomplete.

Go to Potlatch for the area in question. Press ‘U’ (undelete). This will show you deleted ways, in red. Select the one you want to undelete, and click the padlock to unlock it. Deselect and it’ll be saved.

Well, I’ve attempted to reach Skywave on the map site, and here. So far no luck.

Meanwhile I have been able to write some XSL which converts his boundaries into full outline boundaries.

Still, I’m not quite sure that this is semantically correct. I’ll have to give it some thought.

Yes when you delete something in Openstreetmap the only thing that happens is that the way will be marked as not visible, the same goes for the nodes. When node references and tags are removed and the object is saved under a new version.

I think I’ve figured out what the “right” way to do these borders would be: use relations. However, I can’t find a good example of the relations expressed as OSM XML, otherwise I would just do it.

Ha! I’ve found the interface in JOSM. It looks as though Skywave has in fact recreated these ways as relations. Mystery solved.

thanks all!

That sounde so wrong…