Trouble with an OSM file

Posted by PortCal on 12 December 2017 in English (English)

@experienced users of OGF/JOSM

I know the new forum is opened and it's preferred messages are posted there, but I wouldn't know where to put this problem (the closest thing I found was 'Collaboration > Technical problems and solutions' which seems to be for the problems with OGF). So I thought I'd put it here in the User Diaries.

Today I was editing and detailing central Chorley, with a lot of new things I wanted to bring to the map. But when I tried to upload it as a changeset, it gave me the constant error that it could not upload the file due to certain problems with another relation. After a few tries I decided to save the file and restart JOSM. Then I tried to re-open the file I just saved, but now it won't even let me open it and gives me the error

"Relation with external id ''74.461'' refers to a missing primitive with external id ''74.455''

Both relations to places in the Ardisphere that I visited earlier today (which looks amazing btw) when looking at Mstr's Featured Objects page (which also is amazing) for inspiration for my rivers.

Now I'm stuck with this annoying error. I really want to upload this file so I can go back to mapping the rest of the town with the proper layout, instead of guessing where everything is.

Another strange thing I noticed was when I opened JOSM after many attempts and a few hours and dismissed the error, and went in the menu to the list of active changesets, I saw this changeset by me still unclosed, so I closed it, but it is empty, as can be seen.

I'm really distraught at the moment, I don't know what to do with it. I searched the web for help in documentations and forums, but neither of them were helpful to me. I don't want to lose such a large part of the progress I made today. Is there a way I can still upload this .osm file I have on my computer? Does anyone know how to solve this? 😪

Comment from eklas on 12 December 2017 at 09:59

I am really sorry to hear that, I understand it must be really frustrating, but honestly I'd just give up. In the time you'd waste trying to fix the problem, you can draw everything again and make sure the problem doesn't reoccur in the future.

Except for the occasional problems with unsynchronized data, in my two year history of using JOSM I've never ran into this problem. Try downloading the area again and doing some meaningless small changes and uploading them - does it still give you the error?

Also, how large was the area you downloaded? JOSM sometimes does weird stuff when it's processing a lot of data at once.

Hide this comment

Comment from Luciano on 12 December 2017 at 10:36

Long ago, I gave up saving .OSM files for more than a single online editing session. Every frustrating or annoying or mysterious problem I have had with JOSM has been due to trying to save and re-edit saved sessions and .OSM files.

Every time I want to upload a changeset, I start with a clean downloaded dataset. I download where I want to work, and save a .OSM file and I call this a working file. I do my editing and then I "throw it away" after I've uploaded the changeset (or changesets, for a longer/larger editing session).

I don't know if that is the cause of your problem, but I'm guessing.

As @eklas said, JOSM also behaves strangely when you have large datasets. Sometimes this is unavoidable, but for the most part I try to keep my datasets under 100000 objects.

It is very annoying when these things occur. In my first year with JOSM, I lost many hours of map work because of strange problems, because I kept trying to save and reopen the same .OSM files over multiple days. Even diligently trying to use the "Update" functions, it doesn't seem very reliable or complete. Conflicts and strange errors can occur. So I have found it's just easier to pretend JOSM can't "remember" between editing sessions - in essence, I use it as if it were online, even though it's offline.

So how is it possible to do brainstorming and long-term planning? Layers! Layers! Layers. I have as many as 10 layers in an active session. 9 of those are "never for upload" - they're essentially scratchpads where I work out ideas and brainstorm and keep various objects-in-progress (rivers, contours, streets, whatever). Then I have one layer which is my current "working file" which is a fresh downloaded snapshot of where I want to put my work. I do copy-pastes from my scratchpads to my working file, and upload that.

Hide this comment

Comment from PortCal on 12 December 2017 at 12:05

@eklas @Luciano yes, I tried to do a small edit yesterday (you can see the ugly street drawn here) but it will just ignore the previous changeset as if it never existed.

Normally I don't save .OSM files too, I directly download a small area from the map (this time, only the town of Chorley, nothing else), work on it and upload that in a few changesets. It always works very well and very stable. I never use that many large changesets. I always keep it under a 1000 objects at once. I even set up JOSM to spread it over multiple changesets when it reaches above 600 altered objects, as I too had problems with uploading in the past. But well, JOSM is just a weird program sometimes, and trying to find an answer in the documentation mess on the web can be quite hard and time-consuming.

Well that might be the best thing to do. I just found out that I can open the .OSM file in PotLatch 2 and see everything, but cannot upload any of it. But at least I have a reference to how I want it to look, maybe I can even make some adjustments. Thanks for replying anyway and for the advise!

Hide this comment

Comment from Ūdilugbulgidħū on 12 December 2017 at 17:50

Luciano is dead right on working on previously uploaded datasets, though I can't tell if this is the cause of your troubles. The workaround may be to copy & paste the stuff you mapped and couldn't upload to a new layer, then clean this layer up and upload it. You will lose all the relations, but the detail of what you've drawn will probably still be ok. If there are going to be conflicts (i.e. duplicates) you'll have to manually merge objects for the two areas and remove these (the validator will do most of this work for you, like removing isolated nodes or duplicate ways). That may be easier than redrawing everything.

Hide this comment

Leave a comment

Parsed with Markdown

  • Headings

    # Heading
    ## Subheading

  • Unordered list

    * First item
    * Second item

  • Ordered list

    1. First item
    2. Second item

  • Link

  • Image

    ![Alt text](URL)

Login to leave a comment