Ensure published querying parity between V13 and V17#22622
Conversation
|
Claude finished @kjac's task in 4m 55s —— View job PR ReviewTarget: Fixes culture-specific ancestor path filtering in
Critical
Important
Request ChangesThe missing default implementation on The behavior fix itself (culture-specific ancestor path checking, |
AndyButland
left a comment
There was a problem hiding this comment.
Code-wise looks good @kjac, and a very smart way to handle avoiding breaking changes. I'll give it a test out later this morning, but first just sharing feedback on the code.
|
Here's what I found in testing @kjac - please look carefully to make sure it aligns with what you expect. With a structure of parent, child, grandchild, with each document in two languages, I've verified that:
|
This is certainly not expected, nor is it what I saw when testing. The unpublished child should show in preview mode. I will re-test. |
|
So... this is what I see. Yes, I spiced up the template with fancy links 😛 publish-parity.webm |
|
Found it - it's resolved in #22662 - which then becomes a prerequisite for this PR. I will flip this PR to draft for now. |
|
Claude finished @kjac's task in 4m 0s —— View job PR ReviewTarget: Restores culture-specific ancestor path filtering in
Important
Suggestions
Approved with SuggestionsThe core logic is sound and well-tested. The |
|
#22662 is merged. I have verified it fixes what you're seeing, @AndyButland ... ready for re-testing when you have time 👍 |
AndyButland
left a comment
There was a problem hiding this comment.
Looks good to me now @kjac. I've verified the preview issue we were discussing earlier and now see the expected result.


Prerequisites
Description
I have noticed a few differences between V13 and V17 when querying published content in a culture variant context.
This PR ensures the two versions align in behavior.
Consider this structure:
All content is published in English and Danish, except "Child 2", which is only in published in Danish.
The rendered output differs between V13 and V17 in the English language. Since all content is published in Danish, the renderings are the same for Danish between V13 and V17.
The template used for testing can be found in the bottom of this PR.
Root, English
"Grandchild 2" is rendered in V17, despite its parent being unpublished in English.
Root, English, in preview node
In V13, "Child 2" and "Grandchild 2" are rendered as expected when viewing the root in preview. In V17, "Grandchild 2" continues to be rendered without its parent.
Grandchild 2, English, requested by ID/key
While it might seem unexpected, both V13 and V17 allows for rendering published content, even if an ancestor is unpublished, as long as it is permitted to resolve content by ID/key. This could potentially qualify as a bug, but that's for another PR.
The empty bullets in the V13 rendering represent "Child 2" in English. Since it's not published, it won't render out a name, but all the same it appears both in the ancestors collection, and as the parent of "Grandchild 2".
Grandchild 2, English, in preview
As expected, V13 renders out the name of "Child 2" in preview. V17, however, continues to disregard "Child 2" entirely.
Introducing obsolete code
This PR introduces the
Unfiltered()method onIPublishedStatusFilteringServiceto avoid breaking the signature of a whole lot of published content extensions. This is a temporary means to an end, and the method has been marked as obsolete.I will create a follow-up task to remove
Unfiltered()for V19 (or later) if it is merged in. This does require a bit of planning, as it will break certain published content extensions.Testing this PR
Use the provided test template (or something similar) to test various permutations of culture variance and published structure querying. The scenarios above can be used as inspiration.
Test template
Here's the template I have used for testing: