Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
34d2574
lnwallet: add new helper functions to scale confirmations based on amt
Roasbeef Sep 4, 2025
ed0094c
server: use new FundingConfsForAmounts helper func
Roasbeef Sep 4, 2025
531cdd0
lnwallet: define helper func to coop close conf scaling
Roasbeef Sep 4, 2025
7c34188
lnwallet: add tests for new conf scaling helper funcs
Roasbeef Sep 4, 2025
33a26b5
peer+rpcserver: use new conf scaling for notifications
Roasbeef Sep 4, 2025
af7f343
lncfg: add new dev config option for scaling channel close confs
Roasbeef Oct 1, 2025
34db0ad
multi: add new ChannelCloseConfs param, thread thru as needed
Roasbeef Oct 1, 2025
11649bb
peer: send out a notification after the 1st conf, then wait for the rest
Roasbeef Oct 1, 2025
1354e8e
contractcourt: update close logic to handle re-orgs of depth n-1, whe…
Roasbeef Oct 1, 2025
86bd2ee
lntest: add new wait for conf helper method to ChainNotifier
Roasbeef Oct 1, 2025
5608bd5
contractcourt: add new chainWatcherTestHarness
Roasbeef Oct 1, 2025
f1a8a54
contractcourt: update existing chain watcher tests due to new logic
Roasbeef Oct 1, 2025
1b67863
contractcourt: add unit tests for rbf re-org cases
Roasbeef Oct 1, 2025
07c08bf
contractcourt: add generic close re-org tests
Roasbeef Oct 1, 2025
de3ed9c
itest: add new coop close rbf itest
Roasbeef Oct 1, 2025
80be53b
lnrpc/devrpc: add new TriggerSweep dev rpc command
Roasbeef Oct 11, 2025
1b95fdf
sweeper: implement TriggerSweep
Roasbeef Oct 11, 2025
b578431
lntest: add new utilities to wait for mempool/block inclusion, then t…
Roasbeef Oct 11, 2025
08ac7b6
itest: update itests to use new *WithSweep helper assertions
Roasbeef Oct 11, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions contractcourt/chain_arbitrator.go
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,12 @@ type ChainArbitratorConfig struct {
// AuxResolver is an optional interface that can be used to modify the
// way contracts are resolved.
AuxResolver fn.Option[lnwallet.AuxContractResolver]

// ChannelCloseConfs is an optional override for the number of
// confirmations required for channel closes. When set, this overrides
// the normal capacity-based scaling. This is only available in
// dev/integration builds for testing purposes.
ChannelCloseConfs fn.Option[uint32]
}

// ChainArbitrator is a sub-system that oversees the on-chain resolution of all
Expand Down Expand Up @@ -1138,6 +1144,7 @@ func (c *ChainArbitrator) WatchNewChannel(newChan *channeldb.OpenChannel) error
extractStateNumHint: lnwallet.GetStateNumHint,
auxLeafStore: c.cfg.AuxLeafStore,
auxResolver: c.cfg.AuxResolver,
chanCloseConfs: c.cfg.ChannelCloseConfs,
},
)
if err != nil {
Expand Down Expand Up @@ -1315,6 +1322,7 @@ func (c *ChainArbitrator) loadOpenChannels() error {
extractStateNumHint: lnwallet.GetStateNumHint,
auxLeafStore: c.cfg.AuxLeafStore,
auxResolver: c.cfg.AuxResolver,
chanCloseConfs: c.cfg.ChannelCloseConfs,
},
)
if err != nil {
Expand Down
Loading
Loading