Modify

Opened 7 years ago

Closed 17 months ago

Last modified 17 months ago

#13981 closed defect (irreproducible)

IllegalStateException: "Missing merge target of type node" reverting a changeset with deleted objects

Reported by: skyper Owned by: Upliner
Priority: critical Milestone:
Component: Plugin reverter Version:
Keywords: template_report regression Cc: BeKri, osm@…

Description (last modified by skyper)

What steps will reproduce the problem?

  1. revert changset 43556601 into empty layer
  2. answer "yes" to previous download other objects

What is the expected result?

changeset is reverted and deleted objects are undeleted

What happens instead?

IllegalStateException

Please provide any additional information below. Attach a screenshot if possible.

Problem seem to be deleted objects

URL:http://josm.openstreetmap.de/svn/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2016-11-14 23:32:57 +0100 (Mon, 14 Nov 2016)
Build-Date:2016-11-15 03:13:32
Revision:11256
Relative:URL: ^/trunk

Identification: JOSM/1.5 (11256 en) Linux Debian GNU/Linux 8.6 (jessie)
Memory Usage: 374 MB / 882 MB (83 MB allocated, but free)
Java version: 1.8.0_102-8u102-b14.1-1~bpo8+1-b14, Oracle Corporation, OpenJDK 64-Bit Server VM
Java package: openjdk-8-jre:amd64-8u102-b14.1-1~bpo8+1
Java ATK Wrapper package: libatk-wrapper-java:all-0.30.4-3
Program arguments: [--language=en]
Dataset consistency test: No problems found

Plugins:
+ reverter (32796)
+ tag2link (33035)
+ undelete (32699)
+ utilsplugin2 (32815)
+ wikipedia (33017)

Tagging presets:
+ https://josm.openstreetmap.de/josmfile?page=Presets/LaneAttributes&zip=1
+ http://osmtools.de/josm/steps.xml

Map paint styles:
+ https://josm.openstreetmap.de/josmfile?page=Styles/Lane_and_Road_Attributes&zip=1

Last errors/warnings:
- E: Handled by bug report queue: java.lang.IllegalStateException: Missing merge target of type node with id 575,881,486


=== REPORTED CRASH DATA ===
BugReportExceptionHandler#handleException:
No data collected.

Warning issued by: BugReportExceptionHandler#handleException

=== STACK TRACE ===
Thread: AWT-EventQueue-0 (18) of main
java.lang.IllegalStateException: Missing merge target of type node with id 575,881,486
	at reverter.DataSetCommandMerger.getMergeTarget(DataSetCommandMerger.java:61)
	at reverter.DataSetCommandMerger.mergeNode(DataSetCommandMerger.java:81)
	at reverter.DataSetCommandMerger.merge(DataSetCommandMerger.java:172)
	at reverter.DataSetCommandMerger.<init>(DataSetCommandMerger.java:45)
	at reverter.ChangesetReverter.getCommands(ChangesetReverter.java:344)
	at reverter.RevertChangesetTask.realRun(RevertChangesetTask.java:110)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:93)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:141)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)

Attachments (1)

13981-popup.PNG (23.0 KB ) - added by GerdP 4 years ago.

Download all attachments as: .zip

Change History (29)

comment:1 by skyper, 7 years ago

Description: modified (diff)
Summary: IllegalStateException reverting a changesetIllegalStateException reverting a changeset with deleted objects

comment:2 by skyper, 7 years ago

Similar to #11136

comment:3 by mdk, 7 years ago

#12809, #12829, #13981, #13986 and #13987 are failing with same callstack.

comment:4 by skyper, 7 years ago

Ticket #13986 has been marked as a duplicate of this ticket.

in reply to:  3 comment:5 by skyper, 7 years ago

Replying to mdk:

#12809, #12829, #13981, #13986 and #13987 are failing with same callstack.

comment:6 by skyper, 7 years ago

Cc: BeKri added

comment:7 by Klumbumbus, 7 years ago

Ticket #14020 has been marked as a duplicate of this ticket.

comment:8 by Klumbumbus, 7 years ago

Cc: osm@… added

comment:9 by skyper, 7 years ago

At least for deleted ways and nodes, a workaround is to priorly undelete these objects with the plugin "undelete" before reverting the changeset.

comment:10 by skyper, 7 years ago

Priority: normalmajor

comment:11 by Don-vip, 7 years ago

Ticket #14515 has been marked as a duplicate of this ticket.

comment:12 by Don-vip, 7 years ago

Ticket #14519 has been marked as a duplicate of this ticket.

comment:13 by Don-vip, 7 years ago

Ticket #14822 has been marked as a duplicate of this ticket.

comment:14 by Don-vip, 7 years ago

Ticket #15014 has been marked as a duplicate of this ticket.

comment:15 by Don-vip, 7 years ago

Priority: majorcritical

comment:16 by Don-vip, 6 years ago

Ticket #16383 has been marked as a duplicate of this ticket.

comment:17 by ris, 6 years ago

Yup, got this myself:

URL:https://josm.openstreetmap.de/svn/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2018-07-09 01:47:59 +0200 (Mon, 09 Jul 2018)
Build-Date:2018-07-08 23:50:14
Revision:14026
Relative:URL: ^/trunk

Identification: JOSM/1.5 (14026 en_GB) Linux Debian GNU/Linux 9.4 (stretch)
Memory Usage: 724 MB / 1646 MB (204 MB allocated, but free)
Java version: 1.8.0_171-8u171-b11-1~deb9u1-b11, Oracle Corporation, OpenJDK 64-Bit Server VM
Screen: :0.0 1680x1050
Maximum Screen Size: 1680x1050
Java package: openjdk-8-jre:amd64-8u171-b11-1~deb9u1
Java ATK Wrapper package: libatk-wrapper-java:all-0.33.3-13+deb9u1
Dataset consistency test: No problems found

Plugins:
+ Mapillary (v1.5.14+post13733)
+ apache-commons (34389)
+ apache-http (34389)
+ buildings_tools (34212)
+ markseen (7)
+ reverter (34271)
+ turnlanes (34288)

Tagging presets:
+ http://josm.openstreetmap.de/josmfile?page=Presets/Communication_Towers&zip=1
+ http://josm.openstreetmap.de/josmfile?page=Presets/BicycleJunction&preset
+ http://josm.openstreetmap.de/josmfile?page=Presets/BuildingPreset&preset

Map paint styles:
- https://josm.openstreetmap.de/josmfile?page=Styles/Lane_and_Road_Attributes&zip=1

Last errors/warnings:
- E: java.util.concurrent.ExecutionException: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401. Cause: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401
- E: java.util.concurrent.ExecutionException: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401. Cause: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401
- E: java.util.concurrent.ExecutionException: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401. Cause: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401
- E: java.util.concurrent.ExecutionException: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401. Cause: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401
- E: java.util.concurrent.ExecutionException: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401. Cause: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401
- E: java.util.concurrent.ExecutionException: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401. Cause: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401
- E: java.util.concurrent.ExecutionException: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401. Cause: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401
- E: java.util.concurrent.ExecutionException: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401. Cause: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401
- E: java.util.concurrent.ExecutionException: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401. Cause: org.openstreetmap.josm.io.OsmApiException: ResponseCode=401
- E: Handled by bug report queue: java.lang.IllegalStateException: Missing merge target of type node with id 2,919,211,048

OSM API: http://www.openstreetmap.org/api


=== REPORTED CRASH DATA ===
BugReportExceptionHandler#handleException:
No data collected.

Warning issued by: BugReportExceptionHandler#handleException

=== STACK TRACE ===
Thread: AWT-EventQueue-1 (18) of main
java.lang.IllegalStateException: Missing merge target of type node with id 2,919,211,048
	at reverter.DataSetCommandMerger.getMergeTarget(DataSetCommandMerger.java:62)
	at reverter.DataSetCommandMerger.mergeNode(DataSetCommandMerger.java:82)
	at reverter.DataSetCommandMerger.merge(DataSetCommandMerger.java:173)
	at reverter.DataSetCommandMerger.<init>(DataSetCommandMerger.java:46)
	at reverter.ChangesetReverter.getCommands(ChangesetReverter.java:346)
	at reverter.RevertChangesetTask.revertChangeset(RevertChangesetTask.java:159)
	at reverter.RevertChangesetTask.realRun(RevertChangesetTask.java:95)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:95)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:143)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

comment:18 by ris, 6 years ago

Well here's an interesting data point: turns out I got the previous error because I had josm misconfigured to point an the old non-https api endpoint. Could this be caused by a mishandles network error?

comment:19 by Don-vip, 5 years ago

Ticket #17355 has been marked as a duplicate of this ticket.

comment:20 by Don-vip, 5 years ago

Ticket #15442 has been marked as a duplicate of this ticket.

comment:21 by Don-vip, 5 years ago

Summary: IllegalStateException reverting a changeset with deleted objectsIllegalStateException: "Missing merge target of type node" reverting a changeset with deleted objects

comment:22 by skyper, 5 years ago

Ticket #17993 has been marked as a duplicate of this ticket.

comment:23 by Don-vip, 4 years ago

Ticket #18304 has been marked as a duplicate of this ticket.

comment:24 by GerdP, 4 years ago

See #15626. Would be good to know if all the above duplicates were produced with overpass api enabled.
Maybe we can add this information to the status report?

by GerdP, 4 years ago

Attachment: 13981-popup.PNG added

comment:25 by GerdP, 4 years ago

I can sometimes reproduce this problem with current versions of JOSM and plugin. It seems that this depends on the order in which tasks are executed. Steps are from #12360:
1) Download way w233056719 to a new layer
2) Revert cs 36536612 with "Revert selection and restore deleted objects"
3) If the popup "This changeset has objects that are not present in current dataset. It is needed to download them before reverting. Do you want to continue?" pops up early the error will show up.

If it is shown after some seconds like this the program continues:

comment:26 by GerdP, 4 years ago

No, sorry, I get a different stacktrace with these steps, mine is like the one in #11136.

comment:27 by skyper, 17 months ago

Resolution: irreproducible
Status: newclosed

Cannot reproduce with reverter (36011) but #22520.

comment:28 by skyper, 17 months ago

Damn, the former deleted node was undeleted, therefore the example does not work anymore. E.g. I cannot tell if this problem was fixed or if simple the example does not lead to an exception caused by changes in data. Any tip how to preserve an example in the future?

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Upliner.
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.