Opened 17 years ago
Closed 16 years ago
#1712 closed defect (fixed)
Incomplete ways are discarded without notice - untested for server loads
Reported by: | anonymous | Owned by: | framm |
---|---|---|---|
Priority: | minor | Milestone: | |
Component: | Core | Version: | latest |
Keywords: | Cc: |
Description
When a node of a way is missing in an .osm file JOSM discards the way silently without informing the user about that fact.
Attachments (0)
Change History (8)
comment:1 by , 16 years ago
Component: | unspecified → Core |
---|
comment:2 by , 16 years ago
comment:3 by , 16 years ago
src/org/openstreetmap/josm/io/OsmReader.java has a function called createWays(), which very clearly skips ways with missing nodes. The question is: what to do about it? And, how many other ways are there to break a .osm file's data coherency that JOSM is currently silently discarding? How was this problem discovered? Did somebody edit the .osm file themselves, or is there some software out there which writes out incoherent .osm files?
comment:4 by , 16 years ago
Previous comment was mine also. I've been thinking about what is the right thing to do, to recover the maximum information: when a way contains a node which is not in the file, create a node a little ways away from the previous node (or in the center of the view if it's the first node), and assign the node a special attribute like "Created_by=JOSM missing node". If any nodes had to be created, then the loader should pop up an error message saying "File incomplete; search for `missing node to find the re-created nodes."
comment:5 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Fixed. Sent a patch to the mailing list because it won't let me upload it as a file.
comment:6 by , 16 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Summary: | Incomplete ways are discarded without notice → Incomplete ways are discarded without notice - untested for server loads |
Patch to fix for file loading included. Must be tested for server downloads as well.
comment:7 by , 16 years ago
Status: | reopened → new |
---|
comment:8 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
For an incomplete primitive (node, way or relation) in JOSM only its type and its id should be known. An incomplete primitive is typically returned by the API for relation memembers.
Several API calls also return ways with incomplete nodes and JOSM now supports incomplete ways with incomplete nodes. trunk/src/org/openstreetmap/josm/io/OsmReader.java has been updated accordingly.
I've verified that this does indeed happen.