Skip to content

Commit

Permalink
Merge #14023: Remove accounts rpcs
Browse files Browse the repository at this point in the history
Summary:
bb08423d5ca866d4a139a3b57ff110d818d08b32 [doc] Add release notes for 'account' API removal (John Newbery)
1f4b865e57b4567270b1586bb1f348ab9106485d [wallet] Re-sort wallet RPC commands (John Newbery)
f0dc850bf698f7377797d7d68365d4fc79b0221c [wallet] Remove wallet account RPCs (John Newbery)

Pull request description:

  This is the first part of #13825. It simply removes the RPC methods and tests.

  #13825 touches lots of files and will require frequent rebasing.

  Breaking it down for easier reviewing and fewer rebases.

Tree-SHA512: d29af8e7a035e4484e6b9bb56cb86592be0ec112d8ba4ce19c15d15366ff3086e89e99fca26b90c9d66f6d3e06894486d0f29948df0bb7dcb1e2c49c6887a85a

Backport of Core [[bitcoin/bitcoin#14023 | PR14023]]

Test Plan:
  make check
  ninja check
  ninja check-functional
  ./bitcoind
  ./bitcoin-cli help
Verify the account rpcs were removed.
  ./bitcoin-cli help sendmany
Verify the change to `sendmany` help text.

Reviewers: O1 Bitcoin ABC, #bitcoin_abc, Fabien

Reviewed By: O1 Bitcoin ABC, #bitcoin_abc, Fabien

Subscribers: jasonbcox, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D5316
  • Loading branch information
laanwj authored and Nico Guiton committed Mar 5, 2020
1 parent 7ff1309 commit 5f7aec6
Show file tree
Hide file tree
Showing 10 changed files with 130 additions and 1,337 deletions.
7 changes: 7 additions & 0 deletions doc/release-notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,10 @@ Bitcoin ABC version 0.21.2 is now available from:
<https://download.bitcoinabc.org/0.21.2/>

This release includes the following features and fixes:
Account API removed
------------------
- The 'account' API was deprecated in v0.20.6 and has been fully removed in v0.21
- The 'label' API was introduced in v0.20.6 as a replacement for accounts.

- See the release notes from v0.20.6 for a full description of the changes from the
'account' API to the 'label' API.
1 change: 0 additions & 1 deletion src/Makefile.test.include
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,6 @@ endif

if ENABLE_WALLET
BITCOIN_TESTS += \
wallet/test/accounting_tests.cpp \
wallet/test/db_tests.cpp \
wallet/test/psbt_wallet_tests.cpp \
wallet/test/wallet_tests.cpp \
Expand Down
10 changes: 0 additions & 10 deletions src/rpc/client.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,11 @@ static const CRPCConvertParam vRPCConvertParams[] = {
{"settxfee", 0, "amount"},
{"sethdseed", 0, "newkeypool"},
{"getreceivedbyaddress", 1, "minconf"},
{"getreceivedbyaccount", 1, "minconf"},
{"getreceivedbylabel", 1, "minconf"},
{"listreceivedbyaddress", 0, "minconf"},
{"listreceivedbyaddress", 1, "include_empty"},
{"listreceivedbyaddress", 2, "include_watchonly"},
{"listreceivedbyaddress", 3, "address_filter"},
{"listreceivedbyaccount", 0, "minconf"},
{"listreceivedbyaccount", 1, "include_empty"},
{"listreceivedbyaccount", 2, "include_watchonly"},
{"listreceivedbylabel", 0, "minconf"},
{"listreceivedbylabel", 1, "include_empty"},
{"listreceivedbylabel", 2, "include_watchonly"},
Expand All @@ -57,15 +53,9 @@ static const CRPCConvertParam vRPCConvertParams[] = {
{"waitforblockheight", 1, "timeout"},
{"waitforblock", 1, "timeout"},
{"waitfornewblock", 0, "timeout"},
{"move", 2, "amount"},
{"move", 3, "minconf"},
{"sendfrom", 2, "amount"},
{"sendfrom", 3, "minconf"},
{"listtransactions", 1, "count"},
{"listtransactions", 2, "skip"},
{"listtransactions", 3, "include_watchonly"},
{"listaccounts", 0, "minconf"},
{"listaccounts", 1, "include_watchonly"},
{"walletpassphrase", 1, "timeout"},
{"getblocktemplate", 0, "template_request"},
{"listsinceblock", 1, "target_confirmations"},
Expand Down
1 change: 0 additions & 1 deletion src/test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ if(BUILD_BITCOIN_WALLET)
../wallet/test/wallet_test_fixture.cpp
)
set(BITCOIN_WALLET_TESTS
../wallet/test/accounting_tests.cpp
../wallet/test/db_tests.cpp
../wallet/test/coinselector_tests.cpp
../wallet/test/init_tests.cpp
Expand Down
2 changes: 1 addition & 1 deletion src/wallet/rpcdump.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1429,7 +1429,7 @@ UniValue importmulti(const Config &config, const JSONRPCRequest &mainRequest) {
" \"keys\": [\"<key>\", ... ] , (array, optional) Array of strings giving private keys whose corresponding public keys must occur in the output or redeemscript\n"
" \"internal\": <true> , (boolean, optional, default: false) Stating whether matching outputs should be treated as not incoming payments aka change\n"
" \"watchonly\": <true> , (boolean, optional, default: false) Stating whether matching outputs should be considered watched even when they're not spendable, only allowed if keys are empty\n"
" \"label\": <label> , (string, optional, default: '') Label to assign to the address (aka account name, for now), only allowed with internal=false\n"
" \"label\": <label> , (string, optional, default: '') Label to assign to the address, only allowed with internal=false\n"
" }\n"
" ,...\n"
" ]\n"
Expand Down
Loading

0 comments on commit 5f7aec6

Please sign in to comment.