Skip to content

Commit e012e7d

Browse files
committed
Implement savemempool method and test
1 parent dc0122e commit e012e7d

File tree

41 files changed

+129
-36
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+129
-36
lines changed

client/src/client_sync/v17/blockchain.rs

+16
Original file line numberDiff line numberDiff line change
@@ -302,6 +302,22 @@ macro_rules! impl_client_v17__pruneblockchain {
302302
};
303303
}
304304

305+
/// Implements Bitcoin Core JSON-RPC API method `savemempool`
306+
#[macro_export]
307+
macro_rules! impl_client_v17__savemempool {
308+
() => {
309+
impl Client {
310+
pub fn save_mempool(&self) -> Result<SaveMempool> {
311+
match self.call("savemempool", &[]) {
312+
Ok(serde_json::Value::Null) => Ok(SaveMempool),
313+
Ok(res) => Err(Error::Returned(res.to_string())),
314+
Err(err) => Err(err.into()),
315+
}
316+
}
317+
}
318+
};
319+
}
320+
305321
/// Implements Bitcoin Core JSON-RPC API method `verifytxoutproof`
306322
#[macro_export]
307323
macro_rules! impl_client_v17__verifytxoutproof {

client/src/client_sync/v17/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ crate::impl_client_v17__gettxoutproof!();
4949
crate::impl_client_v17__gettxoutsetinfo!();
5050
crate::impl_client_v17__preciousblock!();
5151
crate::impl_client_v17__pruneblockchain!();
52+
crate::impl_client_v17__savemempool!();
5253
crate::impl_client_v17__verifytxoutproof!();
5354

5455
// == Control ==

client/src/client_sync/v18/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ crate::impl_client_v17__gettxoutproof!();
4343
crate::impl_client_v17__gettxoutsetinfo!();
4444
crate::impl_client_v17__preciousblock!();
4545
crate::impl_client_v17__pruneblockchain!();
46+
crate::impl_client_v17__savemempool!();
4647
crate::impl_client_v17__verifytxoutproof!();
4748

4849
// == Control ==

client/src/client_sync/v19/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ crate::impl_client_v17__gettxoutproof!();
4444
crate::impl_client_v17__gettxoutsetinfo!();
4545
crate::impl_client_v17__preciousblock!();
4646
crate::impl_client_v17__pruneblockchain!();
47+
crate::impl_client_v17__savemempool!();
4748
crate::impl_client_v17__verifytxoutproof!();
4849

4950
// == Control ==

client/src/client_sync/v20.rs

+1
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ crate::impl_client_v17__gettxoutproof!();
4141
crate::impl_client_v17__gettxoutsetinfo!();
4242
crate::impl_client_v17__preciousblock!();
4343
crate::impl_client_v17__pruneblockchain!();
44+
crate::impl_client_v17__savemempool!();
4445
crate::impl_client_v17__verifytxoutproof!();
4546

4647
// == Control ==

client/src/client_sync/v21/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ crate::impl_client_v17__gettxoutproof!();
4343
crate::impl_client_v17__gettxoutsetinfo!();
4444
crate::impl_client_v17__preciousblock!();
4545
crate::impl_client_v17__pruneblockchain!();
46+
crate::impl_client_v17__savemempool!();
4647
crate::impl_client_v17__verifytxoutproof!();
4748

4849
// == Control ==

client/src/client_sync/v22/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ crate::impl_client_v17__gettxoutproof!();
4444
crate::impl_client_v17__gettxoutsetinfo!();
4545
crate::impl_client_v17__preciousblock!();
4646
crate::impl_client_v17__pruneblockchain!();
47+
crate::impl_client_v17__savemempool!();
4748
crate::impl_client_v17__verifytxoutproof!();
4849

4950
// == Control ==
+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
// SPDX-License-Identifier: CC0-1.0
2+
3+
//! Macros for implementing JSON-RPC methods on a client.
4+
//!
5+
//! Specifically this is methods found under the `== Blockchain ==` section of the
6+
//! API docs of Bitcoin Core `v0.23`.
7+
//!
8+
//! All macros require `Client` to be in scope.
9+
//!
10+
//! See or use the `define_jsonrpc_minreq_client!` macro to define a `Client`.
11+
/// Implements Bitcoin Core JSON-RPC API method `savemempool`
12+
#[macro_export]
13+
macro_rules! impl_client_v23__savemempool {
14+
() => {
15+
impl Client {
16+
pub fn save_mempool(&self) -> Result<SaveMempool> { self.call("savemempool", &[]) }
17+
}
18+
};
19+
}

client/src/client_sync/v23/mod.rs

+2
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
//!
55
//! We ignore option arguments unless they effect the shape of the returned JSON data.
66
7+
pub mod blockchain;
78
pub mod wallet;
89

910
use std::collections::BTreeMap;
@@ -44,6 +45,7 @@ crate::impl_client_v17__gettxoutproof!();
4445
crate::impl_client_v17__gettxoutsetinfo!();
4546
crate::impl_client_v17__preciousblock!();
4647
crate::impl_client_v17__pruneblockchain!();
48+
crate::impl_client_v23__savemempool!();
4749
crate::impl_client_v17__verifytxoutproof!();
4850

4951
// == Control ==

client/src/client_sync/v24.rs

+1
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ crate::impl_client_v17__gettxoutproof!();
4141
crate::impl_client_v17__gettxoutsetinfo!();
4242
crate::impl_client_v17__preciousblock!();
4343
crate::impl_client_v17__pruneblockchain!();
44+
crate::impl_client_v23__savemempool!();
4445
crate::impl_client_v17__verifytxoutproof!();
4546

4647
// == Control ==

client/src/client_sync/v25.rs

+1
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ crate::impl_client_v17__gettxoutproof!();
4141
crate::impl_client_v17__gettxoutsetinfo!();
4242
crate::impl_client_v17__preciousblock!();
4343
crate::impl_client_v17__pruneblockchain!();
44+
crate::impl_client_v23__savemempool!();
4445
crate::impl_client_v17__verifytxoutproof!();
4546

4647
// == Control ==

client/src/client_sync/v26/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ crate::impl_client_v17__gettxoutproof!();
4545
crate::impl_client_v26__gettxoutsetinfo!();
4646
crate::impl_client_v17__preciousblock!();
4747
crate::impl_client_v17__pruneblockchain!();
48+
crate::impl_client_v23__savemempool!();
4849
crate::impl_client_v17__verifytxoutproof!();
4950

5051
// == Control ==

client/src/client_sync/v27.rs

+1
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ crate::impl_client_v17__gettxoutproof!();
4141
crate::impl_client_v26__gettxoutsetinfo!();
4242
crate::impl_client_v17__preciousblock!();
4343
crate::impl_client_v17__pruneblockchain!();
44+
crate::impl_client_v23__savemempool!();
4445
crate::impl_client_v17__verifytxoutproof!();
4546

4647
// == Control ==

client/src/client_sync/v28/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ crate::impl_client_v17__gettxoutproof!();
4343
crate::impl_client_v26__gettxoutsetinfo!();
4444
crate::impl_client_v17__preciousblock!();
4545
crate::impl_client_v17__pruneblockchain!();
46+
crate::impl_client_v23__savemempool!();
4647
crate::impl_client_v17__verifytxoutproof!();
4748

4849
// == Control ==

integration_test/tests/blockchain.rs

+13
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,19 @@ fn blockchain__prune_blockchain() {
276276
let _: Result<PruneBlockchain, _> = node.client.prune_blockchain(target_height);
277277
}
278278

279+
#[test]
280+
fn blockchain__savemempool() {
281+
let node = Node::with_wallet(Wallet::Default, &[]);
282+
283+
node.fund_wallet();
284+
let (_addr, _txid) = node.create_mempool_transaction();
285+
286+
// Give node a moment to process mempool tx
287+
std::thread::sleep(std::time::Duration::from_millis(200));
288+
289+
let _: Result<SaveMempool, _> = node.client.save_mempool();
290+
}
291+
279292
#[test]
280293
fn blockchain__verify_tx_out_proof__modelled() {
281294
let node = Node::with_wallet(Wallet::Default, &[]);

types/src/v17/blockchain/mod.rs

+7
Original file line numberDiff line numberDiff line change
@@ -650,6 +650,13 @@ pub struct PruneBlockchain(
650650
pub i64,
651651
);
652652

653+
/// Result of JSON-RPC method `savemempool`.
654+
///
655+
/// > savemempool
656+
/// > Dumps the mempool to disk. It will fail until the previous dump is fully loaded.
657+
#[derive(Clone, Debug, PartialEq, Eq, Deserialize, Serialize)]
658+
pub struct SaveMempool;
659+
653660
/// Result of JSON-RPC method `verifytxoutproof`.
654661
///
655662
/// > verifytxoutproof "proof"

types/src/v17/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -243,8 +243,8 @@ pub use self::{
243243
GetMempoolDescendantsVerbose, GetMempoolEntry, GetMempoolInfo, GetMempoolInfoError,
244244
GetRawMempool, GetRawMempoolVerbose, GetTxOut, GetTxOutError, GetTxOutSetInfo,
245245
GetTxOutSetInfoError, MapMempoolEntryError, MempoolEntry, MempoolEntryError,
246-
MempoolEntryFees, MempoolEntryFeesError, PruneBlockchain, Softfork, SoftforkReject,
247-
VerifyTxOutProof,
246+
MempoolEntryFees, MempoolEntryFeesError, PruneBlockchain, SaveMempool, Softfork,
247+
SoftforkReject, VerifyTxOutProof,
248248
},
249249
control::{GetMemoryInfoStats, Locked, Logging},
250250
generating::{Generate, GenerateToAddress},

types/src/v18/mod.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -265,8 +265,8 @@ pub use crate::v17::{
265265
MapMempoolEntryError, MempoolAcceptance, MempoolEntry, MempoolEntryError, MempoolEntryFees,
266266
MempoolEntryFeesError, PeerInfo, PruneBlockchain, PsbtInput, PsbtOutput, PsbtScript,
267267
RawTransaction, RawTransactionError, RawTransactionInput, RawTransactionOutput,
268-
RescanBlockchain, SendMany, SendRawTransaction, SendToAddress, SignFail, SignFailError,
269-
SignMessage, SignRawTransaction, SignRawTransactionError, Softfork, SoftforkReject,
270-
TestMempoolAccept, TransactionCategory, UploadTarget, VerifyTxOutProof, WalletCreateFundedPsbt,
271-
WalletCreateFundedPsbtError, WalletProcessPsbt, WitnessUtxo,
268+
RescanBlockchain, SaveMempool, SendMany, SendRawTransaction, SendToAddress, SignFail,
269+
SignFailError, SignMessage, SignRawTransaction, SignRawTransactionError, Softfork,
270+
SoftforkReject, TestMempoolAccept, TransactionCategory, UploadTarget, VerifyTxOutProof,
271+
WalletCreateFundedPsbt, WalletCreateFundedPsbtError, WalletProcessPsbt, WitnessUtxo,
272272
};

types/src/v19/mod.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -266,10 +266,10 @@ pub use crate::v17::{
266266
ListTransactions, ListTransactionsItem, ListTransactionsItemError, ListUnspent,
267267
ListUnspentItem, ListUnspentItemError, ListWallets, LoadWallet, Locked, Logging, PeerInfo,
268268
PruneBlockchain, RawTransactionError, RawTransactionInput, RawTransactionOutput,
269-
RescanBlockchain, SendMany, SendRawTransaction, SendToAddress, SignMessage, SignRawTransaction,
270-
SignRawTransactionError, SoftforkReject, TestMempoolAccept, TransactionCategory, UploadTarget,
271-
VerifyTxOutProof, WalletCreateFundedPsbt, WalletCreateFundedPsbtError, WalletProcessPsbt,
272-
WitnessUtxo,
269+
RescanBlockchain, SaveMempool, SendMany, SendRawTransaction, SendToAddress, SignMessage,
270+
SignRawTransaction, SignRawTransactionError, SoftforkReject, TestMempoolAccept,
271+
TransactionCategory, UploadTarget, VerifyTxOutProof, WalletCreateFundedPsbt,
272+
WalletCreateFundedPsbtError, WalletProcessPsbt, WitnessUtxo,
273273
};
274274
#[doc(inline)]
275275
pub use crate::v18::{

types/src/v20/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -258,8 +258,8 @@ pub use crate::{
258258
ListSinceBlockTransaction, ListSinceBlockTransactionError, ListTransactions,
259259
ListTransactionsItem, ListTransactionsItemError, ListUnspent, ListUnspentItem,
260260
ListUnspentItemError, ListWallets, LoadWallet, Locked, PeerInfo, PruneBlockchain,
261-
RawTransactionError, RawTransactionInput, RawTransactionOutput, RescanBlockchain, SendMany,
262-
SendRawTransaction, SendToAddress, SignMessage, SignRawTransaction,
261+
RawTransactionError, RawTransactionInput, RawTransactionOutput, RescanBlockchain,
262+
SaveMempool, SendMany, SendRawTransaction, SendToAddress, SignMessage, SignRawTransaction,
263263
SignRawTransactionError, SoftforkReject, TestMempoolAccept, TransactionCategory,
264264
UploadTarget, VerifyTxOutProof, WalletCreateFundedPsbt, WalletCreateFundedPsbtError,
265265
WalletProcessPsbt, WitnessUtxo,

types/src/v21/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -264,8 +264,8 @@ pub use crate::{
264264
ListSinceBlockTransaction, ListSinceBlockTransactionError, ListTransactions,
265265
ListTransactionsItem, ListTransactionsItemError, ListUnspent, ListUnspentItem,
266266
ListUnspentItemError, ListWallets, LoadWallet, Locked, PeerInfo, PruneBlockchain,
267-
RawTransactionError, RawTransactionInput, RawTransactionOutput, RescanBlockchain, SendMany,
268-
SendRawTransaction, SendToAddress, SignMessage, SignRawTransaction,
267+
RawTransactionError, RawTransactionInput, RawTransactionOutput, RescanBlockchain,
268+
SaveMempool, SendMany, SendRawTransaction, SendToAddress, SignMessage, SignRawTransaction,
269269
SignRawTransactionError, SoftforkReject, TestMempoolAccept, TransactionCategory,
270270
UploadTarget, VerifyTxOutProof, WalletCreateFundedPsbt, WalletCreateFundedPsbtError,
271271
WalletProcessPsbt, WitnessUtxo,

types/src/v22/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -279,8 +279,8 @@ pub use crate::{
279279
ListSinceBlockTransactionError, ListTransactions, ListTransactionsItem,
280280
ListTransactionsItemError, ListUnspent, ListUnspentItem, ListUnspentItemError, ListWallets,
281281
LoadWallet, Locked, PeerInfo, PruneBlockchain, RawTransactionError, RawTransactionInput,
282-
RawTransactionOutput, RescanBlockchain, SendMany, SendRawTransaction, SendToAddress,
283-
SignMessage, SignRawTransaction, SignRawTransactionError, SoftforkReject,
282+
RawTransactionOutput, RescanBlockchain, SaveMempool, SendMany, SendRawTransaction,
283+
SendToAddress, SignMessage, SignRawTransaction, SignRawTransactionError, SoftforkReject,
284284
TestMempoolAccept, TransactionCategory, UploadTarget, VerifyTxOutProof,
285285
WalletCreateFundedPsbt, WalletCreateFundedPsbtError, WalletProcessPsbt, WitnessUtxo,
286286
},

types/src/v23/blockchain.rs

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
// SPDX-License-Identifier: CC0-1.0
2+
3+
//! The JSON-RPC API for Bitcoin Core `v23` - blockchain.
4+
//!
5+
//! Types for methods found under the `== Blockchain ==` section of the API docs.
6+
use serde::{Deserialize, Serialize};
7+
8+
/// Result of JSON-RPC method `savemempool`.
9+
///
10+
/// > savemempool
11+
/// > Dumps the mempool to disk. It will fail until the previous dump is fully loaded.
12+
#[derive(Clone, Debug, PartialEq, Deserialize, Serialize)]
13+
pub struct SaveMempool {
14+
/// The directory and file where the mempool was saved.
15+
pub filename: String,
16+
}

types/src/v23/mod.rs

+7-3
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
//! | gettxoutsetinfo | version + model | |
5050
//! | preciousblock | returns nothing | |
5151
//! | pruneblockchain | returns numeric | |
52-
//! | savemempool | returns nothing | |
52+
//! | savemempool | returns string | |
5353
//! | scantxoutset | omitted | API marked as experimental |
5454
//! | verifychain | returns boolean | |
5555
//! | verifytxoutproof | version + model | |
@@ -236,11 +236,15 @@
236236
//! </details>
237237
238238
// JSON-RPC types by API section.
239+
mod blockchain;
239240
mod raw_transactions;
240241

241242
#[doc(inline)]
242-
pub use self::raw_transactions::{
243-
DecodePsbt, DecodePsbtError, GlobalXpub, Proprietary, PsbtInput, PsbtOutput,
243+
pub use self::{
244+
blockchain::SaveMempool,
245+
raw_transactions::{
246+
DecodePsbt, DecodePsbtError, GlobalXpub, Proprietary, PsbtInput, PsbtOutput,
247+
},
244248
};
245249
#[doc(inline)]
246250
pub use crate::{

types/src/v24/mod.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
//! | gettxspendingprevout | version + model | TODO |
5151
//! | preciousblock | returns nothing | |
5252
//! | pruneblockchain | returns numeric | |
53-
//! | savemempool | returns nothing | |
53+
//! | savemempool | returns string | |
5454
//! | scantxoutset | omitted | API marked as experimental |
5555
//! | verifychain | returns boolean | |
5656
//! | verifytxoutproof | version + model | |
@@ -294,4 +294,5 @@ pub use crate::{
294294
},
295295
v21::UnloadWallet,
296296
v22::{GetTxOut, GetTxOutError, Logging, ScriptPubkey},
297+
v23::SaveMempool,
297298
};

types/src/v25/mod.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
//! | gettxspendingprevout | version + model | TODO |
5151
//! | preciousblock | returns nothing | |
5252
//! | pruneblockchain | returns numeric | |
53-
//! | savemempool | returns nothing | |
53+
//! | savemempool | returns string | |
5454
//! | scanblocks | version + model | TODO |
5555
//! | scantxoutset | omitted | API marked as experimental |
5656
//! | verifychain | returns boolean | |
@@ -290,6 +290,7 @@ pub use crate::{
290290
SoftforkType,
291291
},
292292
v22::{GetTxOut, GetTxOutError, Logging, ScriptPubkey},
293+
v23::SaveMempool,
293294
v24::{
294295
DecodePsbt, DecodePsbtError, GlobalXpub, Proprietary, PsbtInput, PsbtOutput,
295296
TaprootBip32Deriv, TaprootLeaf, TaprootScript, TaprootScriptPathSig,

types/src/v26/mod.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
//! | loadtxoutset | version + model | TODO |
5555
//! | preciousblock | returns nothing | |
5656
//! | pruneblockchain | returns numeric | |
57-
//! | savemempool | returns nothing | |
57+
//! | savemempool | returns string | |
5858
//! | scanblocks | version + model | TODO |
5959
//! | scantxoutset | omitted | API marked as experimental |
6060
//! | verifychain | returns boolean | |
@@ -310,6 +310,7 @@ pub use crate::{
310310
SoftforkType,
311311
},
312312
v22::{GetTxOut, GetTxOutError, Logging, ScriptPubkey},
313+
v23::SaveMempool,
313314
v24::{
314315
DecodePsbt, DecodePsbtError, GlobalXpub, Proprietary, PsbtInput, PsbtOutput,
315316
TaprootBip32Deriv, TaprootLeaf, TaprootScript, TaprootScriptPathSig,

types/src/v27/mod.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
//! | loadtxoutset | version + model | TODO |
5555
//! | preciousblock | returns nothing | |
5656
//! | pruneblockchain | returns numeric | |
57-
//! | savemempool | returns nothing | |
57+
//! | savemempool | returns string | |
5858
//! | scanblocks | version + model | TODO |
5959
//! | scantxoutset | omitted | API marked as experimental |
6060
//! | verifychain | returns boolean | |
@@ -294,6 +294,7 @@ pub use crate::{
294294
SoftforkType,
295295
},
296296
v22::{GetTxOut, GetTxOutError, Logging, ScriptPubkey},
297+
v23::SaveMempool,
297298
v24::{
298299
DecodePsbt, DecodePsbtError, GlobalXpub, Proprietary, PsbtInput, PsbtOutput,
299300
TaprootBip32Deriv, TaprootLeaf, TaprootScript, TaprootScriptPathSig,

types/src/v28/mod.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
//! | loadtxoutset | version + model | TODO |
5555
//! | preciousblock | returns nothing | |
5656
//! | pruneblockchain | returns numeric | |
57-
//! | savemempool | returns nothing | |
57+
//! | savemempool | returns string | |
5858
//! | scanblocks | version + model | TODO |
5959
//! | scantxoutset | omitted | API marked as experimental |
6060
//! | verifychain | returns boolean | |
@@ -300,6 +300,7 @@ pub use crate::{
300300
MempoolEntryError, MempoolEntryFees, MempoolEntryFeesError, Softfork, SoftforkType,
301301
},
302302
v22::{GetTxOut, GetTxOutError, Logging, ScriptPubkey},
303+
v23::SaveMempool,
303304
v24::{
304305
DecodePsbt, DecodePsbtError, GlobalXpub, Proprietary, PsbtInput, PsbtOutput,
305306
TaprootBip32Deriv, TaprootLeaf, TaprootScript, TaprootScriptPathSig,

verify/src/method/v17.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ pub const METHODS: &[Method] = &[
3131
Method::new_modelled("gettxoutsetinfo", "GetTxOutSetInfo", "get_tx_out_set_info"),
3232
Method::new_nothing("preciousblock", "precious_block"),
3333
Method::new_no_model("pruneblockchain", "PruneBlockchain", "prune_blockchain"),
34-
Method::new_nothing("savemempool", "save_mempool"),
34+
Method::new_no_model("savemempool", "SaveMempool", "save_mempool"),
3535
Method::new_modelled("scantxoutset", "ScanTxOutSet", "scan_tx_out_set"),
3636
Method::new_bool("verifychain", "verify_chain"),
3737
Method::new_modelled("verifytxoutproof", "VerifyTxOutProof", "verify_tx_out_proof"),

verify/src/method/v18.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ pub const METHODS: &[Method] = &[
3131
Method::new_modelled("gettxoutsetinfo", "GetTxOutSetInfo", "get_tx_out_set_info"),
3232
Method::new_nothing("preciousblock", "precious_block"),
3333
Method::new_no_model("pruneblockchain", "PruneBlockchain", "prune_blockchain"),
34-
Method::new_nothing("savemempool", "save_mempool"),
34+
Method::new_no_model("savemempool", "SaveMempool", "save_mempool"),
3535
Method::new_modelled("scantxoutset", "ScanTxOutSet", "scan_tx_out_set"),
3636
Method::new_bool("verifychain", "verify_chain"),
3737
Method::new_modelled("verifytxoutproof", "VerifyTxOutProof", "verify_tx_out_proof"),

0 commit comments

Comments
 (0)