-
Notifications
You must be signed in to change notification settings - Fork 61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unset nodeIdentifier on Delete #158
Unset nodeIdentifier on Delete #158
Conversation
seems sane. could you maybe add a test to phpcr-api-tests that demonstrates the bug? by "recreate" you mean create it at the same path? |
Yeah, I meant recreating at the same path. In this case I was recreating some example nodes, so deleted them before creating them again. Busy with the test right now. |
It seems I forgot to add the referenceable mixin... |
yeah trying to create a reference on a node without that mixin is not allowed and should trigger an error immediately. surprised it does not already. if you have the mixin, all works as expected? |
Yes, then it works like expected. I'll try to look at the error this |
@wjzijderveld any chance you manage to fix this in the next couple of days so we can have it in 1.1.0? |
I'll try, I had a vacation the last 10 days so I'm spending most of my |
Added the test to phpcr-api-tests and rebased on master. |
IMO this PR can be merged as soon as phpcr/phpcr-api-tests#122 is merged. |
i merged the test and retriggered the build, lets see. |
thanks! |
I am not completely sure this is an actual bug and if so, if this is the correct fix. But it works for me ;-)
The bug I ran into can be reproduced like this:
$session->save()
$session->save()
You will now get an
PHPCR\ReferentialIntegrityException
, stating that the reference you gave the does not exist.That failed because Client.php holds an internal list of UUID's and found the UUID for the deleted Node there.