You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Properly provide PaymentPathSuccessful event for replay claims
When a payment was sent and ultimately completed through an
on-chain HTLC claim which we discover during startup, we
deliberately break the payment tracking logic to keep it around
forever, declining to send a `PaymentPathSuccessful` event but
ensuring that we don't constantly replay the claim on every
startup.
However, now that we now have logic to complete a claim by marking
it as completed in a `ChannelMonitor` and not replaying information
about the claim on every startup. Thus, we no longer need to take
the conservative stance and can correctly replay claims now,
generating `PaymentPathSuccessful` events and allowing the state to
be removed.
Backport of ba6528f
Fixed conflicts in:
* lightning/src/ln/channelmanager.rs
* lightning/src/ln/payment_tests.rs
Copy file name to clipboardExpand all lines: lightning/src/ln/channelmanager.rs
+1-9Lines changed: 1 addition & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -14154,20 +14154,12 @@ where
14154
14154
log_warn!(logger, "Missing counterparty node id in monitor when trying to re-claim a payment resolved on chain. This may lead to redundant payment claims on restart");
14155
14155
None
14156
14156
};
14157
-
// Note that we set `from_onchain` to "false" here,
14158
-
// deliberately keeping the pending payment around forever.
14159
-
// Given it should only occur when we have a channel we're
14160
-
// force-closing for being stale that's okay.
14161
-
// The alternative would be to wipe the state when claiming,
14162
-
// generating a `PaymentPathSuccessful` event but regenerating
14163
-
// it and the `PaymentSent` on every restart until the
0 commit comments