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 after upgrade from 8.3.12 to 8.3.13: deleting nodes does not flush relevant caches #5105

Closed
1 task done
patricekaufmann opened this issue May 29, 2024 · 12 comments
Closed
1 task done
Labels

Comments

@patricekaufmann
Copy link

patricekaufmann commented May 29, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

In 8.3.13, caches are no longer getting flushed when a node is deleted. The cache configurations make use of the EEL helpers Neos.Caching.nodeTypeTag and Neos.Caching.descendantOfTag, in both cases caches are no longer getting flushed when deleting a node that should lead to a cache flush. I verified the issue not occuring in 8.3.12.

Expected Behavior

Referencing cache entries should be flushed when a node is deleted.

Steps To Reproduce

No response

Environment

- Flow: 8.3.9
- Neos: 8.3.13
- PHP: 8.1 / 8.3

Anything else?

Edit: I noticed that backend caches are flushed correctly and it's merely the frontend caches that are not getting flushed.

@dlubitz
Copy link
Contributor

dlubitz commented Jun 1, 2024

Thanks for your report. Might be related to #4291

@patricekaufmann
Copy link
Author

The cause is the commit c99cd8b

When I delete the lines, it is working as expected.

@patricekaufmann
Copy link
Author

I also noticed that backend caches are flushed correctly and it's merely the frontend caches that are not getting flushed. Looking at the previously mentioned commit I would assume that the node is already null in live workspace and therefore the method returns early.

@dlubitz
Copy link
Contributor

dlubitz commented Jun 5, 2024

Fixed with #5124. Will be released with next bugfix release soonish.

@dlubitz dlubitz closed this as completed Jun 5, 2024
@crydotsnake
Copy link
Member

crydotsnake commented Jun 14, 2024

What exactly was the behavior you had? @patricekaufmann
In 8.3.14 i have the issue, that when i delete a node and publish the workspace, the node is still there. But I will check it more closely during the day as it was a bit late last night :) But it was on a freshly new 8.3.14 project i started yesterday.

@patricekaufmann
Copy link
Author

With 8.3.14, I cannot reproduce any of the issues I encountered before. I also tried publishing to another internal workspace first. It works as expected when publishing to the live workspace afterwards via the workspace module.

@crydotsnake
Copy link
Member

This is the behavior i have with Neos 8.3.14:

Animation

When i add a node to the page, and publish and refresh the backend, the node is not visible in the backend and frontend but still visible in the content tree. In the frontend only a empty content collection will be rendered.

@crydotsnake
Copy link
Member

I recorded it again but in OBS and with a better solution:

2024-06-14.20-13-55.mp4

I even updated my project to Neos 8.3.15 but this didnt help either..

And i dont believe this is a problem with my NodeType configuration.

@crydotsnake
Copy link
Member

And if i edit my publishd node, the change will not even be registered.

2024-06-14.20-20-47.mp4

@crydotsnake
Copy link
Member

I solved it but i really have no idea what the issue was.

For small nodes like a headline i always build my renderer like:

headline = ${q(node).property('title')}
renderer = afx`
  <Neos.Neos:Editable property={props.headline}/>
`

But this didnt work. I'm 100% sure this SHOULD work! As i have done this the same way hundred of times already.

With:

     headline = Neos.Neos:Editable {
         property = 'title'
     }
    
    renderer = afx`
        {props.headline}
    `

It works.

@jonnitto
Copy link
Member

I solved it but i really have no idea what the issue was.

For small nodes like a headline i always build my renderer like:

headline = ${q(node).property('title')}
renderer = afx`
  <Neos.Neos:Editable property={props.headline}/>
`

But this didnt work. I'm 100% sure this SHOULD work! As i have done this the same way hundred of times already.

With:

     headline = Neos.Neos:Editable {
         property = 'title'
     }
    
    renderer = afx`
        {props.headline}
    `

It works.

The first didn't work because it is wrong. Neos.Neos:Editable want the property name, not the value of the property. So your code should look like this:

headline = 'title'
renderer = afx`
  <Neos.Neos:Editable property={props.headline}/>
`

But it is better anyway to keep the Neos.Neos:Editable outside of an afx tag, as it is an integration part and not a presentation

@crydotsnake
Copy link
Member

The first didn't work because it is wrong. Neos.Neos:Editable want the property name, not the value of the property. So your code should look like this:

Yes 🤦🏼‍♂️ I dont know if i should laugh or cry 😅..

Thanks @jonnitto ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants