Skip to content

Commit 9c3cf5a

Browse files
committed
newaddr: don't include "address" field.
Signed-off-by: Rusty Russell <[email protected]> Changelog-Removed: JSON-RPC: `newaddr` no longer includes `address` field (deprecated in 0.7.1)
1 parent da4c2ca commit 9c3cf5a

File tree

2 files changed

+0
-11
lines changed

2 files changed

+0
-11
lines changed

tests/test_misc.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1771,14 +1771,6 @@ def test_newaddr(node_factory, chainparams):
17711771
assert both['bech32'].startswith(chainparams['bip173_prefix'])
17721772

17731773

1774-
def test_newaddr_deprecated(node_factory, chainparams):
1775-
l1 = node_factory.get_node(options={'allow-deprecated-apis': True})
1776-
p2sh = l1.rpc.newaddr('p2sh-segwit')
1777-
assert p2sh['address'].startswith(chainparams['p2sh_prefix'])
1778-
bech32 = l1.rpc.newaddr('bech32')
1779-
assert bech32['address'].startswith(chainparams['bip173_prefix'])
1780-
1781-
17821774
def test_bitcoind_fail_first(node_factory, bitcoind, executor):
17831775
"""Make sure we handle spurious bitcoin-cli failures during startup
17841776

wallet/walletrpc.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,9 +151,6 @@ static struct command_result *json_newaddr(struct command *cmd,
151151
}
152152

153153
response = json_stream_success(cmd);
154-
if (deprecated_apis && *addrtype != ADDR_ALL)
155-
json_add_string(response, "address",
156-
*addrtype & ADDR_BECH32 ? bech32 : p2sh);
157154
if (*addrtype & ADDR_BECH32)
158155
json_add_string(response, "bech32", bech32);
159156
if (*addrtype & ADDR_P2SH_SEGWIT)

0 commit comments

Comments
 (0)