Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cargo check -p fails with ambiguous package names #18121

Open
benjamin-lieser opened this issue Sep 16, 2024 · 0 comments · May be fixed by #18123
Open

cargo check -p fails with ambiguous package names #18121

benjamin-lieser opened this issue Sep 16, 2024 · 0 comments · May be fixed by #18123
Labels
C-bug Category: bug

Comments

@benjamin-lieser
Copy link

benjamin-lieser commented Sep 16, 2024

rust-analyzer version: 0.3.2112-standalone

rustc version: rustc 1.79.0-nightly (244da22fa 2024-04-23)

editor or extension: VSCode

relevant settings: None

repository link (if public, optional): https://github.com/benjamin-lieser/rand/tree/cdf_testing

I get the following error message:

2024-09-16T13:22:58.748136Z ERROR Flycheck failed to run the following command: CommandHandle { program: "/home/benjamin/.cargo/bin/cargo", arguments: ["check", "-p", "rand_distr", "--test", "cdf", "--message-format=json-diagnostic-rendered-ansi", "--manifest-path", "/home/benjamin/git/myrand/Cargo.toml", "--keep-going", "--all-targets"], current_dir: Some("/home/benjamin/git/myrand") }, error=Cargo watcher failed, the command produced no valid metadata (exit code: ExitStatus(unix_wait_status(25856))):
error: There are multiple `rand_distr` packages in your project, and the specification `rand_distr` is ambiguous.
Please re-run this command with one of the following specifications:
  rand_distr@0.4.3
  rand_distr@0.5.0-alpha.1

The package rand_distr is there in version 0.5.0-alpha.1 and in version 0.4.3 inside the dependency tree.
I guess this is related to #3781

Running the tests from VS code works fine, it executes cargo test --package rand_distr:0.5.0-alpha.1 --test cdf -- normal --exact --show-output

@benjamin-lieser benjamin-lieser added the C-bug Category: bug label Sep 16, 2024
@jhgg jhgg linked a pull request Sep 16, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant