Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: properly hook gix's interrupt handler #552

Closed
ds-cbo opened this issue Aug 31, 2023 · 0 comments · Fixed by #549
Closed

Bug: properly hook gix's interrupt handler #552

ds-cbo opened this issue Aug 31, 2023 · 0 comments · Fixed by #549
Labels
bug Something isn't working

Comments

@ds-cbo
Copy link

ds-cbo commented Aug 31, 2023

Describe the bug

cargo deny check repeatedly seemed to hang "indefinitely" because I kept Ctrl-C'ing the process before it could hit the 10-minute mark. I had tried enabling the TRACE log messages, but it didn't give any clear reason why it seemed to be hanging. While I was cloning the repo and adding several more trace messages to figure out where and why it could be hanging, a background process finally hit the 10-minute mark and gave the exact error message I was looking for (ie: that a lockfile from a crashed instance was still lingering).

I think the proper fix is to actually properly hook gix's interrupt handler so interrupts cause the lockfile to be deleted before the process exits/is aborted.

To reproduce

  1. cargo-deny check & pkill cargo-deny to create the lockfile (yes, that single & is on purpose, because we want to put cargo-deny to the background to kill it, it's not a typo for &&)
  2. confirm the lockfile exists at $HOME/.cargo/advisory-dbs/github.cargo-deny.lock
  3. cargo-deny check will hang now

cargo-deny version

cargo-deny 0.14.1

What OS were you running cargo-deny on?

MacOS

Additional context

Keywords for searchability: hangs, hanging, freeze, frozen, no output, stuck, doesn't exit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant