Skip to content

Commit 5c4911e

Browse files
committed
Merge #20568: doc: Use FeeModes doc helper in estimatesmartfee
fa8abdc rpc: Use FeeModes doc helper in estimatesmartfee (MarcoFalke) Pull request description: Not sure why this doesn't use the doc helper, probably an oversight? ACKs for top commit: laanwj: Code review ACK fa8abdc Tree-SHA512: 1f2dc8356e3476ddcf9cafafa7f9865ad95bed1e3067c0edab8e3c483e374bdbdbecc066167554b4a1b479e28f6a52c4ae6a75a70c67ee4e1ff4f3ba36b04001
2 parents 03b1db6 + fa8abdc commit 5c4911e

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

src/rpc/mining.cpp

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1022,21 +1022,19 @@ static RPCHelpMan submitheader()
10221022
static RPCHelpMan estimatesmartfee()
10231023
{
10241024
return RPCHelpMan{"estimatesmartfee",
1025-
"\nEstimates the approximate fee per kilobyte needed for a transaction to begin\n"
1026-
"confirmation within conf_target blocks if possible and return the number of blocks\n"
1027-
"for which the estimate is valid. Uses virtual transaction size as defined\n"
1028-
"in BIP 141 (witness data is discounted).\n",
1029-
{
1030-
{"conf_target", RPCArg::Type::NUM, RPCArg::Optional::NO, "Confirmation target in blocks (1 - 1008)"},
1031-
{"estimate_mode", RPCArg::Type::STR, /* default */ "CONSERVATIVE", "The fee estimate mode.\n"
1025+
"\nEstimates the approximate fee per kilobyte needed for a transaction to begin\n"
1026+
"confirmation within conf_target blocks if possible and return the number of blocks\n"
1027+
"for which the estimate is valid. Uses virtual transaction size as defined\n"
1028+
"in BIP 141 (witness data is discounted).\n",
1029+
{
1030+
{"conf_target", RPCArg::Type::NUM, RPCArg::Optional::NO, "Confirmation target in blocks (1 - 1008)"},
1031+
{"estimate_mode", RPCArg::Type::STR, /* default */ "conservative", "The fee estimate mode.\n"
10321032
" Whether to return a more conservative estimate which also satisfies\n"
10331033
" a longer history. A conservative estimate potentially returns a\n"
10341034
" higher feerate and is more likely to be sufficient for the desired\n"
10351035
" target, but is not as responsive to short term drops in the\n"
1036-
" prevailing fee market. Must be one of:\n"
1037-
" \"UNSET\"\n"
1038-
" \"ECONOMICAL\"\n"
1039-
" \"CONSERVATIVE\""},
1036+
" prevailing fee market. Must be one of (case insensitive):\n"
1037+
"\"" + FeeModes("\"\n\"") + "\""},
10401038
},
10411039
RPCResult{
10421040
RPCResult::Type::OBJ, "", "",

test/functional/rpc_estimatefee.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ def run_test(self):
4141
self.nodes[0].estimatesmartfee(1)
4242
# self.nodes[0].estimatesmartfee(1, None)
4343
self.nodes[0].estimatesmartfee(1, 'ECONOMICAL')
44+
self.nodes[0].estimatesmartfee(1, 'unset')
45+
self.nodes[0].estimatesmartfee(1, 'conservative')
4446

4547
self.nodes[0].estimaterawfee(1)
4648
self.nodes[0].estimaterawfee(1, None)

0 commit comments

Comments
 (0)