Lower strictness of pending monitor update while awaiting tx_signatures#4748
Lower strictness of pending monitor update while awaiting tx_signatures#4748wpaulino wants to merge 1 commit into
Conversation
We previously assumed that no monitor update should ever be pending when receiving `tx_signatures` while quiescent, with the exception of the `RenegotiatedFunding` variant. This was a bit too strict, as we did not consider that if an HTLC was sent via the same channel, its preimage could be received from upstream leading to a monitor update to durably persist it. This commit ensures that if the recipient of a `tx_signatures` has not yet echoed theirs back, and it is awaiting a monitor update completion, then the pending monitor update must be of the `RenegotiatedFunding` variant. If the pending monitor update is of another variant, then we must remain quiescent with no pending updates available to send until after the `tx_signatures` exchange.
|
👋 Thanks for assigning @jkczyz as a reviewer! |
|
I've completed a thorough review of all hunks in this PR. No issues found. I examined the core logic changes and verified they are internally consistent:
One area worth a maintainer's eye (not a defect I can demonstrate): the retained |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4748 +/- ##
==========================================
+ Coverage 84.55% 86.95% +2.40%
==========================================
Files 137 161 +24
Lines 77617 111632 +34015
Branches 77617 111632 +34015
==========================================
+ Hits 65627 97073 +31446
- Misses 9948 12055 +2107
- Partials 2042 2504 +462
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
We previously assumed that no monitor update should ever be pending when receiving
tx_signatureswhile quiescent, with the exception of theRenegotiatedFundingvariant. This was a bit too strict, as we did not consider that if an HTLC was sent via the same channel, its preimage could be received from upstream leading to a monitor update to durably persist it.This commit ensures that if the recipient of a
tx_signatureshas not yet echoed theirs back, and it is awaiting a monitor update completion, then the pending monitor update must be of theRenegotiatedFundingvariant. If the pending monitor update is of another variant, then we must remain quiescent with no pending updates available to send until after thetx_signaturesexchange.Fixes #4729.