Handle retrying sign_counterparty_commitment failures
authorMatt Corallo <git@bluematt.me>
Tue, 5 Sep 2023 22:06:53 +0000 (22:06 +0000)
committerChris Waterson <waterson@gmail.com>
Wed, 1 Nov 2023 22:24:14 +0000 (15:24 -0700)
commitf36afcbae33f6785daee1b5292f37c547e2cbf5d
tree3cc906cf614e7383464b6f9960909be4796d5d17
parent0e3f6b60297101d0a9d451bddf84197d69df6dda
Handle retrying sign_counterparty_commitment failures

If sign_counterparty_commitment fails (i.e. because the signer is
temporarily disconnected), this really indicates that we should
retry the message sending which required the signature later,
rather than force-closing the channel (which probably won't even
work if the signer is missing).

This commit adds initial retrying of failures, specifically
regenerating commitment updates, attempting to re-sign the
`CommitmentSigned` message, and sending it to our peers if we
succed.
lightning/src/ln/channel.rs
lightning/src/ln/channelmanager.rs