Linemux does not compile anymore -- notify has been updated and broke it.
sjm42 opened this issue · comments
Compiling linemux v0.2.3
error[E0061]: this function takes 2 arguments but 1 argument was supplied
--> /home/sjm/.cargo/registry/src/github.com-1ecc6299db9ec823/linemux-0.2.3/src/events.rs:62:49
|
62 | let inner: notify::RecommendedWatcher = notify::RecommendedWatcher::new(move |res| {
| _________________________________________________^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-
63 | | // The only way `send` can fail is if the receiver is dropped,
64 | | // and `MuxedEvents` controls both. `unwrap` is not used,
65 | | // however, since `Drop` idiosyncrasies could otherwise result
66 | | // in a panic.
67 | | let _ = tx.send(res);
68 | | })
| |__________- an argument of type `Config` is missing
|
note: associated function defined here
--> /home/sjm/.cargo/registry/src/github.com-1ecc6299db9ec823/notify-5.0.0-pre.16/src/lib.rs:294:8
|
294 | fn new<F: EventHandler>(event_handler: F, config: config::Config) -> Result<Self>
| ^^^
help: provide the argument
|
62 ~ let inner: notify::RecommendedWatcher = notify::RecommendedWatcher::new(move |res| {
63 + // The only way `send` can fail is if the receiver is dropped,
64 + // and `MuxedEvents` controls both. `unwrap` is not used,
65 + // however, since `Drop` idiosyncrasies could otherwise result
66 + // in a panic.
67 + let _ = tx.send(res);
68 + }, /* Config */)
|
For more information about this error, try `rustc --explain E0061`.
error: could not compile `linemux` due to previous error
Well, as linemux
commit from 2022-06-05 says "update notify to 5.0.0-pre.14" I suspect that now notify
has made a breaking change with their pre5-version.
It looks like this simple change was able to fix it. Cargo is a bit weird sometimes...
Thanks for the report-- notify
should really be getting pinned while 5.0 is still under RC.
Whee, many thanks! \o/