I'm working in a relatively large closed-source Rust workspace, and I've been having sporadic issues with RA (+ vscode) hanging forever locking up the CPU, but only in this workspace.
I normally use sccache to improve my incremental build times, but for the purposes of debugging, I've uninstalled it completely. I've also tried uninstalling RA, installing older versions, and deleting plugin files manually. I've tried deleting all rust build artifacts on my machine as well.
The other strange thing is I'm seeing similar behavior on a separate device, so I presume this is somehow related to this particular workspace, although no one else working in it is having this issue.
Another data point - I've been running without too much trouble, until I did a full reboot, and RA seemed to hang on opening the workspace in vscode. I waited, but eventually killed the process and disabled RA in vscode.
I tried running rust-analyzer analysis-stats /path/to/project but that also seemed to hang indefinitely. You said it should be much simpler to work from if I'm able to reproduce the hang as I have - what next steps do you recommend?
After restarting vscode, I ran cargo check/build/run without it taking too much time, and without errors. After this, I was able to run analysis-stats:
It seems like something is going on, only when I start up RA from a fresh boot, yet it's resolved by manually running cargo build.
Edit: It's also clear RA/rustc is doing something while it appears to hang: my computer is basically completely locked up with a rustc process hammering every logical processor.
I'll continue to debug and post here as I (hopefully) narrow this down.