-
Notifications
You must be signed in to change notification settings - Fork 12
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
'version_req' keyname should be 'req' #2
Comments
I think this is a cargo issue. The crates metadata are generated by Cargo. The key is indeed I'm able to fetch a crate from Meuse if the crate does not have dependencies. If a crate has a dependency, I should indeed replace I could transform |
I looked at this a little more and I think what cargo publishes isn't intended to go directly to the git index. notice there's a format for an index entry that uses 'req' and another format for the body of a publish request that uses 'version_req'. You can see crates.io building a git dependency from the published data here: https://github.com/rust-lang/crates.io/blob/e2f20c70093a91169e8a654e2a87a035ae3a54a7/src/models/dependency.rs#L115 and it's setting 'req' of the dependency to 'version_req' of the published crate. so... I think my title is wrong here... it's not just just the keyname that's different, it's the whole serialized object. But they're so similar that it happens to work with just renaming that key. very odd/lucky! |
You are right. The format in the git repository should now be OK ;) |
confirmed a fresh publish can be downloaded by another project using the private registry. |
when meuse creates the crate description it writes a key 'version_req'. that should be just 'req' as specified in https://github.com/rust-lang/rfcs/blob/master/text/2141-alternative-registries.md. cargo won't download the crate as published but after editing the repo and doing a search/replace I was able to download the crate.
The text was updated successfully, but these errors were encountered: