diff --git a/itest/lnd_channel_backup_test.go b/itest/lnd_channel_backup_test.go index ea04a139a6..8327ca6467 100644 --- a/itest/lnd_channel_backup_test.go +++ b/itest/lnd_channel_backup_test.go @@ -107,13 +107,6 @@ func newChanRestoreScenario(ht *lntest.HarnessTest, ct lnrpc.CommitmentType, // with a portion pushed. ht.ConnectNodes(dave, carol) - // If the commitment type is taproot, then the channel must also be - // private. - var privateChan bool - if ct == lnrpc.CommitmentType_SIMPLE_TAPROOT { - privateChan = true - } - return &chanRestoreScenario{ carol: carol, dave: dave, @@ -124,7 +117,6 @@ func newChanRestoreScenario(ht *lntest.HarnessTest, ct lnrpc.CommitmentType, PushAmt: pushAmt, ZeroConf: zeroConf, CommitmentType: ct, - Private: privateChan, }, } } @@ -649,13 +641,6 @@ func runChanRestoreScenarioCommitTypes(ht *lntest.HarnessTest, multi, err := ioutil.ReadFile(backupFilePath) require.NoError(ht, err) - // If this was a zero conf taproot channel, then since it's private, - // we'll need to mine an extra block (framework won't mine extra blocks - // otherwise). - if ct == lnrpc.CommitmentType_SIMPLE_TAPROOT && zeroConf { - ht.MineBlocksAndAssertNumTxes(1, 1) - } - // Now that we have Dave's backup file, we'll create a new nodeRestorer // that we'll restore using the on-disk channels.backup. restoredNodeFunc := chanRestoreViaRPC( diff --git a/itest/lnd_channel_force_close_test.go b/itest/lnd_channel_force_close_test.go index 71950f81f9..e75419ce92 100644 --- a/itest/lnd_channel_force_close_test.go +++ b/itest/lnd_channel_force_close_test.go @@ -315,18 +315,8 @@ func channelForceClosureTest(ht *lntest.HarnessTest, carolBalResp := carol.RPC.WalletBalance() carolStartingBalance := carolBalResp.ConfirmedBalance - // If the channel is a taproot channel, then we'll need to create a - // private channel. - // - // TODO(roasbeef): lift after G175 - var privateChan bool - if channelType == lnrpc.CommitmentType_SIMPLE_TAPROOT { - privateChan = true - } - chanPoint := ht.OpenChannel( alice, carol, lntest.OpenChannelParams{ - Private: privateChan, Amt: chanAmt, PushAmt: pushAmt, CommitmentType: channelType, diff --git a/itest/lnd_funding_test.go b/itest/lnd_funding_test.go index e280494171..5b41702008 100644 --- a/itest/lnd_funding_test.go +++ b/itest/lnd_funding_test.go @@ -60,16 +60,6 @@ func testBasicChannelFunding(ht *lntest.HarnessTest) { // connected to the funding flow can properly be executed. ht.EnsureConnected(carol, dave) - var privateChan bool - - // If this is to be a taproot channel type, then it needs to be - // private, otherwise it'll be rejected by Dave. - // - // TODO(roasbeef): lift after gossip 1.75 - if carolCommitType == lnrpc.CommitmentType_SIMPLE_TAPROOT { - privateChan = true - } - // If carol wants taproot, but dave wants something // else, then we'll assert that the channel negotiation // attempt fails. @@ -81,7 +71,6 @@ func testBasicChannelFunding(ht *lntest.HarnessTest) { amt := funding.MaxBtcFundingAmount ht.OpenChannelAssertErr( carol, dave, lntest.OpenChannelParams{ - Private: privateChan, Amt: amt, CommitmentType: carolCommitType, }, expectedErr, @@ -91,7 +80,7 @@ func testBasicChannelFunding(ht *lntest.HarnessTest) { } carolChan, daveChan, closeChan := basicChannelFundingTest( - ht, carol, dave, nil, privateChan, &carolCommitType, + ht, carol, dave, nil, false, &carolCommitType, ) // Both nodes should report the same commitment diff --git a/itest/lnd_multi-hop_test.go b/itest/lnd_multi-hop_test.go index e85de046ae..a81776265f 100644 --- a/itest/lnd_multi-hop_test.go +++ b/itest/lnd_multi-hop_test.go @@ -193,13 +193,6 @@ func runMultiHopHtlcLocalTimeout(ht *lntest.HarnessTest, dustPayHash := ht.Random32Bytes() payHash := ht.Random32Bytes() - // If this is a taproot channel, then we'll need to make some manual - // route hints so Alice can actually find a route. - var routeHints []*lnrpc.RouteHint - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - routeHints = makeRouteHints(bob, carol, zeroConf) - } - alice.RPC.SendPayment(&routerrpc.SendPaymentRequest{ Dest: carolPubKey, Amt: int64(dustHtlcAmt), @@ -207,7 +200,6 @@ func runMultiHopHtlcLocalTimeout(ht *lntest.HarnessTest, FinalCltvDelta: finalCltvDelta, TimeoutSeconds: 60, FeeLimitMsat: noFeeLimitMsat, - RouteHints: routeHints, }) alice.RPC.SendPayment(&routerrpc.SendPaymentRequest{ @@ -217,7 +209,6 @@ func runMultiHopHtlcLocalTimeout(ht *lntest.HarnessTest, FinalCltvDelta: finalCltvDelta, TimeoutSeconds: 60, FeeLimitMsat: noFeeLimitMsat, - RouteHints: routeHints, }) // Verify that all nodes in the path now have two HTLC's with the @@ -359,13 +350,6 @@ func runMultiHopReceiverChainClaim(ht *lntest.HarnessTest, ht, alice, bob, false, c, zeroConf, ) - // If this is a taproot channel, then we'll need to make some manual - // route hints so Alice can actually find a route. - var routeHints []*lnrpc.RouteHint - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - routeHints = makeRouteHints(bob, carol, zeroConf) - } - // With the network active, we'll now add a new hodl invoice at Carol's // end. Make sure the cltv expiry delta is large enough, otherwise Bob // won't send out the outgoing htlc. @@ -377,7 +361,6 @@ func runMultiHopReceiverChainClaim(ht *lntest.HarnessTest, Value: invoiceAmt, CltvExpiry: finalCltvDelta, Hash: payHash[:], - RouteHints: routeHints, } carolInvoice := carol.RPC.AddHoldInvoice(invoiceReq) @@ -576,13 +559,6 @@ func runMultiHopLocalForceCloseOnChainHtlcTimeout(ht *lntest.HarnessTest, // opens up the base for out tests. const htlcAmt = btcutil.Amount(300_000) - // If this is a taproot channel, then we'll need to make some manual - // route hints so Alice can actually find a route. - var routeHints []*lnrpc.RouteHint - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - routeHints = makeRouteHints(bob, carol, zeroConf) - } - // We'll now send a single HTLC across our multi-hop network. carolPubKey := carol.PubKey[:] payHash := ht.Random32Bytes() @@ -593,7 +569,6 @@ func runMultiHopLocalForceCloseOnChainHtlcTimeout(ht *lntest.HarnessTest, FinalCltvDelta: finalCltvDelta, TimeoutSeconds: 60, FeeLimitMsat: noFeeLimitMsat, - RouteHints: routeHints, } alice.RPC.SendPayment(req) @@ -746,13 +721,6 @@ func runMultiHopRemoteForceCloseOnChainHtlcTimeout(ht *lntest.HarnessTest, // opens up the base for out tests. const htlcAmt = btcutil.Amount(30000) - // If this is a taproot channel, then we'll need to make some manual - // route hints so Alice can actually find a route. - var routeHints []*lnrpc.RouteHint - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - routeHints = makeRouteHints(bob, carol, zeroConf) - } - // We'll now send a single HTLC across our multi-hop network. var preimage lntypes.Preimage copy(preimage[:], ht.Random32Bytes()) @@ -761,7 +729,6 @@ func runMultiHopRemoteForceCloseOnChainHtlcTimeout(ht *lntest.HarnessTest, Value: int64(htlcAmt), CltvExpiry: finalCltvDelta, Hash: payHash[:], - RouteHints: routeHints, } carolInvoice := carol.RPC.AddHoldInvoice(invoiceReq) @@ -917,13 +884,6 @@ func runMultiHopHtlcLocalChainClaim(ht *lntest.HarnessTest, ht, alice, bob, false, c, zeroConf, ) - // If this is a taproot channel, then we'll need to make some manual - // route hints so Alice can actually find a route. - var routeHints []*lnrpc.RouteHint - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - routeHints = makeRouteHints(bob, carol, zeroConf) - } - // With the network active, we'll now add a new hodl invoice at Carol's // end. Make sure the cltv expiry delta is large enough, otherwise Bob // won't send out the outgoing htlc. @@ -935,7 +895,6 @@ func runMultiHopHtlcLocalChainClaim(ht *lntest.HarnessTest, Value: invoiceAmt, CltvExpiry: finalCltvDelta, Hash: payHash[:], - RouteHints: routeHints, } carolInvoice := carol.RPC.AddHoldInvoice(invoiceReq) @@ -1233,13 +1192,6 @@ func runMultiHopHtlcRemoteChainClaim(ht *lntest.HarnessTest, ht, alice, bob, false, c, zeroConf, ) - // If this is a taproot channel, then we'll need to make some manual - // route hints so Alice can actually find a route. - var routeHints []*lnrpc.RouteHint - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - routeHints = makeRouteHints(bob, carol, zeroConf) - } - // With the network active, we'll now add a new hodl invoice at Carol's // end. Make sure the cltv expiry delta is large enough, otherwise Bob // won't send out the outgoing htlc. @@ -1251,7 +1203,6 @@ func runMultiHopHtlcRemoteChainClaim(ht *lntest.HarnessTest, Value: invoiceAmt, CltvExpiry: finalCltvDelta, Hash: payHash[:], - RouteHints: routeHints, } carolInvoice := carol.RPC.AddHoldInvoice(invoiceReq) @@ -1520,23 +1471,11 @@ func runMultiHopHtlcAggregation(ht *lntest.HarnessTest, ht, alice, bob, false, c, zeroConf, ) - // If this is a taproot channel, then we'll need to make some manual - // route hints so Alice+Carol can actually find a route. - var ( - carolRouteHints []*lnrpc.RouteHint - aliceRouteHints []*lnrpc.RouteHint - ) - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - carolRouteHints = makeRouteHints(bob, carol, zeroConf) - aliceRouteHints = makeRouteHints(bob, alice, zeroConf) - } - // To ensure we have capacity in both directions of the route, we'll // make a fairly large payment Alice->Carol and settle it. const reBalanceAmt = 500_000 invoice := &lnrpc.Invoice{ - Value: reBalanceAmt, - RouteHints: carolRouteHints, + Value: reBalanceAmt, } resp := carol.RPC.AddInvoice(invoice) ht.CompletePaymentRequests(alice, []string{resp.PaymentRequest}) @@ -1568,7 +1507,6 @@ func runMultiHopHtlcAggregation(ht *lntest.HarnessTest, Value: invoiceAmt, CltvExpiry: finalCltvDelta, Hash: payHash[:], - RouteHints: carolRouteHints, } carolInvoice := carol.RPC.AddHoldInvoice(invoiceReq) @@ -1590,7 +1528,6 @@ func runMultiHopHtlcAggregation(ht *lntest.HarnessTest, Value: invoiceAmt, CltvExpiry: thawHeightDelta - 4, Hash: payHash[:], - RouteHints: aliceRouteHints, } aliceInvoice := alice.RPC.AddHoldInvoice(invoiceReq) @@ -1956,13 +1893,7 @@ func createThreeHopNetwork(ht *lntest.HarnessTest, ) } - var privateChan bool - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - privateChan = true - } - aliceParams := lntest.OpenChannelParams{ - Private: privateChan, Amt: chanAmt, CommitmentType: c, FundingShim: aliceFundingShim, @@ -1987,7 +1918,6 @@ func createThreeHopNetwork(ht *lntest.HarnessTest, // Prepare params for Bob. bobParams := lntest.OpenChannelParams{ Amt: chanAmt, - Private: privateChan, CommitmentType: c, FundingShim: bobFundingShim, ZeroConf: zeroConf, @@ -2032,18 +1962,8 @@ func createThreeHopNetwork(ht *lntest.HarnessTest, } // Make sure alice and carol know each other's channels. - // - // We'll only do this though if it wasn't a private channel we opened - // earlier. - if !privateChan { - ht.AssertTopologyChannelOpen(alice, bobChanPoint) - ht.AssertTopologyChannelOpen(carol, aliceChanPoint) - } else { - // Otherwise, we want to wait for all the channels to be shown - // as active before we proceed. - ht.AssertChannelExists(alice, aliceChanPoint) - ht.AssertChannelExists(carol, bobChanPoint) - } + ht.AssertTopologyChannelOpen(alice, bobChanPoint) + ht.AssertTopologyChannelOpen(carol, aliceChanPoint) return aliceChanPoint, bobChanPoint, carol } @@ -2071,13 +1991,6 @@ func runExtraPreimageFromRemoteCommit(ht *lntest.HarnessTest, ht, alice, bob, false, c, zeroConf, ) - // If this is a taproot channel, then we'll need to make some manual - // route hints so Alice can actually find a route. - var routeHints []*lnrpc.RouteHint - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - routeHints = makeRouteHints(bob, carol, zeroConf) - } - // With the network active, we'll now add a new hodl invoice at Carol's // end. Make sure the cltv expiry delta is large enough, otherwise Bob // won't send out the outgoing htlc. @@ -2087,7 +2000,6 @@ func runExtraPreimageFromRemoteCommit(ht *lntest.HarnessTest, Value: 100_000, CltvExpiry: finalCltvDelta, Hash: payHash[:], - RouteHints: routeHints, } eveInvoice := carol.RPC.AddHoldInvoice(invoiceReq) @@ -2226,13 +2138,6 @@ func runExtraPreimageFromLocalCommit(ht *lntest.HarnessTest, ht, alice, bob, false, c, zeroConf, ) - // If this is a taproot channel, then we'll need to make some manual - // route hints so Alice can actually find a route. - var routeHints []*lnrpc.RouteHint - if c == lnrpc.CommitmentType_SIMPLE_TAPROOT { - routeHints = makeRouteHints(bob, carol, zeroConf) - } - // With the network active, we'll now add a new hodl invoice at Carol's // end. Make sure the cltv expiry delta is large enough, otherwise Bob // won't send out the outgoing htlc. @@ -2242,7 +2147,6 @@ func runExtraPreimageFromLocalCommit(ht *lntest.HarnessTest, Value: 100_000, CltvExpiry: finalCltvDelta, Hash: payHash[:], - RouteHints: routeHints, } eveInvoice := carol.RPC.AddHoldInvoice(invoiceReq) diff --git a/itest/lnd_payment_test.go b/itest/lnd_payment_test.go index 28d499a5b0..34ea98c508 100644 --- a/itest/lnd_payment_test.go +++ b/itest/lnd_payment_test.go @@ -132,10 +132,6 @@ func testSendDirectPayment(ht *lntest.HarnessTest) { CommitmentType: ct, } - // Open private channel for taproot channels. - params.Private = ct == - lnrpc.CommitmentType_SIMPLE_TAPROOT - testSendPayment(st, params) }) } diff --git a/itest/lnd_psbt_test.go b/itest/lnd_psbt_test.go index 3bf1cfa04f..27787263ee 100644 --- a/itest/lnd_psbt_test.go +++ b/itest/lnd_psbt_test.go @@ -35,20 +35,14 @@ func testPsbtChanFunding(ht *lntest.HarnessTest) { testCases := []struct { name string commitmentType lnrpc.CommitmentType - private bool }{ { name: "anchors", commitmentType: lnrpc.CommitmentType_ANCHORS, - private: false, }, { name: "simple taproot", commitmentType: lnrpc.CommitmentType_SIMPLE_TAPROOT, - - // Set this to true once simple taproot channels can be - // announced to the network. - private: true, }, } @@ -76,7 +70,7 @@ func testPsbtChanFunding(ht *lntest.HarnessTest) { Name: tc.name, TestFunc: func(sst *lntest.HarnessTest) { runPsbtChanFunding( - sst, carol, dave, tc.private, + sst, carol, dave, false, tc.commitmentType, ) }, @@ -97,7 +91,7 @@ func testPsbtChanFunding(ht *lntest.HarnessTest) { Name: tc.name, TestFunc: func(sst *lntest.HarnessTest) { runPsbtChanFundingExternal( - sst, carol, dave, tc.private, + sst, carol, dave, false, tc.commitmentType, ) }, @@ -114,7 +108,7 @@ func testPsbtChanFunding(ht *lntest.HarnessTest) { Name: tc.name, TestFunc: func(sst *lntest.HarnessTest) { runPsbtChanFundingSingleStep( - sst, carol, dave, tc.private, + sst, carol, dave, false, tc.commitmentType, ) }, diff --git a/itest/lnd_revocation_test.go b/itest/lnd_revocation_test.go index 4350c92a2b..22917b36cb 100644 --- a/itest/lnd_revocation_test.go +++ b/itest/lnd_revocation_test.go @@ -54,12 +54,10 @@ func breachRetributionTestCase(ht *lntest.HarnessTest, // In order to test Carol's response to an uncooperative channel // closure by Bob, we'll first open up a channel between them with a // 0.5 BTC value. - privateChan := commitType == lnrpc.CommitmentType_SIMPLE_TAPROOT chanPoint := ht.OpenChannel( carol, bob, lntest.OpenChannelParams{ CommitmentType: commitType, Amt: chanAmt, - Private: privateChan, }, ) @@ -247,12 +245,10 @@ func revokedCloseRetributionZeroValueRemoteOutputCase(ht *lntest.HarnessTest, // In order to test Dave's response to an uncooperative channel // closure by Carol, we'll first open up a channel between them with a // 0.5 BTC value. - privateChan := commitType == lnrpc.CommitmentType_SIMPLE_TAPROOT chanPoint := ht.OpenChannel( dave, carol, lntest.OpenChannelParams{ CommitmentType: commitType, Amt: chanAmt, - Private: privateChan, }, ) @@ -434,12 +430,10 @@ func revokedCloseRetributionRemoteHodlCase(ht *lntest.HarnessTest, // In order to test Dave's response to an uncooperative channel closure // by Carol, we'll first open up a channel between them with a // funding.MaxBtcFundingAmount (2^24) satoshis value. - privateChan := commitType == lnrpc.CommitmentType_SIMPLE_TAPROOT chanPoint := ht.OpenChannel( dave, carol, lntest.OpenChannelParams{ Amt: chanAmt, PushAmt: pushAmt, - Private: privateChan, CommitmentType: commitType, }, )