notify-rs / notify

🔭 Cross-platform filesystem notification library for Rust.
https://docs.rs/notify
2.77k stars 222 forks source link

Zbus / Nix Dependency Issue #562

Closed nadenf closed 9 months ago

nadenf commented 9 months ago

So there is an odd situation where Zbus has a dependency on Nix but didn't correctly specify it whereas some other library did which has now removed it.

Which in turn is causing Notify (latest version 4) to not compile on Ubuntu Linux with the following error:

error[E0432]: unresolved import `nix::unistd::Uid`
  --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zbus-3.14.1/src/address.rs:9:5
   |
   | use nix::unistd::Uid;
   |     ^^^^^^^^^^^^^^^^ no `Uid` in `unistd`
   |
note: found an item that was configured out
  --> /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/nix-0.26.4/src/unistd.rs:73:12
   |
   | pub struct Uid(uid_t);
   |            ^^^
   = note: the item is gated behind the `user` feature

There is a PR here which fixes it but you may want to temporarily fix this.

Reddit thread which is discussing this issue as it affects other libraries as well.

0xpr03 commented 9 months ago

Does that even affect notify? It sounds more like users of zbus have to upgrade such that the relevant feature is selected.

nadenf commented 9 months ago

Closing this. It was showing up as a dependency in Cargo.lock but must a transitive one.