Skip to content

Misleading error message when a component is not found #1596

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

Closed
Yatekii opened this issue Dec 31, 2018 · 1 comment
Closed

Misleading error message when a component is not found #1596

Yatekii opened this issue Dec 31, 2018 · 1 comment

Comments

@Yatekii
Copy link

Yatekii commented Dec 31, 2018

When one tries to install a component on a a toolchain which does not have that component, you get a message like this:

error: component 'rls' for target 'x86_64-unknown-linux-gnu' is unavailable for download

This message implies that the component does not exist for your architecture. But it in fact means it's not available for the currently selected toolchain, which is not mentioned in the error message.
For example in my case I had the toolchain of my PWD overridden to nightly and this rls was not found. The error message suggested that rls is not available for my architecture. But in fact it was available; just for stable.

This can be very missleading as for example in my case I knew that the component existed for my architecture and I though that something completely different went wrong. Maybe my net or the likes.

In my opinion it is absolutely never enough to imply something in error messages (as in this case it is implied that the current toolchain is meant) because unfamiliar users, which get confronted with error messages like this the most, are not aware of the implications.

There is an easy fix to this: Add the complete name of the toolchain to this error message and all is good.

kinnison added a commit to kinnison/rustup that referenced this issue Jan 17, 2019
In the component-unavailable error case, we need to report the
full toolchain rather than just the component and target name.
This threads it through and reports it in the error message.

Fixes: rust-lang#1596

Signed-off-by: Daniel Silverstone <[email protected]>
kinnison added a commit to kinnison/rustup that referenced this issue Jan 17, 2019
In the component-unavailable error case, we need to report the
full toolchain rather than just the component and target name.
This threads it through and reports it in the error message.

Fixes: rust-lang#1596

Signed-off-by: Daniel Silverstone <[email protected]>
kinnison added a commit to kinnison/rustup that referenced this issue Jan 21, 2019
In the component-unavailable error case, we need to report the
full toolchain rather than just the component and target name.
This threads it through and reports it in the error message.

Fixes: rust-lang#1596

Signed-off-by: Daniel Silverstone <[email protected]>
@fbruetting
Copy link

fbruetting commented Feb 16, 2019

I also have the same issue, and adding the complete name of the toolchain doesn’t fix this. Any suggestions?

rustup update nightly-x86_64-unknown-linux-gnu
info: syncing channel updates for 'nightly-x86_64-unknown-linux-gnu'
info: latest update on 2019-02-16, rust version 1.34.0-nightly (a9410cd1a 2019-02-15)
error: component 'rls' for target 'x86_64-unknown-linux-gnu' is unavailable for download

// OK, uninstalling and reinstalling nightly helped.

kinnison added a commit to kinnison/rustup that referenced this issue Mar 1, 2019
In the component-unavailable error case, we need to report the
full toolchain rather than just the component and target name.
This threads it through and reports it in the error message.

Fixes: rust-lang#1596

Signed-off-by: Daniel Silverstone <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants