﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
3056	can't delete a way added to relation with no role	kaitu	team	"can't delete a way added to relation with no role

When I add a way to a relation, leaving the role field blank, and then try to delete that way, I get a 'Unexpected Exception error'. When I close the 'Unexpected Exception error' window, the way has not been deleted. 

After uploading the changes to server, I still get the same error.

If I start a new layer and download the data, then I can delete the way in the new layer. I still cannot delete the way in the same layer in which I added the way to the relation.

The error doesn't occur if, in the relation editor, I write something in the 'role' field of the way and apply the changes.

Possible workaround (while the bug gets fixed) when the role must intentionally remain blank: 
1)write some text in the role field
2)apply changes and close relation editor
3)now the way can be deleted

Here is a dump of josm diagnostic text:

Path: trunk
URL: http://josm.openstreetmap.de/svn/trunk
Repository Root: http://josm.openstreetmap.de/svn
Repository UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Revision: 1824
Node Kind: directory
Last Changed Author: ulfl
Last Changed Rev: 1824
Last Changed Date: 2009-07-24 03:14:11 +0200 (Fri, 24 Jul 2009)


Memory Usage: 43 MB / 508 MB (5 MB allocated, but free)
Java version: 1.6.0_13

Plugins: measurementutilspluginvalidatorwmsplugin
Plugin measurement Version: 16317
Plugin utilsplugin Version: 16628
Plugin validator Version: 16629
Plugin wmsplugin Version: 16599


java.lang.NullPointerException
	at org.openstreetmap.josm.command.DeleteCommand.testRelation(DeleteCommand.java:151)
	at org.openstreetmap.josm.command.DeleteCommand.delete(DeleteCommand.java:226)
	at org.openstreetmap.josm.actions.mapmode.DeleteAction.doActionPerformed(DeleteAction.java:83)
	at org.openstreetmap.josm.actions.DeleteAction.actionPerformed(DeleteAction.java:24)
	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.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)
"	defect	closed	major		Core		fixed	way delete role relation	
