spacedrive icon indicating copy to clipboard operation
spacedrive copied to clipboard

Watcher panicked after editing file

Open matheus-consoli opened this issue 9 months ago • 1 comments

Describe the bug

The application crashes after editing a new file create from outside of Spacedrive.

Reproduction

  1. create a new Location
  2. let it open on the side
  3. create a new file in the location using another application (touch file)
  4. edit the file (vim file)

Expected behavior

The application should not crash

Platform and versions

>> pnpm --version && cargo --version && rustc --version
9.0.6
cargo 1.78.0 (54d8815d0 2024-03-26)
rustc 1.78.0 (9b00956e5 2024-04-29)

Stack trace

2024-05-06T22:37:54.692469Z ERROR sd_core: core/src/lib.rs:239: panicked at core/src/location/manager/watcher/utils.rs:942:13:
not yet implemented: file has changed in some way, re-identify it panic.file="core/src/location/manager/watcher/utils.rs:942" panic.column=13
fatal runtime error: failed to initiate panic, error 3

Additional context

The issue's origin is this todo!(): https://github.com/spacedriveapp/spacedrive/blob/44478207e72495b3777e294660d78939711b544f/core/src/location/manager/watcher/utils.rs#L942

I'll be happy to work on it, but I will just need some help with the expected behavior :)

matheus-consoli avatar May 06 '24 22:05 matheus-consoli