diff --git a/.msggen.json b/.msggen.json index a642d7b07..7d64d8081 100644 --- a/.msggen.json +++ b/.msggen.json @@ -330,7 +330,6 @@ "NewaddrAddresstype": { "all": 2, "bech32": 0, - "p2sh-segwit": 1, "p2tr": 3 }, "PayStatus": { @@ -1562,7 +1561,6 @@ }, "NewaddrResponse": { "NewAddr.bech32": 1, - "NewAddr.p2sh-segwit": 2, "NewAddr.p2tr": 3 }, "OfferRecurrence": { @@ -5621,10 +5619,6 @@ "added": "pre-v0.10.1", "deprecated": false }, - "NewAddr.p2sh-segwit": { - "added": "pre-v0.10.1", - "deprecated": "v23.02" - }, "NewAddr.p2tr": { "added": "v23.08", "deprecated": false diff --git a/README.md b/README.md index b8648d733..794d1a3db 100644 --- a/README.md +++ b/README.md @@ -123,11 +123,11 @@ lightning-cli newaddr `lightningd` will register the funds once the transaction is confirmed. -You may need to generate a p2sh-segwit address if the faucet does not support bech32: +Alternatively you can generate a taproot address should your source of funds support it: ```bash -# Return a p2sh-segwit address -lightning-cli newaddr p2sh-segwit +# Return a taproot address +lightning-cli newaddr p2tr ``` Confirm `lightningd` got funds by: diff --git a/cln-rpc/src/model.rs b/cln-rpc/src/model.rs index c1bed7e13..1009e0424 100644 Binary files a/cln-rpc/src/model.rs and b/cln-rpc/src/model.rs differ diff --git a/contrib/pyln-testing/pyln/testing/grpc.py b/contrib/pyln-testing/pyln/testing/grpc.py index d854f25bd..0b39878e3 100644 --- a/contrib/pyln-testing/pyln/testing/grpc.py +++ b/contrib/pyln-testing/pyln/testing/grpc.py @@ -133,11 +133,6 @@ class LightningGrpc(object): payload = clnpb.NewaddrRequest(addresstype=atype) res = grpc2py.newaddr2py(self.stub.NewAddr(payload)) - # Need to remap the bloody spelling of p2sh-segwit to match - # addresstype. - if 'p2sh_segwit' in res: - res['p2sh-segwit'] = res['p2sh_segwit'] - del res['p2sh_segwit'] return res def listfunds(self, spent=None): diff --git a/doc/beginners-guide/opening-channels.md b/doc/beginners-guide/opening-channels.md index 4341e2188..8c7b87b36 100644 --- a/doc/beginners-guide/opening-channels.md +++ b/doc/beginners-guide/opening-channels.md @@ -16,11 +16,11 @@ lightning-cli newaddr `lightningd` will register the funds once the transaction is confirmed. -You may need to generate a p2sh-segwit address if the faucet does not support bech32: +Alternatively you can generate a taproot address should your source of funds support it: ```shell -# Return a p2sh-segwit address -lightning-cli newaddr p2sh-segwit +# Return a taproot address +lightning-cli newaddr p2tr ``` diff --git a/doc/lightningd.8.md b/doc/lightningd.8.md index af4af6b79..41cf77051 100644 --- a/doc/lightningd.8.md +++ b/doc/lightningd.8.md @@ -103,11 +103,10 @@ elided, specify it if you selected your own *lightning-dir*): $ lightning-cli newaddr -This will provide a native SegWit bech32 address. In case all your money -is in services that do not support native SegWit and have to use -P2SH-wrapped addresses, instead use: +This will provide a native SegWit bech32 address. Alternatively you can +generate a taproot address with: - $ lightning-cli newaddr p2sh-segwit + $ lightning-cli newaddr p2tr Transfer a small amount of onchain funds to the given address. Check the status of all your funds (onchain and on-Lightning) via diff --git a/tests/test_misc.py b/tests/test_misc.py index d66ee4b5a..8979b0532 100644 --- a/tests/test_misc.py +++ b/tests/test_misc.py @@ -2019,6 +2019,7 @@ def test_newaddr(node_factory, chainparams): both = l1.rpc.newaddr('all') assert 'p2sh-segwit' not in both assert both['bech32'].startswith(chainparams['bip173_prefix']) + assert both['p2tr'].startswith(chainparams['bip173_prefix']) def test_bitcoind_fail_first(node_factory, bitcoind):