-
Notifications
You must be signed in to change notification settings - Fork 87
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
Page tree problems after translating including subtree #773
Comments
Hey @leewesleyv, |
Currently using the following versions:
Besides these versions I've tried with main (of |
Does running the |
@danthedeckie Running that command will indeed find and fix the problem (see 4th screenshot in #773 (comment)). |
By way of update: I was hoping to get to it last week, but I didn't get to it, sorry! |
I was able to replicate this. Working on a fix |
Naively wondering if we can effectively run |
Rummaging around, trying to pinpoint where the page tree goes awry. I slotted in a call to It appears not:
So now it's off to deeper in the stack, possibly in core wagtail(?) If anyone else knows where this is being caused, please do say 😄 |
Thank you for the investigation @stevejalim |
I've been having the exact same problem on a site that I'm developing, and I've successfully implemented the following, which solves it until it's fixed upstream (put this in
|
Thanks @urlsangel! |
I haven't, as I wasn't aware that signal existed 😅 I'll try that implementation when I get back on the project - it's still in development, so it would be good to respond to a signal like that rather than the Thanks for the tip! 🙏 |
@urlsangel Fingers crossed that it works - it might be sent slightly before the tree gets mangled (I don't know), but here's hoping it's a lighter-touch workaround, yeah! |
Just tried with the copy_for_translation_done signal, and no joy I'm afraid, so have reverted back to Shame, as |
Ah bad luck @urlsangel 😢 Thanks for letting me know, though! Maybe there's something in the built-in hooks that might be more focused. I think it'll depend on knowing when exactly the tree gets messed up. Maybe |
When translating a page through the Wagtail admin (localize/submit/page/<page_id>) and including the subtree, the (translated) page tree is corrupt. The
numchild
value for the translated page stays 0, which causes the subpages to not appear in the Wagtail admin. I've been able to reproduce this on multiple Wagtail instances.How to reproduce
On a fresh installation of Wagtail (using
wagtail start
), configure i18n using the Wagtail docs. Installwagtail-localize
following the installation guide. Then perform the following actions:The text was updated successfully, but these errors were encountered: