OpenStreetMap

So the current JOSM release allows you to load and save *.osn files. There is a daily notes dump available at http://planet.osm.org/notes/

But you can’t filter them to only display those that are open. I wanted to find a solution. First, I thought about writing Python or C# app. Turns out there is much simpler solution: XPath is a syntax for XML element selection. With xml_grep from xml-twig-tools package I can apply it to an XML file like this:

xml_grep –exclude /*/note[@closed_at] planet-notes-latest.osn > open_notes.osn

You can of course extend this expression to filter by geographic area or date.

Discussion

Comment from Baloo Uriza on 9 February 2015 at 17:47

Except you can do that in JOSM with osm.notes.daysClosed…

Comment from RicoElectrico on 5 July 2017 at 21:03

Just or the reference - daysClosed is only passed to OSM API, it isn’t used when loading notes from a file. So you can’t do this in JOSM.

Log in to leave a comment