Modify

Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#5334 closed defect (duplicate)

how to handle inconsistent data?

Reported by: malenki Owned by: team
Priority: blocker Milestone:
Component: Core Version:
Keywords: inconsistency Cc: malenki

Description

Today josm gave me some error which I could trace to come from inconsistent data.¹
Neither c&p (to a new layer) nor saving or uploading worked. No-one on IRC could tell me how to handle this error.
Josm's autosave created only empty files.

Marking all data in josm with mouse and running the validator worked fine. Running the validator with no data marked gave an exception.²

¹

[COMPLETE WITHOUT COORDINATES] {Node id=-83990 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-19037 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-137428 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-18822 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-18979 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-126518 version=0 V } is not incomplete but has null coordinates
Exception during dataset integrity test:
java.lang.NullPointerException
	at org.openstreetmap.josm.data.osm.DatasetConsistencyTest.searchNodes(DatasetConsistencyTest.java:82)
	at org.openstreetmap.josm.data.osm.DatasetConsistencyTest.runTest(DatasetConsistencyTest.java:143)
	at org.openstreetmap.josm.data.osm.DatasetConsistencyTest.runTests(DatasetConsistencyTest.java:157)
	at org.openstreetmap.josm.gui.layer.OsmDataLayer$ConsistencyTestAction.actionPerformed(OsmDataLayer.java:636)
	at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995)
	at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2318)
	at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)
	at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)
	at javax.swing.AbstractButton.doClick(AbstractButton.java:357)
	at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1223)
	at javax.swing.plaf.basic.BasicMenuItemUI$Handler.menuDragMouseReleased(BasicMenuItemUI.java:1327)
	at javax.swing.JMenuItem.fireMenuDragMouseReleased(JMenuItem.java:568)
	at javax.swing.JMenuItem.processMenuDragMouseEvent(JMenuItem.java:465)
	at javax.swing.JMenuItem.processMouseEvent(JMenuItem.java:411)
	at javax.swing.MenuSelectionManager.processMouseEvent(MenuSelectionManager.java:305)
	at javax.swing.plaf.basic.BasicPopupMenuUI$MouseGrabber.eventDispatched(BasicPopupMenuUI.java:807)
	at java.awt.Toolkit$SelectiveAWTEventListener.eventDispatched(Toolkit.java:2353)
	at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2245)
	at java.awt.Toolkit.notifyAWTEventListeners(Toolkit.java:2203)
	at java.awt.Component.dispatchEventImpl(Component.java:4528)
	at java.awt.Container.dispatchEventImpl(Container.java:2099)
	at java.awt.Component.dispatchEvent(Component.java:4460)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4577)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4238)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168)
	at java.awt.Container.dispatchEventImpl(Container.java:2085)
	at java.awt.Window.dispatchEventImpl(Window.java:2478)
	at java.awt.Component.dispatchEvent(Component.java:4460)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

2

Repository Root: http://josm.openstreetmap.de/svn
Build-Date: 2010-08-15 01:31:09
Last Changed Author: stoecker
Revision: 3438
Repository UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
URL: http://josm.openstreetmap.de/svn/trunk
Last Changed Date: 2010-08-15 00:34:57 +0200 (Sun, 15 Aug 2010)
Last Changed Rev: 3438

Identification: JOSM/1.5 (3438 de)
Memory Usage: 942 MB / 942 MB (107 MB allocated, but free)
Java version: 1.6.0_21, Sun Microsystems Inc., Java HotSpot(TM) Server VM
Operating system: Linux

Dataset consistency test:
[COMPLETE WITHOUT COORDINATES] {Node id=-83990 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-19037 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-137428 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-18822 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-18979 version=0 V } is not incomplete but has null coordinates
[COMPLETE WITHOUT COORDINATES] {Node id=-126518 version=0 V } is not incomplete but has null coordinates
Exception during dataset integrity test:
java.lang.NullPointerException
	at org.openstreetmap.josm.data.osm.DatasetConsistencyTest.searchNodes(DatasetConsistencyTest.java:82)
	at org.openstreetmap.josm.data.osm.DatasetConsistencyTest.runTest(DatasetConsistencyTest.java:143)
	at org.openstreetmap.josm.data.osm.DatasetConsistencyTest.runTests(DatasetConsistencyTest.java:157)
	at org.openstreetmap.josm.actions.ShowStatusReportAction.getReportHeader(ShowStatusReportAction.java:69)
	at org.openstreetmap.josm.tools.BugReportExceptionHandler.handleException(BugReportExceptionHandler.java:88)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable$2.run(PleaseWaitRunnable.java:108)
	at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)


