Modify

Opened 14 years ago

Closed 14 years ago

#6513 closed defect (fixed)

turnlanes plugin preventing splitting ways that don't have "lanes" tags

Reported by: rickmastfan67 Owned by: benshu
Priority: critical Milestone:
Component: Plugin turnlanes Version: latest
Keywords: Cc:

Description

Steps to reproduce:

  1. Download any way that doesn't have the "lanes=*" tag set. (example: way 11812680)
  2. Select ANY node in the way.
  3. Hit the "p" button to split the way.

Expected results: turnlanes plugin doesn't crash and the way should have been split into two separate ways.

What happens: turnlanes plugin crashes and deletes the newly split way that didn't keep the original way ID (but the nodes are still there).

Repository Root: http://josm.openstreetmap.de/svn
Build-Date: 2011-06-27 01:31:44
Last Changed Author: stoecker
Revision: 4177
Repository UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
URL: http://josm.openstreetmap.de/svn/trunk
Last Changed Date: 2011-06-26 17:45:48 +0200 (Sun, 26 Jun 2011)
Last Changed Rev: 4177

Identification: JOSM/1.5 (4177 en)
Memory Usage: 124 MB / 3640 MB (58 MB allocated, but free)
Java version: 1.6.0_26, Sun Microsystems Inc., Java HotSpot(TM) 64-Bit Server VM
Operating system: Windows 7
Dataset consistency test: No problems found

Plugin: ImproveWayAccuracy (26174)
Plugin: OpeningHoursEditor (26174)
Plugin: RoadSigns (26174)
Plugin: alignways (26174)
Plugin: buildings_tools (26174)
Plugin: imageryadjust (26174)
Plugin: mapdust (26174)
Plugin: measurement (26174)
Plugin: michigan_left (26174)
Plugin: openstreetbugs (26174)
Plugin: restart (26174)
Plugin: reverter (26174)
Plugin: turnlanes (26182)
Plugin: turnrestrictions (26174)
Plugin: undelete (26174)
Plugin: utilsplugin2 (26174)

org.openstreetmap.josm.plugins.turnlanes.model.UnexpectedDataException: The tag "lanes" is missing.
	at org.openstreetmap.josm.plugins.turnlanes.model.UnexpectedDataException$Kind.chuck(UnexpectedDataException.java:26)
	at org.openstreetmap.josm.plugins.turnlanes.model.Lane.getCount(Lane.java:80)
	at org.openstreetmap.josm.plugins.turnlanes.model.Lane.getRegularCount(Lane.java:84)
	at org.openstreetmap.josm.plugins.turnlanes.model.Lane.load(Lane.java:38)
	at org.openstreetmap.josm.plugins.turnlanes.model.Road$End.<init>(Road.java:55)
	at org.openstreetmap.josm.plugins.turnlanes.model.Road$End.<init>(Road.java:24)
	at org.openstreetmap.josm.plugins.turnlanes.model.Road.<init>(Road.java:339)
	at org.openstreetmap.josm.plugins.turnlanes.model.ModelContainer.<init>(ModelContainer.java:120)
	at org.openstreetmap.josm.plugins.turnlanes.model.ModelContainer.recalculate(ModelContainer.java:227)
	at org.openstreetmap.josm.plugins.turnlanes.gui.GuiContainer.recalculate(GuiContainer.java:170)
	at org.openstreetmap.josm.plugins.turnlanes.gui.JunctionPane.setState(JunctionPane.java:296)
	at org.openstreetmap.josm.plugins.turnlanes.gui.JunctionPane.refresh(JunctionPane.java:450)
	at org.openstreetmap.josm.plugins.turnlanes.gui.TurnLanesDialog$1.refresh(TurnLanesDialog.java:127)
	at org.openstreetmap.josm.plugins.turnlanes.gui.TurnLanesDialog$1.tagsChanged(TurnLanesDialog.java:91)
	at org.openstreetmap.josm.data.osm.event.TagsChangedEvent.fire(TagsChangedEvent.java:24)
	at org.openstreetmap.josm.data.osm.DataSet.fireEventToListeners(DataSet.java:942)
	at org.openstreetmap.josm.data.osm.DataSet.endUpdate(DataSet.java:921)
	at org.openstreetmap.josm.data.osm.OsmPrimitive.writeUnlock(OsmPrimitive.java:319)
	at org.openstreetmap.josm.data.osm.Way.cloneFrom(Way.java:264)
	at org.openstreetmap.josm.command.ChangeCommand.executeCommand(ChangeCommand.java:43)
	at org.openstreetmap.josm.command.SequenceCommand.executeCommand(SequenceCommand.java:53)
	at org.openstreetmap.josm.data.UndoRedoHandler.addNoRedraw(UndoRedoHandler.java:36)
	at org.openstreetmap.josm.data.UndoRedoHandler.add(UndoRedoHandler.java:58)
	at org.openstreetmap.josm.actions.SplitWayAction.actionPerformed(SplitWayAction.java:156)
	at javax.swing.SwingUtilities.notifyAction(Unknown Source)
	at javax.swing.JComponent.processKeyBinding(Unknown Source)
	at javax.swing.KeyboardManager.fireBinding(Unknown Source)
	at javax.swing.KeyboardManager.fireKeyboardAction(Unknown Source)
	at javax.swing.JComponent.processKeyBindingsForAllComponents(Unknown Source)
	at javax.swing.JComponent.processKeyBindings(Unknown Source)
	at javax.swing.JComponent.processKeyEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.KeyboardFocusManager.redispatchEvent(Unknown Source)
	at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(Unknown Source)
	at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(Unknown Source)
	at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(Unknown Source)
	at java.awt.DefaultKeyboardFocusManager.dispatchEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$000(Unknown Source)
	at java.awt.EventQueue$1.run(Unknown Source)
	at java.awt.EventQueue$1.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.AccessControlContext$1.doIntersectionPrivilege(Unknown Source)
	at java.security.AccessControlContext$1.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$2.run(Unknown Source)
	at java.awt.EventQueue$2.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.AccessControlContext$1.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.run(Unknown Source)

Attachments (0)

Change History (2)

comment:1 by benshu, 14 years ago

Status: newassigned

Yeah, the exception handling is in the wrong place. I'm going to have to refactor it if I don't want to do it in two places.

comment:2 by benshu, 14 years ago

Resolution: fixed
Status: assignedclosed

Fixed in [o26192].

Modify Ticket

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