Weihang Lo

Results 766 comments of Weihang Lo

Agree, and since `Cargo.toml.orig` is there, plugins should have alternative way to get the original manifest file.

Hmm… I didn't look closer. Seems like `cargo vendor` intentionally skips `Cargo.toml.orig` since `cargo-vendor` was imported into cargo from a community plugin. https://github.com/rust-lang/cargo/blob/363a2d11320faf531f6aacd1ea067c6bc08343b9/src/cargo/ops/vendor.rs#L341-L348 We may want to reconsider copying `Cargo.toml.orig`...

Oops I wrote a false claim there: https://github.com/rust-lang/cargo/blob/a9c749c33ea42e64d423d0174518793412f7b5c4/src/cargo/core/compiler/build_context/target_info.rs#L809-L811 Given that is accidentally supported, shoud we just make it a feature and document it?

Got an impression that @Eh2406 just talked about this somewhere. @Eh2406 do you remember anything?

Good finding! Thank you. I've tested several toolchains. Starting from 1.46.0 Cargo contains this bug, which contains the PR that you observed the potential bad commit. The Cargo started using...

Thanks for looking into the issue! The effort is much appreciated :) However, there are probably two things we need to take care of: * [The patch](https://github.com/JEnoch/cargo/commit/0be684bd2de29d1b955b34635ac288290a36b075) seems for GitHub...

> I think the root of the issue is that the conversion from short SHA to `git2::Oid` leads to a 20 bytes SHA completed with `0`s that cannot be found...

Oops. I didn't realize this is claimed. Sorry for that, @linyihai 😔 Actually I was trying to provide guidance but ended up writing a fix

> For registry, the path prefix would be things like `index.crates.io-6f17d22bba15001f/winnow-0.5.26` > > For git, the path prefix would be things like `winnow-110da4674123f04f/` > > What are the stability guarantees...

> Please note that the `registry@` and `git@` prefixes would complicate things again. Hmm… Maybe I understand the original concern wrong 🤔 ? I would expect remapped paths to be...