kbknapp / cargo-outdated

A cargo subcommand for displaying when Rust dependencies are out of date
MIT License
1.2k stars 94 forks source link

`cargo outdated -R` gets confused by path dependencies #334

Open oconnor663 opened 1 year ago

oconnor663 commented 1 year ago

In one of my projects, I have a subdirectory that refers to its parent directory with path = ".." when building locally. The relevant line of Cargo.toml looks like this:

blake3 = { version = "1", path = "..", features = ["rayon"] }

This seems to confuse cargo outdated -R:

$ git clone https://github.com/BLAKE3-team/BLAKE3
$ cd BLAKE3/b3sum
$ cargo outdated
All dependencies are up to date, yay!
$ cargo outdated -R
error: failed to parse manifest at `/tmp/cargo-outdatedsaTTC8/Cargo.toml`

Caused by:
  feature `neon` includes `blake3/neon`, but `blake3` is not a dependency

If I remove the path field from Cargo.toml, this error goes away. I vaguely remember this working in the past, but I'm having trouble bisecting it, as other recent versions seem to produce an error: failed to select a version for the requirement clap = "^4.0.8" that I don't really understand.

BlackDex commented 1 year ago

I have the exact same issue, it also doesn't help if i add the package attribute, it just doesn't seem to recognize it.

It also doesn't help to add those to the ignore or exclude list.