rust-lang / rust-lang/rust-clippy
Clippy leaves cargo running in the background on SIGTERM
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 13.5k
- Forks
- 2.2k
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 32
Description
When you kill cargo-clippy via SIGTERM it will leave a detached cargo check process running in the background. If, for example, the clippy instance was launched by your editor and killed when you exited it this can result in a long duration of Blocking waiting for file lock on build directory when you attempt to run cargo test.
Test reproduction:
- Run
cargo clean && cargo clippyon a project that will take a decent while to check - In another terminal run
killall cargo-clippyto send SIGTERM - In the original terminal watch the process exit, but the output from checking continue to be printed
This appears to be already fixed by #3837, so maybe not worth trying to fix the current subcommand, I'm mostly opening this as informational in case others run into it as well.
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 the SIGTERM behavior with cargo clean && cargo clippy and killall cargo-clippy, then review the referenced issue #3837. Confirm whether that fix covers the detached cargo check process and the resulting build-directory lock; no specific file or test is named in this issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- cli, tooling
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100