I had already checked a Fix and added sanity-checks for this into the SVN-version of Osmosis some weeks ago.
Marcus On Thu, 3 Dec 2009 09:14:06 +0000, 80n <80n...@gmail.com> wrote: > I've fixed this in XAPI. > > 80n > > On Thu, Dec 3, 2009 at 8:28 AM, Stephan Plepelits < > sk...@xover.htu.tuwien.ac.at> wrote: > >> Hi! >> >> I found a bug either in XAPI or Osmosis: >> >> If you download relations from XAPI, members of relations without a role, >> don't get an attribute 'role', which breaks Osmosis processing that file. >> Osmosis (0.31) gets a NullPointerException, if no role is defined. >> >> E.g. >> <relation id='1'> >> <member type='node' ref='1'> >> </relation >> >> Something like this works for Osmosis: >> <relation id='1'> >> <member type='node' ref='1' role=''> >> </relation >> >> For now I wrote a workaround via sed: >> sed "s/<member \(.*\) ref='\([0-9]*\)'/<member \1 ref='\2' role=''/" >> file.osm >> >> But I think, somebody should either fix Osmosis, so I works without >> roles, >> or fix XAPI, that it returns empty roles. >> >> greetings, >> Stephan >> -- >> Seid unbequem, seid Sand, nicht Öl im Getriebe der Welt! - Günther Eich >> ,---------------------------------------------------------------------. >> | Stephan Plepelits, | >> | Technische Universität Wien - Studien Informatik & Raumplanung | >> | > openstreetbrowser.org > couchsurfing.org > tubasis.at > bl.mud.at | >> | sk...@xover.htu.tuwien.ac.at - My Blog: http://plepe.at | >> `---------------------------------------------------------------------' >> >> _______________________________________________ >> dev mailing list >> dev@openstreetmap.org >> http://lists.openstreetmap.org/listinfo/dev >> _______________________________________________ dev mailing list dev@openstreetmap.org http://lists.openstreetmap.org/listinfo/dev