sweep: handle missing inputs during fee bumping
This commit handles the case when the input is missing during the RBF process, which could happen when the bumped tx has inputs being spent by a third party. Normally we should be able to catch the spend early via the spending notification and never attempt to fee bump the record. However, due to the possible race between block notification and spend notification, this cannot be guaranteed. Thus, we need to handle the case during the RBF when seeing a `ErrMissingInputs`, which can only happen when the inputs are spent by others.
This commit is contained in:
2 files changed
+78
-1
No files matched your search
@@ -108,7 +108,7 @@ func (c *anchorResolver) Resolve() (ContractResolver, error) {
|
||||
|
||||
// Anchor was swept by someone else. This is possible after the
|
||||
// 16 block csv lock.
|
||||
case sweep.ErrRemoteSpend:
|
||||
case sweep.ErrRemoteSpend, sweep.ErrInputMissing:
|
||||
c.log.Warnf("our anchor spent by someone else")
|
||||
outcome = channeldb.ResolverOutcomeUnclaimed
|
||||
|
||||
|
||||
Reference in new issue
Block a user