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

Crate should be marked as "does not build" when dependency has all its versions yanked #2083

Closed
MaciekTalaska opened this issue Dec 31, 2019 · 2 comments

Comments

@MaciekTalaska
Copy link

I think it could be a good idea to show that a particular crate can not be build if one of the dependencies has all of its versions yanked.

In such a case it is impossible to use the crate without making changes to the source of the crate itself, and (what is very important for some people) it is not possible to use cargo install (as the crate will not be build).

For an example, please have a look at the following crate: https://crates.io/crates/lobsters

@smarnach
Copy link
Contributor

smarnach commented Jan 2, 2020

Yanked dependencies should not affect your ability to build a crate. Yanked versions can still be downloaded, so dependent crates should continue to build.

The example you gave can't be installed with cargo install because it does not contain any binaries. The binary for this lib is in the lobsters-cli crate, which the author did not upload to crates.io. I suggest asking the author to upload that crate, which will allow you to run cargo install lobsters-cli.

I will close this issue for now. Feel free to reopen it in case I misunderstood the issue.

@smarnach smarnach closed this as completed Jan 2, 2020
@carols10cents
Copy link
Member

Aside from the issue of lobsters not including any binaries, there is an issue with cargo install ignoring the lockfiles that may exist with a binary crate. Rust 1.37 added a --locked flag you can pass to cargo install to tell it to use the lockfile, which should allow the crate to depend on any yanked versions that appear in said lockfile. Related: rust-lang/cargo#7169 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants