I have recurrent issues working with the Forest admin layout.
My different actions are not all correctly recorded.
It can occur at any time, in any environment, and it is not showing any error.
Please find below the video that illustrates the issue.
I am hiding three columns, and when refreshing the layout, only two of three have been changed.
I have the same problem when changing the order of the columns.
It is very unpleasant and we cannot known in advance what will be correctly recorded.
Sorry to read your issue.
Can you tell us when you recorded the screencast you shared in this post exactly?
Do you feel this specific to columns layout edition?
All my regrets for this inconvenience.
Let’s take the example of hiding 3 collections, only 2 were really hidden after page refresh.
Were you able finally to hide successfully the third collection by using again the layout editor?
It was recorded this morning just before opening this ticket (and after applying the last release of forest-express / forest-express-sequelize).
Do you feel this specific to columns layout edition?
I am not sure. I think that I already encountered the same issue on other actions in the layout.
When this occurred previously, I was thinking that I forgot to make some action.
I have just noticed, that it was occurring too frequently to be my repeated mistake.
I am sure that I already had the same issue while ordering the columns in layout edition.
I can repeat the same layout actions, and sometimes, it works, sometime the same issue appears again. It is very strange. I cannot define a specific action that make it work or not.
This looks like the kind of issue that is hard to track.
I have a lot of questions, confirmation to help us.
Questions:
What is your project name?
What environment+team faces the issue?
Is it only for this environment? team?
Confirmations:
Some patches are sometimes applied,
There is never any console.error, (only PATCH 200)
It can happen on hiding collection, but also on (just one other example would be helpful)
What environment+team faces the issue?
Is it only for this environment? team?
All environments / all teams.
I can reproduce the issue whenever I want, whatever the collection is.
Some patches are sometimes applied,
There is never any console.error , (only PATCH 200)
It can happen on hiding collection, but also on (just one other example would be helpful)
Yes, I can see the PATCH methods called for each column that I am hiding.
They are returning 204.
Here is an example of the PATCH payload.
I think that this is issued linked to a deferred operation somewhere on your server.
If I wait around 10 seconds, and load the page again, sometime, the new display is different again.
This is really annoying as I do not never know if my modifications are taken into account or not.
Bad news, I am able to easily reproduce the same original issue
Sorry.
However, there is something new:
if I am waiting a bit (around 1 min) before reloading the page again, then the changes are applied correctly.
So, it seems that the changes are taken into account, but are deferred and not visible immediately when I reload the page.
Same thing for the collection that was hidden, it is now visible.
So there is a delay in the rendering, while Forest gives the message that the changes are saved.
When you save a change in the layout, it becomes immediately visible to you, as you just made the changes.
But behind the scenes, the real update takes some time to be saved, processed and committed in your project. The processing is done asynchronously in order to let you continue your work on Forest Admin.
So when you are refreshing your browser just after a modification, you might not receive the latest version of it.
We are working on improving the delay between saving and the actual commit of a layout, but the overall behavior will remain the same.
Now that the change is really recorded and taken into account, that should not be a real issue.
Excepting one detail:
When showing the collection, if I quit the layout design mode and try to display its content, (even without reloading the page), I 'm getting an error because your server is considering that it is not visible yet.
So that is difficult to understand at first use… Do you understand?