Repository navigation
fix(backend): tell users when and why a mind map was not saved - #461
Merged
Merged
Conversation
1 task done
When saving a mind map threw an unexpected exception, the response showed the file's path as the error, a leftover from debugging. Users now read that the mind map could not be saved and should try again later, and the exception is logged, so admins can find out what went wrong. Assisted-by: Claude Code:claude-opus-5-5 Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
A save request without the modification time of the loaded file was compared against the file's mtime and failed with "The file you are working on was updated in the meantime", which sent users looking for a conflict that did not exist. Both the user and the public share controller now tell users that the mind map could not be saved and to reload it, which fetches a fresh modification time, and log the request for admins. The branch that was meant to handle this could never be reached and is gone, and log entries from the save endpoint are no longer attributed to files_texteditor. Assisted-by: Claude Code:claude-opus-5-5 Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
AndyScherzinger
force-pushed
the
fix/backend-save-errors
branch
from
October 27, 2026 16:43
77496fb to
5a793cf
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two save errors now tell users what happened and what to do, and leave the technical details to the server log. Taken from the analysis of #259 (thanks @stephancordes for the diagnosis).
Also cleaned up while there: the branch originally meant for the missing modification time could never be reached and is removed, and the save endpoint no longer logs under
files_texteditor.The two messages are new strings and go through Transifex as usual.
Not included from #259: normalizing
$dir . '/' . $filenameinload().Folder::get()already collapses duplicate slashes (PathHelper::normalizePath()), so//file.kmresolves fine.The repo has no PHP test setup, so this is checked with
php -l. Manual checks to do on an instance: save normally; save with a tampered mtime (expect the "updated in the meantime" message); save with the mtime removed from the request (expect the reload message and a log entry); the same on a public share with edit rights.The 0.1.x backport is #462; the controllers are identical there.
🤖 AI (if applicable)