lnd/contractcourt
Olaoluwa Osuntokun 5a28582719
contractcourt: only supplement resolvers if channel has historical state
In this commit, we fix a bug that would cause newly updated nodes to be
unable to start up, if they have an older channel that was closed before
we started to store all the historical state for each channel.

The issue is that we started to write the complete state to disk, but
newer channels don't have it, so when we try to supplement the
resolvers, we run into this error.

Ultimately, we only need this new supplemented information for script
enforcement channels. Ideally we would instead check the channel type
there instead, but it doesn't appear to be available in this context as
is, without further changes.

Fixes https://github.com/lightningnetwork/lnd/issues/6001.
2021-11-24 14:38:56 +01:00
..
anchor_resolver.go contractcourt: handle sweeping script-enforced leased channel outputs 2021-10-19 18:30:37 -07:00
breacharbiter_test.go lnwallet: support transactions and scripts for new commitment type 2021-10-19 18:30:32 -07:00
breacharbiter.go multi: move all channelstate operations to ChannelStateDB 2021-09-29 17:00:03 +02:00
briefcase_test.go kvdb: move channeldb/kvdb to top level 2021-05-07 14:18:56 +02:00
briefcase.go contractcourt: add docs for state transition paths 2021-09-23 13:22:34 +08:00
chain_arbitrator_test.go multi: move all channelstate operations to ChannelStateDB 2021-09-29 17:00:03 +02:00
chain_arbitrator.go contractcourt: handle sweeping script-enforced leased channel outputs 2021-10-19 18:30:37 -07:00
chain_watcher_test.go contractcourt/chainwatcher test: add test cases for future force close 2020-12-03 08:01:08 +01:00
chain_watcher.go lnwallet: support transactions and scripts for new commitment type 2021-10-19 18:30:32 -07:00
channel_arbitrator_test.go contractcourt: handle sweeping script-enforced leased channel outputs 2021-10-19 18:30:37 -07:00
channel_arbitrator.go contractcourt: only supplement resolvers if channel has historical state 2021-11-24 14:38:56 +01:00
commit_sweep_resolver_test.go contractcourt: test commitment deadline logic 2021-06-29 20:25:47 +08:00
commit_sweep_resolver.go contractcourt: handle sweeping script-enforced leased channel outputs 2021-10-19 18:30:37 -07:00
contract_resolvers.go contractcourt: handle sweeping script-enforced leased channel outputs 2021-10-19 18:30:37 -07:00
htlc_incoming_contest_resolver.go contractcourt: handle sweeping script-enforced leased channel outputs 2021-10-19 18:30:37 -07:00
htlc_incoming_resolver_test.go kvdb: move channeldb/kvdb to top level 2021-05-07 14:18:56 +02:00
htlc_outgoing_contest_resolver_test.go kvdb: move channeldb/kvdb to top level 2021-05-07 14:18:56 +02:00
htlc_outgoing_contest_resolver.go contractcourt: handle sweeping script-enforced leased channel outputs 2021-10-19 18:30:37 -07:00
htlc_success_resolver_test.go kvdb: move channeldb/kvdb to top level 2021-05-07 14:18:56 +02:00
htlc_success_resolver.go contractcourt: handle sweeping script-enforced leased channel outputs 2021-10-19 18:30:37 -07:00
htlc_timeout_resolver_test.go kvdb: move channeldb/kvdb to top level 2021-05-07 14:18:56 +02:00
htlc_timeout_resolver.go contractcourt: handle sweeping script-enforced leased channel outputs 2021-10-19 18:30:37 -07:00
interfaces.go cnct: resolve anchors post-confirmation 2020-03-18 12:27:01 +01:00
log.go multi: move breach arbiter and utxo nursery into contractcourt package 2021-09-27 19:10:31 -07:00
mock_registry_test.go multi: replace htlcResolution with an interface 2020-02-06 19:41:36 +02:00
nursery_store_test.go multi: move breach arbiter and utxo nursery into contractcourt package 2021-09-27 19:10:31 -07:00
nursery_store.go multi: move breach arbiter and utxo nursery into contractcourt package 2021-09-27 19:10:31 -07:00
setup_test.go channeldb/test: test with postgres 2021-10-29 10:54:44 +02:00
utils_test.go multi: move all channelstate operations to ChannelStateDB 2021-09-29 17:00:03 +02:00
utxonursery_test.go multi: move breach arbiter and utxo nursery into contractcourt package 2021-09-27 19:10:31 -07:00
utxonursery.go multi: move breach arbiter and utxo nursery into contractcourt package 2021-09-27 19:10:31 -07:00