Skip to content
This repository has been archived by the owner on Dec 8, 2020. It is now read-only.

Misconfigured rustup default-host error #295

Closed
Seeker14491 opened this issue Jun 21, 2017 · 1 comment
Closed

Misconfigured rustup default-host error #295

Seeker14491 opened this issue Jun 21, 2017 · 1 comment

Comments

@Seeker14491
Copy link

Version of VSCode: 1.13.1
Version of the extension: 0.4.0
OS: Windows 10

> rustup show
Default host: x86_64-pc-windows-gnu

nightly-x86_64-pc-windows-msvc (default)
rustc 1.20.0-nightly (445077963 2017-06-20)

Description: RLS stopped working for me. I get an error about the windows-gnu toolchain not being installed. I don't have it installed; I use the MSVCtoolchain.

I found the problem while writing this issue: The command

rustup set default-host x86_64-pc-windows-msvc

fixed the problem. I'm still posting, as I'm not sure this is correct behavior. It might trip up others, as I didn't even know about rustup's default-host command. I think the default-host should be ignored, unless perhaps the user has both GNU and MSVC nightly toolchains.

Output of the "Rust Language Server" channel:

error: toolchain 'nightly-x86_64-pc-windows-gnu' is not installed
[Error - 4:18:29 PM] Connection to server got closed. Server will not be restarted.

Output of the "Rust logging" channel:

DEBUG: Rustup: updateToolchains: this.toolchains=[{"channel":"nightly","host":"x86_64-pc-windows-msvc","isDefault":true}]
DEBUG: Rustup: updateComponents(nightly-x86_64-pc-windows-msvc): components=["cargo-x86_64-pc-windows-msvc (default)","rls-x86_64-pc-windows-msvc (installed)","rust-analysis-x86_64-pc-windows-msvc (installed)","rust-docs-x86_64-pc-windows-msvc (default)","rust-src","rust-std-aarch64-apple-ios","rust-std-aarch64-linux-android","rust-std-aarch64-unknown-fuchsia","rust-std-aarch64-unknown-linux-gnu","rust-std-arm-linux-androideabi","rust-std-arm-unknown-linux-gnueabi","rust-std-arm-unknown-linux-gnueabihf","rust-std-arm-unknown-linux-musleabi","rust-std-arm-unknown-linux-musleabihf","rust-std-armv7-apple-ios","rust-std-armv7-linux-androideabi","rust-std-armv7-unknown-linux-gnueabihf","rust-std-armv7-unknown-linux-musleabihf","rust-std-armv7s-apple-ios","rust-std-asmjs-unknown-emscripten","rust-std-i386-apple-ios","rust-std-i586-pc-windows-msvc","rust-std-i586-unknown-linux-gnu","rust-std-i686-apple-darwin","rust-std-i686-linux-android","rust-std-i686-pc-windows-gnu","rust-std-i686-pc-windows-msvc","rust-std-i686-unknown-freebsd","rust-std-i686-unknown-linux-gnu","rust-std-i686-unknown-linux-musl","rust-std-mips-unknown-linux-gnu","rust-std-mips-unknown-linux-musl","rust-std-mips64-unknown-linux-gnuabi64","rust-std-mips64el-unknown-linux-gnuabi64","rust-std-mipsel-unknown-linux-gnu","rust-std-mipsel-unknown-linux-musl","rust-std-powerpc-unknown-linux-gnu","rust-std-powerpc64-unknown-linux-gnu","rust-std-powerpc64le-unknown-linux-gnu","rust-std-s390x-unknown-linux-gnu","rust-std-sparc64-unknown-linux-gnu","rust-std-wasm32-unknown-emscripten","rust-std-x86_64-apple-darwin","rust-std-x86_64-apple-ios","rust-std-x86_64-linux-android","rust-std-x86_64-pc-windows-gnu","rust-std-x86_64-pc-windows-msvc (default)","rust-std-x86_64-rumprun-netbsd","rust-std-x86_64-unknown-freebsd","rust-std-x86_64-unknown-fuchsia","rust-std-x86_64-unknown-linux-gnu","rust-std-x86_64-unknown-linux-musl","rust-std-x86_64-unknown-netbsd","rustc-x86_64-pc-windows-msvc (default)",""]
DEBUG: activate: getNightlyToolchain: There is only one nightly toolchain
DEBUG: RlsMode: start: enter
DEBUG: Rustup: isRlsInstalled: getNightlyToolchain: There is only one nightly toolchain
DEBUG: RlsMode: start: User decided to use rustfmt
DEBUG: Rustup: isRlsInstalled: getNightlyToolchain: There is only one nightly toolchain
DEBUG: RlsMode: start: rlsPath=rustup 
DEBUG: RlsMode: start: env={} 
DEBUG: Rustup: isRlsInstalled: getNightlyToolchain: There is only one nightly toolchain
DEBUG: RlsMode: start: args=["run","nightly","rls"] 
DEBUG: RlsMode: start: revealOutputChannelOn=3 
DEBUG: RlsMode: start: Language Client Manager: start

Relevant settings.json settings:

"rust.mode": "rls",
"rust.rls": {
	"useRustfmt": true,
	"env": {
		"RUST_LOG": "rls=debug"
	}
},
"rust.rustup": {
	"toolchain": "nightly-x86_64-pc-windows-msvc"
}
@KalitaAlexey
Copy link
Member

@Seeker14491,
It is going to be fixed when #280 will be fixed.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants