Repository navigation
Catalog and downloads: Don't write through a link at a temp file's name (#1502) - #1779
Merged
Merged
Conversation
bogusyogi
added a commit
to Orthic-Labs/ember
that referenced
this pull request
Oct 15, 2026
…me (storytold#1502) (upstream storytold#1779) Applied from storytold/lightcraft PR storytold#1779 (open upstream, not yet merged). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Member
|
Thank you @endthestart! This landed on main in integration batch 36 (#1843). If you haven't already, please join our Discord: https://discord.gg/artcraft. We'd love to have you there. |
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.
Saving the catalog writes
<name>.tmpand then renames it, and model downloads resume from<name>.part, but both opened those names in a way that follows a symlink, so a link left there got the write instead and the file it pointed to was changed. Now whatever is at the temp name is removed first (the link itself, never its target), and the new file is created withcreate_new. A.partis only resumed if it's a plain file, and it's checked again right before appending.I added a test for each, planting a link at the temp name to another file and checking that file is left alone and the save or download still works. Thanks!
Fixes #1502