diff --git a/doc/release-notes.md b/doc/release-notes.md --- a/doc/release-notes.md +++ b/doc/release-notes.md @@ -3,3 +3,4 @@ This release includes the following features and fixes: + - Remove deprecated `estimatepriority` RPC. diff --git a/src/policy/fees.h b/src/policy/fees.h --- a/src/policy/fees.h +++ b/src/policy/fees.h @@ -248,13 +248,6 @@ CFeeRate estimateSmartFee(int confTarget, int *answerFoundAtTarget, const CTxMemPool &pool); - /** - * Return a priority estimate. - * DEPRECATED - * Returns -1 - */ - double estimatePriority(int confTarget); - /** * Estimate priority needed to get be included in a block within confTarget * blocks. diff --git a/src/policy/fees.cpp b/src/policy/fees.cpp --- a/src/policy/fees.cpp +++ b/src/policy/fees.cpp @@ -521,10 +521,6 @@ return CFeeRate(Amount(int64_t(median))); } -double CBlockPolicyEstimator::estimatePriority(int confTarget) { - return -1; -} - double CBlockPolicyEstimator::estimateSmartPriority(int confTarget, int *answerFoundAtTarget, const CTxMemPool &pool) { diff --git a/src/rpc/mining.cpp b/src/rpc/mining.cpp --- a/src/rpc/mining.cpp +++ b/src/rpc/mining.cpp @@ -924,36 +924,6 @@ return ValueFromAmount(feeRate.GetFeePerK()); } -static UniValue estimatepriority(const Config &config, - const JSONRPCRequest &request) { - if (request.fHelp || request.params.size() != 1) { - throw std::runtime_error( - "estimatepriority nblocks\n" - "\nDEPRECATED. Estimates the approximate priority " - "a zero-fee transaction needs to begin\n" - "confirmation within nblocks blocks.\n" - "\nArguments:\n" - "1. nblocks (numeric, required)\n" - "\nResult:\n" - "n (numeric) estimated priority\n" - "\n" - "A negative value is returned if not enough " - "transactions and blocks\n" - "have been observed to make an estimate.\n" - "\nExample:\n" + - HelpExampleCli("estimatepriority", "6")); - } - - RPCTypeCheck(request.params, {UniValue::VNUM}); - - int nBlocks = request.params[0].get_int(); - if (nBlocks < 1) { - nBlocks = 1; - } - - return mempool.estimatePriority(nBlocks); -} - static UniValue estimatesmartfee(const Config &config, const JSONRPCRequest &request) { if (request.fHelp || request.params.size() != 1) { @@ -1054,7 +1024,6 @@ {"generating", "generatetoaddress", generatetoaddress, true, {"nblocks", "address", "maxtries"}}, {"util", "estimatefee", estimatefee, true, {"nblocks"}}, - {"util", "estimatepriority", estimatepriority, true, {"nblocks"}}, {"util", "estimatesmartfee", estimatesmartfee, true, {"nblocks"}}, {"util", "estimatesmartpriority", estimatesmartpriority, true, {"nblocks"}}, }; diff --git a/src/txmempool.h b/src/txmempool.h --- a/src/txmempool.h +++ b/src/txmempool.h @@ -735,9 +735,6 @@ double estimateSmartPriority(int nBlocks, int *answerFoundAtBlocks = nullptr) const; - /** Estimate priority needed to get into the next nBlocks */ - double estimatePriority(int nBlocks) const; - /** Write/Read estimates to disk */ bool WriteFeeEstimates(CAutoFile &fileout) const; bool ReadFeeEstimates(CAutoFile &filein); diff --git a/src/txmempool.cpp b/src/txmempool.cpp --- a/src/txmempool.cpp +++ b/src/txmempool.cpp @@ -941,10 +941,6 @@ return minerPolicyEstimator->estimateSmartFee(nBlocks, answerFoundAtBlocks, *this); } -double CTxMemPool::estimatePriority(int nBlocks) const { - LOCK(cs); - return minerPolicyEstimator->estimatePriority(nBlocks); -} double CTxMemPool::estimateSmartPriority(int nBlocks, int *answerFoundAtBlocks) const { LOCK(cs);