Merged
Conversation
* Do not raise an exception when saving a document and an object has 'freeze' status because this breaks the project file and may lead to loss of data. * Make 'freeze' state persistent * When toggling 'freeze' status only work directly on the selection. Do not use in-list or out-list of an object because this makes it quite inflexible and leads to unpredictable behaviour. This fixes issue with saving frozen files described in 18806.
hyarion
reviewed
Feb 5, 2026
Contributor
hyarion
left a comment
There was a problem hiding this comment.
Nothing too controversial, I added some thoughts in the code.
I'd like to get @FlachyJoe's input on the freeze change.
We might also want to backport some of these changes.
Do not directly pass getNameInDocument() to the ostream as this will set the badbit in case it returns nullptr. As a result no further output is written to the stream and leads to loss of data. Instead the returned C string is stored in a local variable and in case it's nullptr an empty string is passed to the ostream. At the end of the function writeObjects() it's checked whether the failbit or badbit is set. If yes an error message is printed and the failbit or badbit are cleared. This is supposed to fix the issue 18044. In case this fix is not sufficient it can be also check for every object inside writeObjectData()
This reduces build time when adding new Python functions because only one file must be compiled.
This was
linked to
issues
Feb 5, 2026
Collaborator
|
Backport failed for Please cherry-pick the changes locally and resolve any conflicts. git fetch origin releases/FreeCAD-1-1
git worktree add -d .worktree/backport-27355-to-releases/FreeCAD-1-1 origin/releases/FreeCAD-1-1
cd .worktree/backport-27355-to-releases/FreeCAD-1-1
git switch --create backport-27355-to-releases/FreeCAD-1-1
git cherry-pick -x 6c9ad95a70bf60242826739c84579c62025d4a24 2c2cdbfe7f94735a377c06f98389f507aed0d8c1 2c3d9e2bb702d35c8c0fe688f69682f614fb09f7 c97f6e5b3f29d9a4f698686ea63067596cf29236 4f116d8de36975ca220eaf4cd75e482062c139f6 cda2b8cbdbd9838335a9cef880d5f7fa8e81e99e |
Contributor
|
Let's wait about two weeks before backporting it |
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.
A continuation of #27243, this time a bit harder to review. Includes fix for #18044, which is marked as closed by #24123, but that improves reading corrupted file, while fix included here improves writer side. Also includes fix for #18806, which is marked as fixed by #20442, but the fix here allows saving frozen object.
All patches courtesy of @wwmayer.
Cc: @chennes, @hyarion,