Plugin: DirectUpload (22017)
Plugin: PicLayer (22549)
Plugin: fuzzer (15)
Plugin: lakewalker (21706)
Plugin: measurement (22547)
Plugin: multipoly (22171)
Plugin: openstreetbugs (22548)
Plugin: osmarender (21774)
Plugin: remotecontrol (22479)
Plugin: reverter (22533)
Plugin: slippymap (22550)
Plugin: tageditor (21026)
Plugin: terracer (22169)
Plugin: turnrestrictions (22477)
Plugin: undelete (22365)
Plugin: validator (22550)
Plugin: wmsplugin (22581)

java.lang.NullPointerException

Attachments (0)

Change History (8)

comment:1 by bastiK, 14 years ago

I don't really know how you can get your data back, sorry. Have you tried to c&p only small parts?

Something like this can always happen with josm-latest. It can be absolutely stable for some weeks, but then there are fundamental changes and errors like this are expected.

comment:2 by malenki, 14 years ago

Cc: malenki added

Copy does work, but on paste I get the exception. No difference if I try to paste to the same or a new layer.
Luckily I found ~/.josm/autosave/deleted_layer/tmp.osm_20100815_1223.osm which contained a lot of the edits.
Starting Josm normally it also asked me to restore data and started with the mentioned file although the Josm with the inconsistent dataset is still running. (If you want me to try some things you are welcome)

I still would like to know
how nodes without coordinates happen to be created and

how one can avoid that/recover the data.

in reply to:  2 ; comment:3 by bastiK, 14 years ago

Replying to malenki:

I still would like to know
how nodes without coordinates happen to be created and

If we knew, we would fix it.

how one can avoid that

Save often, use tested version

/recover the data.

It may be possible to improve to situation by saving the uncorrupted data to file and ignore the rest. But the energy is spend better by trying to prevent the error in the first place.

in reply to:  3 ; comment:4 by malenki, 14 years ago

Replying to bastiK:

Replying to malenki:

how one can avoid that

Save often,

I do. Saving a inconsistent datalayer results in a 0-byte-file.

use tested version

Mh. Who then are the people to test the new versions? ;)

/recover the data.

It may be possible to improve to situation by saving the uncorrupted data to file and ignore the rest.

As I said trying to save the inconsistent data results in an exception. The filed I repeatedly saved to has now a size of 0 byte. Maybe here one could start and tell josm not to save if the data is corrupt/inconsistent.

But the energy is spend better by trying to prevent the error in the first place.

Yeah. Since you say

how nodes without coordinates happen to be created and

If we knew, we would fix it.

this is quite funny :)
(how to avoid an error of whom one doesn't know how he happens)

in reply to:  4 ; comment:5 by bastiK, 14 years ago

Replying to malenki:

Replying to bastiK:

Replying to malenki:

how one can avoid that

Save often,

I do. Saving a inconsistent datalayer results in a 0-byte-file.

Ok, there should be some kind of warning...

use tested version

Mh. Who then are the people to test the new versions? ;)

/recover the data.

It may be possible to improve to situation by saving the uncorrupted data to file and ignore the rest.

As I said trying to save the inconsistent data results in an exception. The filed I repeatedly saved to has now a size of 0 byte. Maybe here one could start and tell josm not to save if the data is corrupt/inconsistent.

I mean JOSM should be able to save as much of the data as possible.

But the energy is spend better by trying to prevent the error in the first place.

Yeah. Since you say

how nodes without coordinates happen to be created and

If we knew, we would fix it.

this is quite funny :)
(how to avoid an error of whom one doesn't know how he happens)

Not so funny if you repeat that joke too often. ;)

in reply to:  5 comment:6 by malenki, 14 years ago

Replying to bastiK:

Replying to malenki:

Replying to bastiK:

Replying to malenki:

how one can avoid that

Save often,

I do. Saving a inconsistent datalayer results in a 0-byte-file.

Ok, there should be some kind of warning...

please with the possibility to cancel the saving

As I said trying to save the inconsistent data results in an exception. The filed I repeatedly saved to has now a size of 0 byte. Maybe here one could start and tell josm not to save if the data is corrupt/inconsistent.

I mean JOSM should be able to save as much of the data as possible.

If that would be possible...

But the energy is spend better by trying to prevent the error in the first place.

Yeah. Since you say

how nodes without coordinates happen to be created and

If we knew, we would fix it.

this is quite funny :)
(how to avoid an error of whom one doesn't know how he happens)

Not so funny if you repeat that joke too often. ;)

haha (scnr)
I am the one suffering, if so. :P

comment:7 by jttt, 14 years ago

Resolution: duplicate
Status: newclosed

comment:8 by anonymous, 14 years ago

Closed as duplicate of #5333.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.