zed
zed copied to clipboard
Working with Git staging can set binary files to 0 bytes
Summary
Editing a binary file, like an image, while working with the Git pane in Zed can lead to the file becoming 0 bytes large.
Description
I have tried to reproduce this in a small, new project, but can't get the error to show again. Here's what happened:
- I added images to my project.
- I staged them using the Git pane in Zed
- I compressed the images using ImageOptim, thereby changing them on disk.
Expected Behavior: the images should compress, and should be able to stage the updated images Actual Behavior: one of the images became 0 bytes large.
This happened several times, always on the same images. When trying this again on a new, fresh project, I can't reproduce it. I can't find any relevant error in the Zed logs either. I still wanted to submit this bug in case someone else can reproduce it or at least stumbles over a similar issue. Maybe we can start narrowing down what causes this.
Zed Version and System Specs
Zed: v0.188.6 (Zed) OS: macOS 15.5.0 Memory: 24 GiB Architecture: aarch64