Hi,
Twice I've tried to convert to py2neo 2.x. Both times I ran into
this problem. The first time I had to revert the 2.0 changes and put
out the release anyway. This time I'm sticking with it until I get
past it somehow...
The symptom is that I get this result from a transaction:
BatchError:
Batch job 2 failed with NotFoundException
Node 34950 not found
I can assure you that the number 34950 does not appear anywhere in
my code (I put in lots of debug). The transaction consists of three
things:
Create a new node
Relate the newly created node to an old node (which has node id
35031).
Insert the newly-created node into a legacy index.
This all works with the 1.6 series of code.
Here's a little of the debug from the transaction:
====
Performing
batch.create(0:({dateofbirth:"unknown",domain:"global",
firstname:"Annika", lastname:"Hansen", nodetype:"Person",time_create_iso8601:"2015-08-17
17:23:50", time_create_ms:1439832230360})) - for new node
====
RELATIONSHIP(0 -[IS_A]-> (n35031
{domain:"metadata",name:"Person",nodetype:"CMAclass"}))
Here's the explanation of the debug output:
The 0 in "
batch.create(0:(..."
means that this newly-created node has index 0 in the transaction
(as it should).
The
"RELATIONSHIP(0 -[IS_A]-> (n35031 {..." means
that we created a relationship between a node 0 and a Py2neo Node
whose id is 35031.
The "
add_to_index_or_fail"
line means we called the legacy.add_to_index_or_fail function on
node 0, putting it into the Person legacy index with the values
"Hansen" and "Annika" as the index values.
This is all exactly the same code which worked before. I mainly
added "legacy." to a bunch of calls, changed a few imports and
added more debug when it didn't work.
This looks a bit like a bug in py2neo to me. Suggestions on how
to proceed?