[Neo] bug in Node.delete() ?
ml001 at armbruster-it.de
Tue Feb 9 21:28:45 CET 2010
it looks like Node.delete() does not behave as defined in the API docs:
Deletes this node if it has no relationships attached to it. If delete()
is invoked on a node with relationships, an unchecked exception will be
raised. Invoking any methods on this node after delete() has returned is
invalid and will lead to unspecified behavior.
I've created some sample code (http://pastebin.com/f2918f9d5)
demonstrating this. Line 25 tries to delete a node with a relationship
attached to it. There's no exception (as expected from the API docs) and
the node is still there afterwards. So delete() seems to do simply
nothing if there are any realtionships.
Did I miss something or should we consider this a bug?
More information about the User