Skip to content

[stable35] fix: don't silently drop outside changes (e.g. from external storage) - #9530

Open
backportbot[bot] wants to merge 3 commits into
stable35from
backport/9518/stable35
Open

backportbot[bot] wants to merge 3 commits into
stable35from
backport/9518/stable35

Conversation

@backportbot

@backportbot backportbot Bot commented Nov 4, 2026 •

Copy link
Copy Markdown

Backport of #9518

Warning, This backport's changes differ from the original and might be incomplete ⚠️

Todo

  • Review and resolve any conflicts
  • Review and verify the backported changes
  • Amend HEAD commit to remove the line stating to skip CI

Learn more about backports at https://docs.nextcloud.com/server/stable/go.php?to=developer-backports.

@backportbot
backportbot Bot requested review from max-nextcloud and mejo- November 4, 2026 08:59
@backportbot backportbot Bot added bug Something isn't working 3. to review regression AI assisted This PR contains AI-assisted commits labels Nov 4, 2026
@backportbot backportbot Bot added this to the Nextcloud 35.0.3 milestone Nov 4, 2026
@mejo-
mejo- force-pushed the backport/9518/stable35 branch from ceaff46 to 819d1e8 Compare November 4, 2026 09:23
@mejo-
mejo- marked this pull request as ready for review November 4, 2026 09:24
@mejo-
mejo- requested a review from silverkszlo as a code owner November 4, 2026 09:24
@mejo-

mejo- commented Nov 4, 2026

Copy link
Copy Markdown
Member

/backport! to stable34

mejo- added 3 commits November 4, 2026 15:30
…extcloud

Writes that bypass Nextcloud, e.g. directly on external storage, do not
trigger the NodeWritten listeners, so a stored document and its yjs state
were reused when the file was opened again, and the editor showed outdated
content.

When opening a session, compare the stored checksum with the current file.
If it differs and the document has no unsaved changes, reset the document
so the client loads the current file content. Documents with unsaved
changes are kept so the conflict is raised on the next save.

Refs: #9236

Signed-off-by: Jonas <jonas@freesources.org>
Assisted-by: ClaudeCode:claude-opus-5-5
Since conflicts are no longer reported by the sync endpoint, a save
rejected because the file changed outside of Text returned 409 with the
outside content, but SaveService ignored it. The editor kept retrying
silently and the changes were never saved.

Emit a SAVE_COLLISION error so the conflict resolution dialog is shown.

Refs: #9236

Signed-off-by: Jonas <jonas@freesources.org>
Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: Jonas <jonas@freesources.org>
Assisted-by: ClaudeCode:claude-opus-5-5
@mejo-
mejo- force-pushed the backport/9518/stable35 branch from 6a39495 to 977bd1d Compare November 4, 2026 14:31

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review AI assisted This PR contains AI-assisted commits bug Something isn't working regression

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant