-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
rustc-dev component is broken by missing literal-escaper #138647
Comments
cc @rust-lang/bootstrap |
Hmm, I'm not sure if we want to ship library sources in the |
But I guess why not? Anyone have any concerns about doing that? |
It should also be possible to add just |
One possible solution:
|
This will break |
Sure, we could selectively add only the required crates. |
Another option would be to publish literal-escaper to crates.io. That would also allow proc-macro2 to use it. proc-macro2 needs to support not using libproc_macro, so it can't unconditionally use literal escaping through libproc_macro. |
Publishing on crates.io seems like the simplest solution. Should I do it? |
That doesn't sound like the simplest solution to me, tbh 😅 Unless the code is done and will never ever change? Otherwise we should probably have some setup for deploying it, managing the crates.io token, figuring out who will own the crate etc. (it probably shouldn't be owned by your GH account). |
Very good point. Then I'll keep quiet in the back and step in if my help is needed. 😆 |
So this change broke not just Miri but also RA? I've posted a revert to avoid blocking multiple tools while we figure out a proper solution: #138661. |
Just a small thing if publishing to crates.io is a possibility: we have a crate in rustdoc (https://crates.io/crates/rustdoc-json) that is published with rights given to https://cargo-public-api. Isn't it possible to do the same here? |
The change prevents us from doing subtree syncs, so technically yes (though there is another issue right now that prevents us from syncing until 1.86 releases) |
I guess that the token wouldn't be such an issue, but rather the deployment strategy, as we currently don't have workflows or secrets configured for deploying crates from the rust-lang/rust repository. I suppose that we should enumerate the possible solutions here, as it seems that there were also other concerns raised above, which would not be solved even by crates.io upload. |
So the listed solutions so far:
The point was for |
I think literal-escaper would have to be moved to another repo if we want to publish to crates.io either way. Otherwise any breaking change to literal-escaper would require first changing it for proc_macro, getting the PR merged, publishing to crates.io and finally opening a PR to change rustc_lexer to use the newly published version. |
I think that we could solve that with https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#multiple-locations? But even then I would probably also prefer for it to be a separate repo. |
Having it into a separate repository would make things a lot easier so I also prefer this solution. |
That doesn't work for rustc-dev. That functionality works by cargo stripping |
…r=petrochenkov Revert: Add *_value methods to proc_macro lib This reverts rust-lang#136355. That PR caused unexpected breakage: - the rustc-dev component can no longer be loaded by cargo, which impacts Miri and clippy and likely others - rustc_lexer can no longer be published to crates.io, which impacts RA See rust-lang#138647 for context. Cc `@GuillaumeGomez` `@Amanieu`
I created https://github.com/GuillaumeGomez/literal-escaper. So if we agree on publishing it to crates.io, we can move it to the rust-lang organization. |
That also won't help for RA I think. crates.io is probably the only option for sharing a dependency between |
Seems like crates.io it is. @Kobzol is gonna open a thread on zulip t-infra channel for the discussion to continue there. |
…r=petrochenkov Revert: Add *_value methods to proc_macro lib This reverts rust-lang#136355. That PR caused unexpected breakage: - the rustc-dev component can no longer be loaded by cargo, which impacts Miri and clippy and likely others - rustc_lexer can no longer be published to crates.io, which impacts RA See rust-lang#138647 for context. Cc `@GuillaumeGomez` `@Amanieu`
…, r=petrochenkov Revert: Add *_value methods to proc_macro lib This reverts rust-lang#136355. That PR caused unexpected breakage: - the rustc-dev component can no longer be loaded by cargo, which impacts Miri and clippy and likely others - rustc_lexer can no longer be published to crates.io, which impacts RA See rust-lang#138647 for context. Cc `@GuillaumeGomez` `@Amanieu`
Rollup merge of rust-lang#138661 - RalfJung:revert-rustc-dev-breakage, r=petrochenkov Revert: Add *_value methods to proc_macro lib This reverts rust-lang#136355. That PR caused unexpected breakage: - the rustc-dev component can no longer be loaded by cargo, which impacts Miri and clippy and likely others - rustc_lexer can no longer be published to crates.io, which impacts RA See rust-lang#138647 for context. Cc `@GuillaumeGomez` `@Amanieu`
…chenkov Revert: Add *_value methods to proc_macro lib This reverts rust-lang/rust#136355. That PR caused unexpected breakage: - the rustc-dev component can no longer be loaded by cargo, which impacts Miri and clippy and likely others - rustc_lexer can no longer be published to crates.io, which impacts RA See rust-lang/rust#138647 for context. Cc `@GuillaumeGomez` `@Amanieu`
Trying to load the rustc-dev packages with cargo leads to an error:
This is caused by #136355:
compiler
crates cannot have path dependencies outside thecompiler
folder.Cc @GuillaumeGomez @Amanieu
The text was updated successfully, but these errors were encountered: