Skip to content

bitcoind: call wait in drop to reap process - #585

Merged
tcharding merged 1 commit into
rust-bitcoin:masterfrom
nyonson:reap-process
May 7, 2026
Merged

tcharding merged 1 commit into
rust-bitcoin:masterfrom
nyonson:reap-process

Conversation

@nyonson

@nyonson nyonson commented May 6, 2026

Copy link
Copy Markdown
Contributor

Over in rust-psbt we are seeing integration test failures which result in a CI runner spinning for hours, even though the test failed in a minute. Setting aside why the test failed (looks bitcoind related but dunno what), I am wondering if we should have a stronger guarantee in the drop to clean up the process. I looked back in the old archive for the original impl reasoning and don't see much.

I could also see this being a big no-no in a Drop impl, but for a high level thing like the bitcoind process maybe better than not?

@RCasatta

RCasatta commented May 7, 2026

Copy link
Copy Markdown
Collaborator

Current code guarantees that failed stop RPC call will kill the process while in this PR it will not. I think adding wait could be fine like this:

  if let DataDir::Persistent(_) = self.work_dir {
      let _ = self.stop();
  }
  let _ = self.process.kill();
  let _ = self.process.wait();

@nyonson

nyonson commented May 7, 2026

Copy link
Copy Markdown
Contributor Author

Thanks @RCasatta, I totally missed that, updated in c08ea32

@tcharding tcharding left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK c08ea32

@tcharding
tcharding merged commit a10916a into rust-bitcoin:master May 7, 2026
39 checks passed
@tcharding

Copy link
Copy Markdown
Member

Hey @jamillambert lets do a point release to get this out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants