-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Run stable fmt
& cargo
through rustup
#12953
Conversation
@bors r+ |
☀️ Test successful - checks-actions |
This broke tests in environment without |
It did, but without it the tests completely break on Windows because of a |
For me, this PR pulls in not-required Personally, I think we should not intervene the setup of development environment without user consent (like calling |
I think there was a time when we installed Or are you running the tests as part of building a package? |
FWIW, rustup was always assumed, just in an ignorable way using |
Yes and I did ignore them currently.
The previous method is implemented by me in #4219 to remove this assumption. This PR kinda reverted it. |
does this not also affect runtime, because of the changes to lib.rs? as in, requiring rustup to be installed for anything using the sourcegen formatting function. i personally don't have rustup installed, nor see a reason to ever have it for myself, so this is quite a change (if so) |
@nekopsykose it doesn't. It's strictly about some tests in rust-analyzer itself. sourcegen is for generating parts of RA itself. You can even compile it without rustup, since the generated code is checked in |
ah, okay. thanks for the clarification! |
cargo test -p ide-assists
fails on Windows/x64/nightly:After some investigation it seemed that
cmd!
didn't execute the expected (stable) rustfmt.A simple
xshell
test failed too:Bypassing
xshell
and usingCommand
directly failed too:Spawning
cargo +stable fmt version
failed too witherror: no such subcommand: +stable
.Only
rustup run stable
worked fine for bothcargo
andfmt
.Thanks to @lnicola for a live investigation session, hints and tips.