Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@

## notify 8.2.0 (unreleased)
- FEATURE: notify a user if the `max_user_watches` has been reached implicitly (`INotifyWatcher`) [#698]
- FIX: `INotifyWatcher` ignores events with unknown watch descriptors (instead of `EventMask::Q_OVERFLOW`) [#700]

[#698]: https://github.com/notify-rs/notify/pull/698
[#700]: https://github.com/notify-rs/notify/pull/700

## notify 8.1.0 (2025-07-03)
- FEATURE: added support for the [`flume`](https://docs.rs/flume) crate
Expand Down
9 changes: 8 additions & 1 deletion notify-debouncer-full/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,13 @@ impl<T: FileIdCache> DebounceDataInner<T> {
return;
}

let path = &event.paths[0];
let path = match event.paths.first() {
Some(path) => path,
None => {
log::info!("skipping event with no paths: {event:?}");
return;
}
};

match &event.kind {
EventKind::Create(_) => {
Expand Down Expand Up @@ -775,6 +781,7 @@ mod tests {
"add_create_event",
"add_create_event_after_remove_event",
"add_create_dir_event_twice",
"add_event_with_no_paths_is_ok",
"add_modify_content_event_after_create_event",
"add_rename_from_event",
"add_rename_from_event_after_create_event",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
// https://github.com/notify-rs/notify/issues/678
//
// There was a bug in INotifyWatcher that causes producing events with no paths.
// Debouncer should ignore this kind of events
{
state: {}
events: [
{ kind: "create-folder", paths: [] }
]
expected: {
queues: {}
}
}
Loading
Loading