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

After resolved conflict, don't attempt to re-synchronise #3908

Closed
mhsdesign opened this issue Jan 22, 2025 · 1 comment · Fixed by #3910
Closed

After resolved conflict, don't attempt to re-synchronise #3908

mhsdesign opened this issue Jan 22, 2025 · 1 comment · Fixed by #3910

Comments

@mhsdesign
Copy link
Member

While testing neos/neos-development-collection#5337 i found out through the e2e tests that the Neos Ui issues an obsolete call to rebase after the conflicts were resolved. Discarding or forcing a rebase does already rebase so a second rebase afterwards is obsolete, and will be handled more strictly with the core adjustments:

Image

The error should be prevented client side by not calling the endpoint in this case.

@mhsdesign
Copy link
Member Author

mhsdesign commented Jan 22, 2025

And there is a second similar case:

If during publishing an error occurs, the editor can either abort fully or choose to resolve the conflict.
But after the conflict resolution a new publish is started. This is in my opinion at first sight a nice guide but i previously also thought that this might contradict with the editors intention: E.g. what if some of the dropped changes were supposed to be published and now the publish continues wildly without asking?

Though one can definitely argue that the editor can if necessary just abort the publishing before resolving conflicts and then use the sync button separately ... though i think a 'Resolve conflicts' AND 'Resolve conflicts and continue publish' button makes sense.

Either way we need a solution for the case that the attempted changes were discarded and the publish is now obsolete. With the Neos adjustments neos/neos-development-collection#5337 this can happen and throws an exception (especially in tests if the only change was dropped):

Image

Edit as we already have special handling in place (

//
// It may happen that after conflicts are resolved, the
// document we're trying to publish no longer exists.
//
// We need to finish the publishing operation in this
// case, otherwise it'll lead to an error.
//
) where we respect that the current document was published we could also decide to check if there would still be changes in the publish icon and do the operation based on that on the client. However we should still consider to introduce a new modal window (or reshow the initial one) so its not forgotten that we are still in a workspace publish operation and that after the successful sync a break can be introduced ;)

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

Successfully merging a pull request may close this issue.

1 participant