Avoid generating redundant claims after initial confirmation
authorWilmer Paulino <wilmer.paulino@gmail.com>
Wed, 21 Sep 2022 19:54:28 +0000 (12:54 -0700)
committerWilmer Paulino <wilmer.paulino@gmail.com>
Wed, 2 Nov 2022 17:07:45 +0000 (10:07 -0700)
commita0891368eee2fc5d5735de6caff3420211b0861b
treee48e7dfee90452f48813bebb655e2e0c21a47ca7
parent6957fb63f97546f65f590f191b4c3f181fb62ec7
Avoid generating redundant claims after initial confirmation

These claims will never be valid as a previous claim has already
confirmed. If a previous claim is reorged out of the chain, a new claim
will be generated bypassing the new behavior.

While this doesn't change much for our existing transaction-based
claims, as broadcasting an already confirmed transaction acts as a NOP,
it prevents us from yielding redundant event-based claims, which will be
introduced as part of the anchors patchset.
lightning/src/chain/onchaintx.rs
lightning/src/ln/functional_tests.rs