[HELP] rust-analyzer on VScodium completely fails to load workspace

⚓ rust    📅 2025-06-16    👤 surdeus    👁️ 2      

surdeus

Relevant version/installation info

Plasma Wayland at 6.3.5
Kernel version at 6.15.2-arch1-1 (64-bit)

Rust tools

rustup 1.28.2
rustc 1.87.0 (17067e9ac 2025-05-09)
All tools are added to PATH and working correctly in the terminal from root and from within the project body

VScodium

Version: 1.101.03933
Commit: 3a9d13eb624032e7f764def3dd45db451a4f0270
Date: 2025-06-12T21:31:35.492Z
Electron: 35.5.1
ElectronBuildId: undefined
Chromium: 134.0.6998.205
Node.js: 22.15.1
V8: 13.4.114.21-electron.0
OS: Linux x64 6.15.2-arch1-1

Problem description

Recently I have decided to do a migration over to Linux, which went well so far. However the rust-analyzer extensions fails miserably trying to fetch my workspaces. This happens to both my old ones (Which previously worked fine with my old VSCode + Windows setup), and a fresh "Example" project I made whilst trying to solve the issue myself. Below is a snippet of the extension output generated whenever I open a .rs file in the workplace

2025-06-16T11:00:10.77176176+02:00 ERROR failed fetching toolchain version for ManifestPath { file: AbsPathBuf("/home/Waterpig/Documents/git/example/Cargo.toml") } workspace e=Failed to query rust toolchain version via `cd "/home/Waterpig/Documents/git/example" && "cargo" "--version"`, is your toolchain setup correctly?
2025-06-16T11:00:10.772182703+02:00 ERROR failed fetching data layout for ManifestPath { file: AbsPathBuf("/home/Waterpig/Documents/git/example/Cargo.toml") } workspace e=unable to fetch target-data-layout via `cd "/home/Waterpig/Documents/git/example" && RUSTC_BOOTSTRAP="1" "rustc" "-Z" "unstable-options" "--print" "target-spec-json"`
2025-06-16T11:00:10.772316083+02:00 ERROR FetchWorkspaceError: rust-analyzer failed to load workspace: Failed to load the project at /home/Waterpig/Documents/git/example/Cargo.toml: Failed to read Cargo metadata from Cargo.toml file /home/Waterpig/Documents/git/example/Cargo.toml, None: Failed to run `cd "/home/Waterpig/Documents/git/example" && "cargo" "metadata" "--format-version" "1" "--manifest-path" "/home/Waterpig/Documents/git/example/Cargo.toml"`: No such file or directory (os error 2)

Running all these inside either the VSCodium bash terminal or completely out of scope from a terminal works completely fine. For brevity sake here's just one such example:

image

I'm unsure if I missed a crucial configuration step here? I've not seen this issue anywhere.

Things already tried

  • Reinstalling rustup, and adding it to path manually instead of it doing it automatically
  • Restarting everything like 10 times, once for each step
  • Reinstalling rust-analyzer
  • Changing the default terminal for VSCodium

1 post - 1 participant

Read full topic

🏷️ rust_feed