NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum

Some relations can have thousands of revisions and the “View History” link times out. There is a full history dump but it is vastly greater than the history of a single element and takes too much time and space for a home computer or mobile device.

Is there a more efficient way to do this, maybe starting with the most recent revisions?

asked 08 Mar '16, 22:16

Wynndale's gravatar image

Wynndale
5651515
accept rate: 7%


You might find osm.mapki.com useful - see for example with this relation. If necessary you can also get individual versions from the API:

wget https://openstreetmap.org/api/0.6/relation/1820890/83
permanent link

answered 08 Mar '16, 22:21

SomeoneElse's gravatar image

SomeoneElse ♦
36.9k71370866
accept rate: 16%

edited 08 Mar '16, 22:24

Also, for objects with ultra long history, I recommend just deleting and re-creating them under a new ID, with an additional tag "note=original object ID was ..." or so. Makes life easier for those that come after you!

(08 Mar '16, 22:31) Frederik Ramm ♦

One option is to use josm to view the history. Download the location or just the object (file -> download from osm or file -> download object), select the object, and view its history (Ctrl-H or view -> history).

In my experience it's much faster than mapki or even osmhv, taking 20s to show this test relation's history when the other two timed out on me.

permanent link

answered 09 Mar '16, 10:15

Vincent%20de%20Phily's gravatar image

Vincent de P... ♦
17.3k18152249
accept rate: 19%

Finding those relation versions from the full history dump on your home computer probably doesn't take as much time as you think. With the osmium command line tool you can easily pick out all the versions of a particular object. For instance reading all versions of the relation id 1820890 took only about 7 minutes on my notebook:

osmium getid history.osm.pbf r1820890 -o /tmp/r1820890-hist.osm.xml

Downloading the full history dump will probably take longer. :-) Make sure to use the PBF version of the history and not the XML version, because parsing it is much faster.

permanent link

answered 09 Mar '16, 09:55

Jochen%20Topf's gravatar image

Jochen Topf
5.2k55074
accept rate: 31%

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×236
×89
×8

question asked: 08 Mar '16, 22:16

question was seen: 2,870 times

last updated: 09 Mar '16, 10:15

NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum