Skip to content

show {unknown} type #18560

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
ByteXiang opened this issue Nov 26, 2024 · 3 comments
Closed

show {unknown} type #18560

ByteXiang opened this issue Nov 26, 2024 · 3 comments
Labels
C-bug Category: bug

Comments

@ByteXiang
Copy link

The latest version of rustc (1.82.0) with rust-analyzer (2024-11-25) will appear {unknown} type prompt, the solution is to downgrade rustc to 1.81.0 or rust-analyzer to 2024-08-12. The computer configuration is win10 professional version, 22H2, 19045.4894, this is a company computer and cannot share data.

rust-analyzer version: 2024-11-25

rustc version: 1.82.0

editor or extension: VSCode 1.95.3

relevant settings: (eg. client settings, or environment variables like CARGO, RUSTC, RUSTUP_HOME or CARGO_HOME)

repository link (if public, optional): (eg. rust-analyzer)

code snippet to reproduce:

let content = fs::read_to_string(path)?;
@ByteXiang ByteXiang added the C-bug Category: bug label Nov 26, 2024
@lnicola
Copy link
Member

lnicola commented Nov 26, 2024

What does rustup component list show? And do you have any errors in the logs?

Also, please try this: #17759 (comment).

@RuelYasa
Copy link

Also, please try this: #17759 (comment).

Thanks —— this works for me.

The problem is seemingly related with crates-io mirrors in China, which is possibly not up-to-date. Therefore, it helps to disable mirrors.

@lnicola
Copy link
Member

lnicola commented Nov 27, 2024

More likely, to your proxy settings which we don't propagate. See also #18511, which probably wouldn't have helped for the same reason.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: bug
Projects
None yet
Development

No branches or pull requests

3 participants