rust-lang / rust-lang/rust-analyzer
PATH env is incorrect for "Run Test" on mac osx
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 16.9k
- Forks
- 2.2k
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 72
Description
rust-analyzer version: v0.3.2319.
When I click "Run Test", I got the error below:
But if I run the same command in the terminal, it works:
Here is where the cargo binary is located:
% which cargo
/Users/alan.xu/.cargo/bin/cargo
So I think the PATH env is incorrect for "Run Test".
(btw, I'm using zsh, and the PATH is set in ~/.zshrc)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce Run Test on macOS with zsh and compare the environment's PATH with the terminal PATH, especially the reported /Users/alan.xu/.cargo/bin/cargo location. Trace the Run Test entry point and process-launch environment; done means the generated test command can resolve cargo as it does in the terminal.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- macos, rust, zsh
- Domain
- devtools, operating-systems, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100