From bfcf0830ff6599e48c58db2982831a184c72b963 Mon Sep 17 00:00:00 2001 From: eugene Date: Wed, 3 Aug 2022 14:58:05 -0400 Subject: [PATCH 1/2] htlcswitch: use ticker.New instead of NewForce for test link NewForce's Pause method doesn't reset the ticker, so a test flake would occur in TestChannelLinkCancelFullCommitment where PendingCommitTicker.Pause() was called, but the underlying timer was still ticking. When PendingCommitTicker.Resume() was called, an unlucky Ticks() call could end up firing, leading to the link being shut down. --- htlcswitch/test_utils.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htlcswitch/test_utils.go b/htlcswitch/test_utils.go index 7cda5d97a..a4868c12f 100644 --- a/htlcswitch/test_utils.go +++ b/htlcswitch/test_utils.go @@ -1166,7 +1166,7 @@ func (h *hopNetwork) createChannelLink(server, peer *mockServer, BatchSize: 10, BatchTicker: ticker.NewForce(testBatchTimeout), FwdPkgGCTicker: ticker.NewForce(fwdPkgTimeout), - PendingCommitTicker: ticker.NewForce(2 * time.Minute), + PendingCommitTicker: ticker.New(2 * time.Minute), MinFeeUpdateTimeout: minFeeUpdateTimeout, MaxFeeUpdateTimeout: maxFeeUpdateTimeout, OnChannelFailure: func(lnwire.ChannelID, lnwire.ShortChannelID, LinkFailureError) {}, From 07d924ea343b48eb49e27a0d90ff224c610bd7fd Mon Sep 17 00:00:00 2001 From: eugene Date: Wed, 21 Sep 2022 15:44:54 -0400 Subject: [PATCH 2/2] release-notes: update for 0.16.0 --- docs/release-notes/release-notes-0.16.0.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/release-notes/release-notes-0.16.0.md b/docs/release-notes/release-notes-0.16.0.md index 4add94242..f9fda7028 100644 --- a/docs/release-notes/release-notes-0.16.0.md +++ b/docs/release-notes/release-notes-0.16.0.md @@ -42,6 +42,9 @@ minimum version needed to build the project. ## Misc +* [Fixed a flake in the TestChannelLinkCancelFullCommitment unit + test](https://github.com/lightningnetwork/lnd/pull/6792). + * [Fixed error typo](https://github.com/lightningnetwork/lnd/pull/6659). * [The macaroon key store implementation was refactored to be more generally @@ -98,6 +101,7 @@ minimum version needed to build the project. * Daniel McNally * Elle Mouton * ErikEk +* Eugene Siegel * hieblmi * Jesse de Wit * Matt Morehouse