-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[Tree][NestedSet] Invalid tree when multiple roots are inserted in one flush #2582
Comments
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Anything new on this one? Am I the only one experiencing this one? Is there something wrong with my setup? Or even with my assumption on how this should work? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Still an issue. I'd love to help fixing but I need some hint on where to start if possible. Any help is much appreciated. |
I have the same issue. It works correctly if you persist all root nodes first. $this->doctrine->persist($ou1);
$this->doctrine->persist($ou2);
$this->doctrine->persist($ou11);
$this->doctrine->persist($ou21);
$this->doctrine->flush(); Why does the order matter? I think this is a critical issue. It is not possible use cascade persist. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
I think this is still a valid issue. Perhaps somebody could have a look if possible. I'd try to provide a fix as well but I need some guidance to begin with. |
Using the following simple Tree
I create multiple roots in one
flush()
:Now there's a corrupt tree in the database:
If I split the two roots into two separate
flush()
s, the tree is valid:Did I miss something or is this indeed a bug?
Thanks a lot for your support and your great work! Much appreciated!
The text was updated successfully, but these errors were encountered: