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

universal-lock: deal with hashes (or lack there of) for some types of distributions #3357

Closed
Tracked by #3347
BurntSushi opened this issue May 3, 2024 · 0 comments
Closed
Tracked by #3347
Assignees
Labels
preview Experimental behavior

Comments

@BurntSushi
Copy link
Member

Currently, a ResolvedDist does not always have a hash. This is a problem for the lock file where we'd ideally want hashes for at least direct URL dependencies. We currently also don't have hashes for Git or Path dependencies, but I think we probably don't want those. (Cargo doesn't use hashes for that case either.)

So I think we need to fix this:

fn from_direct_dist(direct_dist: &DirectUrlBuiltDist) -> Wheel {
Wheel {
url: direct_dist.url.to_url(),
// TODO: We want a hash for the artifact at the URL.
hash: todo!(),
filename: direct_dist.filename.clone(),
}
}

And this:

fn from_direct_dist(direct_dist: &DirectUrlSourceDist) -> SourceDist {
SourceDist {
url: direct_dist.url.to_url(),
// TODO: We want a hash for the artifact at the URL.
hash: todo!(),
}
}

And then probably update the data structures so that hash isn't required for the git and path sources.

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

No branches or pull requests

2 participants