notify
notify copied to clipboard
Mac: `FSEvent` ignores hard links
System details
- Intel MacBook running macOS BIgSur 11.6
- Using APFS
rustc --version: 1.57.0- Notify version: latest
main
What you did (as detailed as you can)
- Watch for changes in a directory using
FsEventWatcher. - Create a file with
touch foo. - Create a hard-link using
ln foo bar
What you expected
I expect to get an Event for both actions.
What happened
Only the creation of foo is reported. Nothing happens when creating the hardlink-file (bar).
Investigation
I added some logging inside of src/fsevent.rs and I get no callback when creating the hard-link, so this is likely a problem with FSEvent, or how it is being used. I tried looking for some extra flag to pass into FSEventStreamCreate, but couldn't find anything suitable.
On v5 you could test if the macos_kqueue feature gives you a better result using the kqueue backend.
According to this it could be an issue with fsevent itself.