From 4565cff72c60f56d8ad4b46716fe8df847554824 Mon Sep 17 00:00:00 2001 From: Ryan Ofsky Date: Tue, 24 Jun 2025 17:12:11 -0400 Subject: [PATCH] bitcoin-gui: Implement missing Init::makeMining method A missing Init::makeMining implementation was causing internal code using the mining interface (like the `waitforblockheight` RPC method) to not work when running inside the `bitcoin-gui` binary. It was working the other bitcoin binaries ('bitocind`, `bitcoin-qt`, and `bitcoin-node`) because they implmemented `Init::makeMining` methods in commit 8ecb6816781c7c7f423b501cbb2de3abd7250119 from #30200, but the `bitcoin-gui` init class was forgotten in that change. This bug was reported by Matthew Zipkin https://github.com/bitcoin/bitcoin/pull/32297#pullrequestreview-2932651216 --- src/init/bitcoin-gui.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/init/bitcoin-gui.cpp b/src/init/bitcoin-gui.cpp index 02e8f063620..45f623d026a 100644 --- a/src/init/bitcoin-gui.cpp +++ b/src/init/bitcoin-gui.cpp @@ -7,6 +7,7 @@ #include #include #include +#include #include #include #include @@ -29,6 +30,7 @@ public: } std::unique_ptr makeNode() override { return interfaces::MakeNode(m_node); } std::unique_ptr makeChain() override { return interfaces::MakeChain(m_node); } + std::unique_ptr makeMining() override { return interfaces::MakeMining(m_node); } std::unique_ptr makeWalletLoader(interfaces::Chain& chain) override { return MakeWalletLoader(chain, *Assert(m_node.args));