I assume file-system operations happen in a deterministic order, then write code that breaks the moment it's touched
In one sentence: I may confuse write completion, publication of complete files, and crash durability, or treat a watcher as a complete operation log; establish each guarantee from the API, filesystem, and publication protocol.