Skip to content
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

BUG: UriPathProjection cannot recover from missing UriPathSegments in nested+tethered documentNodes #5413

Open
1 task done
mficzel opened this issue Dec 22, 2024 · 0 comments · May be fixed by #5412
Open
1 task done

Comments

@mficzel
Copy link
Member

mficzel commented Dec 22, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

If documents are created as tethered nodes they often have no uriPathSegments. Currently this leads to incomplete document-uri-pathes. This is problematic for two reasons:

  1. This allows to create empty path segments which is a feature we do not plan to support ATM
  2. This cannot be fixed afterwards by setting UriPathSegments since on setProperties(uriPathSegment) only the last part of the path is ever changed.

Expected Behavior

The uriProjection should project a valid pathSegment for all documents below sites regardless wether the a uriPathSegment was defined during node creation.

It should be discussed wether this is done by creating the UriPathSegment in that case or by falling back to the nodeAggregateId as fallback.

Steps To Reproduce

Steps:

  1. create a autocreated document "A" as child of the Site that has no defaut value for uriPathSegment.
  2. that has another autocreated document "B" that has no default value for uriPathSegment.
  3. Create a document below "B"

Verify:

  1. The child Below "B" does not get a full uriPath
  2. After manually setting the path for "A" and "B" the children only get an incomplete path without the segment for "A"

Environment

- Flow: 9
- Neos: 9
- PHP: 8.3

Anything else?

The Reason behind this behavior is the ambiguity of the meaning of "" in the UriPathProjection which on the one hand is path for a site-node but is also used as a fallback for the uriPathSegment. This leads to parent Nodes accidentally beeing treated like site-nodes.

mficzel added a commit to mficzel/neos-development-collection that referenced this issue Dec 22, 2024
…gments

The testcase verifies that the nodeAggregateId is used as fallback in case no uriPathSegment
was set and that this can be overwritten afterwards of a proper uriPathSegment is set later.

Relates: neos#5413
mficzel added a commit to mficzel/neos-development-collection that referenced this issue Dec 22, 2024
…gments

The testcase verifies that the nodeAggregateId is used as fallback in case no uriPathSegment
was set and that this can be overwritten afterwards of a proper uriPathSegment is set later.

Relates: neos#5413
@mficzel mficzel changed the title BUG: UriPathProjection cannot recover from missing UriPathSegments in tethered-nodes BUG: UriPathProjection cannot recover from missing UriPathSegments in nested+tethered documentNodes Dec 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant