You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After executing rust-playground, only an emacs buffer is created for main.rs, not the physical file. This will make lsp server like rust-analyzer unable to start cause it expects "either src/lib.rs, src/main.rs, a [lib] section, or [[bin]] section must be present".
The full error is like this:
[stderr] rust-analyzer failed to load workspace: Failed to load the project at /tmp/rust-playground/at-2025-01-05-153947/Cargo.toml: Failed to read Cargo metadata from Cargo.toml file /tmp/rust-playground/at-2025-01-05-153947/Cargo.toml, Some(Version { major: 1, minor: 76, patch: 0 }): Failed to run `cd "/tmp/rust-playground/at-2025-01-05-153947" && "cargo" "metadata" "--format-version" "1" "--manifest-path" "/tmp/rust-playground/at-2025-01-05-153947/Cargo.toml" "--filter-platform" "aarch64-apple-darwin"`: `cargo metadata` exited with an error: error: failed to parse manifest at `/tmp/rust-playground/at-2025-01-05-153947/Cargo.toml`
[stderr]
[stderr] Caused by:
[stderr] no targets specified in the manifest
[stderr] either src/lib.rs, src/main.rs, a [lib] section, or [[bin]] section must be present
Seems like we should save the buffer to make sure the corresponding file is sinked.
The text was updated successfully, but these errors were encountered:
After executing
rust-playground
, only an emacs buffer is created formain.rs
, not the physical file. This will make lsp server like rust-analyzer unable to start cause it expects "either src/lib.rs, src/main.rs, a [lib] section, or [[bin]] section must be present".The full error is like this:
Seems like we should save the buffer to make sure the corresponding file is sinked.
The text was updated successfully, but these errors were encountered: