Commit accbb97
chanmon_consistency: handle claimed payments that lose timeout race
When an HTLC timeout on-chain beats the receiver's claim, the sender
gets ProbeFailed/PaymentFailed instead of PaymentSent. The receiver
still saw PaymentClaimable and called claim_funds, so the payment hash
was added to claimed_payment_hashes. The end-of-run assertion then
fails because it expects every claimed payment to have a corresponding
PaymentSent at the sender.
Fix this by removing the payment hash from claimed_payment_hashes when
we see HTLCHandlingFailed with a Receive failure type, which indicates
the claim did not succeed.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent 593ca88 commit accbb97
1 file changed
Lines changed: 11 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
30 | 29 | | |
| 30 | + | |
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| |||
2007 | 2007 | | |
2008 | 2008 | | |
2009 | 2009 | | |
| 2010 | + | |
| 2011 | + | |
| 2012 | + | |
| 2013 | + | |
| 2014 | + | |
| 2015 | + | |
| 2016 | + | |
| 2017 | + | |
| 2018 | + | |
| 2019 | + | |
2010 | 2020 | | |
2011 | 2021 | | |
2012 | 2022 | | |
| |||
0 commit comments