-
Notifications
You must be signed in to change notification settings - Fork 26
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
Why do we detach the table children from the toplevel family? #524
Comments
/cc @sliverc |
Related: #212 (comment) |
From what I gathered until now, table rows should always have the same family ID as the root document (in fact, table questions were the reason document families were introduced in the first place). The fact that table rows can have different family IDs seems to be a bug. Concerning the question "Why do we detach in the first place?" - Could it be that this is a security measure in case the root document reference is changed in |
OK with some more analysis, I think I know why this is done: The detaching happens so the code is correct in any update case, even when the containing document changes. So the behaviour is this:
So my original note is wrong, even if the code looks like it. @sliverc please confirm if my assumption is correct. In any case, I think it may be worth it to only do the detach-reatach circus if actually needed, just to improve performance a bit. Especially since we won't be able to do bulk updates anymore when #522 lands |
@winged I think @anehx and I designed this together and he might have some more feedback on it. If it causes problems this can be rethought though. |
👍 That's also how we ended up implementing it - thanks for the affirmation 🙂 |
@open-dynaMIX Can this be closed or is there still something unclear? |
Out of context for this PR, but why do we detach the table children from the toplevel family? This doesn't make any sense IMHO, and puts rocks in our path when fetching the document for validation etc
Originally posted by @winged in #505
The text was updated successfully, but these errors were encountered: