Modify

Opened 10 days ago

Closed 10 days ago

Last modified 10 days ago

#19598 closed defect (fixed)

DataIntegrityProblemException: Primitive cannot be modified in read-only dataset

Reported by: GerdP Owned by: team
Priority: major Milestone: 20.07
Component: Core Version:
Keywords: template_report regression Cc:

Description (last modified by GerdP)

What steps will reproduce the problem?

  1. Load attached locked file
  2. run validator

What is the expected result?

no crash

What happens instead?

bug report

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

regression from r16784, see #19180

Build-Date:2020-07-30 11:59:55
Revision:16809
Is-Local-Build:true

Identification: JOSM/1.5 (16809 SVN en) Windows 10 64-Bit
OS Build number: Windows 10 Home 1903 (18362)
Memory Usage: 671 MB / 1753 MB (443 MB allocated, but free)
Java version: 1.8.0_191-b12, Oracle Corporation, Java HotSpot(TM) 64-Bit Server VM
Look and Feel: com.sun.java.swing.plaf.windows.WindowsLookAndFeel
Screen: \Display0 1920x1080 (scaling 1.0x1.0)
Maximum Screen Size: 1920x1080
Best cursor sizes: 16x16 -> 32x32, 32x32 -> 32x32
VM arguments: [-agentlib:jdwp=transport=dt_socket,suspend=y,address=localhost:56613, -ea, -Dfile.encoding=UTF-8]
Program arguments: [--debug]
Dataset consistency test: No problems found

Plugins:
+ OpeningHoursEditor (35414)
+ PolygonCutOut (v0.7)
+ apache-commons (35362)
+ buildings_tools (35500)
+ continuosDownload (91)
+ ejml (35313)
+ geotools (35169)
+ jaxb (35092)
+ jts (35122)
+ merge-overlap (35248)
+ o5m (35248)
+ opendata (35513)
+ pbf (35446)
+ poly (35248)
+ reverter (35499)
+ undelete (35499)
+ utilsplugin2 (35487)

Last errors/warnings:
- E: java.lang.IllegalArgumentException: Parameter 'data' must not be null
- E: Handled by bug report queue: org.openstreetmap.josm.data.osm.DataIntegrityProblemException: Primitive cannot be modified in read-only dataset: {Node id=-107737 version=0 MVT lat=44.52595620359,lon=-80.25662705987}


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

Warning issued by: BugReportExceptionHandler#handleException

=== STACK TRACE ===
Thread: AWT-EventQueue-0 (21) of main
org.openstreetmap.josm.data.osm.DataIntegrityProblemException: Primitive cannot be modified in read-only dataset: {Node id=-107737 version=0 MVT lat=44.52595620359,lon=-80.25662705987}
	at org.openstreetmap.josm.data.osm.OsmPrimitive.checkDatasetNotReadOnly(OsmPrimitive.java:208)
	at org.openstreetmap.josm.data.osm.OsmPrimitive.put(OsmPrimitive.java:644)
	at org.openstreetmap.josm.data.validation.tests.TagChecker.filterDeprecatedTags(TagChecker.java:979)
	at org.openstreetmap.josm.data.validation.tests.TagChecker.tryGuess(TagChecker.java:924)
	at org.openstreetmap.josm.data.validation.tests.TagChecker.checkSingleTagComplex(TagChecker.java:841)
	at org.openstreetmap.josm.data.validation.tests.TagChecker.check(TagChecker.java:623)
	at org.openstreetmap.josm.data.validation.Test$TagTest.visit(Test.java:129)
	at org.openstreetmap.josm.data.osm.Node.accept(Node.java:210)
	at org.openstreetmap.josm.data.validation.Test.visit(Test.java:216)
	at org.openstreetmap.josm.data.validation.tests.TagChecker.visit(TagChecker.java:1053)
	at org.openstreetmap.josm.actions.ValidateAction$ValidationTask.realRun(ValidateAction.java:169)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:94)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:142)
	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)

Attachments (1)

19598.osm (242 bytes) - added by GerdP 10 days ago.
locked file with node tagged highway=fard

Download all attachments as: .zip

Change History (6)

Changed 10 days ago by GerdP

Attachment: 19598.osm added

locked file with node tagged highway=fard

comment:1 Changed 10 days ago by GerdP

Keywords: regression added

comment:2 Changed 10 days ago by GerdP

Resolution: fixed
Status: newclosed

In 16812/josm:

fix #19598: DataIntegrityProblemException: Primitive cannot be modified in read-only dataset

  • avoids to modify the original object as this requires a writeLock and probably causes trouble with locked files
  • avoids to call the rather complex filterDeprecatedTags() method by checking LEVENSHTEIN_DISTANCE first

comment:3 in reply to:  description Changed 10 days ago by Klumbumbus

Replying to GerdP:

regression from r16787

What exactly? Or did you mean r16784?

comment:4 Changed 10 days ago by GerdP

Description: modified (diff)

comment:5 Changed 10 days ago by GerdP

Yes, I've corrected the typo.

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.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.