Introduce atomic move and write of file - #4060
Conversation
cfd6b79 to
90f2259
Compare
|
@sampsyo any chances to review it? |
|
Hi, and thanks for your contribution! It's in my queue, but sometimes it can take me a while to have the bandwidth for a full review. Fortunately, the beets community is broad and doesn't just contain me, so other folks might also be able to take a look! You could consider putting out a broader call for reviewers in Discussions, etc., if you think that's warranted. |
wisp3rwind
left a comment
There was a problem hiding this comment.
Not a full review, but some initial thoughts/requests/comments. Let's be certain that this is correct before merging; the fallout might otherwise be huge.
84aff3f to
1a5ddf8
Compare
|
@wisp3rwind / @sampsyo ping? |
|
@sampsyo ping! |
|
It's not been forgotten! I'll try to have another look soon. |
|
@wisp3rwind just friendly reminder |
|
@sampsyo any hope to move forward on it? :) |
wisp3rwind
left a comment
There was a problem hiding this comment.
Looks good to me 🎉 Sorry for the silence here, I've recently had much less time (and motivation) to spend on beets than before.
See the inline comment for a small typo in the log messages. Would you mind adding a changelog entry?
|
@wisp3rwind I've incorporated your changes and rebased to last master. |
Great! A small style issue (line to long) has crept in in this last change, though. |
The idea of this changes is simple: let move file to some temporary name inside distance folder, and after the file is already copy it renames to expected name. When someone tries to save anything it also moves file to trigger OS level notification for change FS. This commit also enforce that `beets.util.move` shouldn't be used to move directories as it described in comment. Thus, this is fixed beetbox#3849
|
@wisp3rwind everything is green now! |
|
Great! I've added a changelog entry for this in 5578d07 |
The idea of this changes is simple: let move file to some temporary name inside distance folder, and after the file is already copy it renames to expected name.
When someone tries to save anything it also moves file to trigger OS level notification for change FS.
This commit also enforce that
beets.util.moveshouldn't be used to move directories as it described in comment.Thus, this is fixed #3849