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

Update Cargo/crates.io Sparse Index support #217

Merged
merged 2 commits into from
Feb 6, 2023
Merged

Conversation

dmikusa
Copy link
Contributor

@dmikusa dmikusa commented Feb 3, 2023

Summary

The environment variable for Cargo/crates.io sparse index support has changed to CARGO_REGISTRIES_CRATES_IO_PROTOCOL=sparse. This PR updates that functionality. It is still enabled by default, but requires beta or nightly Rust to work. This should just start working when upstream Rust supports this in stable.

Use Cases

Faster builds, less data loaded when pulling necessary packages.

Checklist

  • I have viewed, signed, and submitted the Contributor License Agreement.
  • I have linked issue(s) that this PR should close using keywords or the Github UI (See docs)
  • I have added an integration test, if necessary.
  • I have reviewed the styleguide for guidance on my code quality.
  • I'm happy with the commit history on this PR (I have rebased/squashed as needed).

The environment variable for Cargo/crates.io sparse index support has changed to `CARGO_REGISTRIES_CRATES_IO_PROTOCOL=sparse`. This PR updates that functionality. It is still enabled by default, but requires beta or nightly Rust to work. This should just start working when upstream Rust supports this in stable.

Signed-off-by: Daniel Mikusa <[email protected]>
@dmikusa dmikusa added semver:patch A change requiring a patch version bump type:enhancement A general enhancement labels Feb 3, 2023
@dmikusa dmikusa requested a review from a team as a code owner February 3, 2023 16:04
@ForestEckhardt ForestEckhardt merged commit 174a319 into main Feb 6, 2023
@ForestEckhardt ForestEckhardt deleted the cargo-sparse branch February 6, 2023 15:32
@bjorn3
Copy link

bjorn3 commented Feb 20, 2023

This seems to break building on stable: https://users.rust-lang.org/t/error-while-building-function-with-knative/89555/9

@dmikusa
Copy link
Contributor Author

dmikusa commented Feb 25, 2023

@bjorn3 Thanks for raising that up. The previous CARGO_UNSTABLE_SPARSE_REGISTRY flag seemed to be just ignored if it was not capable of being used, like if you were not on a nightly release.

I'm also not seeing this with 1.67.1. Can you open a new issue and attach steps or a project so that I can reproduce it? Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
semver:patch A change requiring a patch version bump type:enhancement A general enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants