Skip to content

Commit 7b13c64

Browse files
committed
Merge #15642: [rpc] Remove deprecated rpc warnings
947f73c [docs] remove reference to signrawtransaction in the developer docs. (John Newbery) 7b6616b [rpc] Remove deprecated functionality message from validateaddress help (John Newbery) 839c3f7 [rpc] Remove signrawtransaction warning (John Newbery) Pull request description: Removes some deprecated code from the RPCs: - signrawtransaction was deprecated in 0.17 and removed in 0.18. A warning message was left in place to advise users to use signrawtransactionwithwallet and signrawtransactionwithkey. That warning can now be removed. - validateaddress had some functionality deprecated in 0.17 and removed in 0.18. The help text for that functionality was not removed in 0.18 and can be removed now. Tree-SHA512: 981678a697954ff2c392752e5a183b4b12c4eb94f55766ee1aa97a70d300668237db8fc5748c2772869d0155ba4a93e38817887b98160ee972a6f6ee94e3f7d9
2 parents 6852059 + 947f73c commit 7b13c64

File tree

5 files changed

+2
-18
lines changed

5 files changed

+2
-18
lines changed

doc/developer-notes.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -952,8 +952,7 @@ A few guidelines for introducing and reviewing new RPC interfaces:
952952
from there.
953953
954954
- A RPC method must either be a wallet method or a non-wallet method. Do not
955-
introduce new methods such as `signrawtransaction` that differ in behavior
956-
based on presence of a wallet.
955+
introduce new methods that differ in behavior based on presence of a wallet.
957956
958957
- *Rationale*: as well as complicating the implementation and interfering
959958
with the introduction of multi-wallet, wallet and non-wallet code should be

src/qt/rpcconsole.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,6 @@ const QStringList historyFilter = QStringList()
6969
<< "importmulti"
7070
<< "sethdseed"
7171
<< "signmessagewithprivkey"
72-
<< "signrawtransaction"
7372
<< "signrawtransactionwithkey"
7473
<< "walletpassphrase"
7574
<< "walletpassphrasechange"

src/rpc/misc.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,7 @@ static UniValue validateaddress(const JSONRPCRequest& request)
3434
if (request.fHelp || request.params.size() != 1)
3535
throw std::runtime_error(
3636
RPCHelpMan{"validateaddress",
37-
"\nReturn information about the given bitcoin address.\n"
38-
"DEPRECATION WARNING: Parts of this command have been deprecated and moved to getaddressinfo. Clients must\n"
39-
"transition to using getaddressinfo to access this information before upgrading to v0.18. The following deprecated\n"
40-
"fields have moved to getaddressinfo and will only be shown here with -deprecatedrpc=validateaddress: ismine, iswatchonly,\n"
41-
"script, hex, pubkeys, sigsrequired, pubkey, addresses, embedded, iscompressed, account, timestamp, hdkeypath, kdmasterkeyid.\n",
37+
"\nReturn information about the given bitcoin address.\n",
4238
{
4339
{"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The bitcoin address to validate"},
4440
},

src/rpc/rawtransaction.cpp

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1021,14 +1021,6 @@ static UniValue signrawtransactionwithkey(const JSONRPCRequest& request)
10211021
return SignTransaction(*g_rpc_interfaces->chain, mtx, request.params[2], &keystore, true, request.params[3]);
10221022
}
10231023

1024-
UniValue signrawtransaction(const JSONRPCRequest& request)
1025-
{
1026-
// This method should be removed entirely in V0.19, along with the entries in the
1027-
// CRPCCommand table and rpc/client.cpp.
1028-
throw JSONRPCError(RPC_METHOD_DEPRECATED, "signrawtransaction was removed in v0.18.\n"
1029-
"Clients should transition to using signrawtransactionwithkey and signrawtransactionwithwallet");
1030-
}
1031-
10321024
static UniValue sendrawtransaction(const JSONRPCRequest& request)
10331025
{
10341026
if (request.fHelp || request.params.size() < 1 || request.params.size() > 2)
@@ -2078,7 +2070,6 @@ static const CRPCCommand commands[] =
20782070
{ "rawtransactions", "decodescript", &decodescript, {"hexstring"} },
20792071
{ "rawtransactions", "sendrawtransaction", &sendrawtransaction, {"hexstring","allowhighfees|maxfeerate"} },
20802072
{ "rawtransactions", "combinerawtransaction", &combinerawtransaction, {"txs"} },
2081-
{ "hidden", "signrawtransaction", &signrawtransaction, {"hexstring","prevtxs","privkeys","sighashtype"} },
20822073
{ "rawtransactions", "signrawtransactionwithkey", &signrawtransactionwithkey, {"hexstring","privkeys","prevtxs","sighashtype"} },
20832074
{ "rawtransactions", "testmempoolaccept", &testmempoolaccept, {"rawtxs","allowhighfees|maxfeerate"} },
20842075
{ "rawtransactions", "decodepsbt", &decodepsbt, {"psbt"} },

test/functional/rpc_signrawtransaction.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ class SignRawTransactionsTest(BitcoinTestFramework):
1515
def set_test_params(self):
1616
self.setup_clean_chain = True
1717
self.num_nodes = 2
18-
self.extra_args = [["-deprecatedrpc=signrawtransaction"], []]
1918

2019
def skip_test_if_missing_module(self):
2120
self.skip_if_no_wallet()

0 commit comments

Comments
 (0)