Skip to content

Commit 19983fc

Browse files
committed
tapchannel: add extra logging when we cancel incoming invoice HTLCs
In this commit, we add some extra logging for the case where we cancel incoming invoice HTLCs. This should make it easier to see exactly what's going on re the why/when here.
1 parent 8737847 commit 19983fc

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tapchannel/aux_invoice_manager.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,12 @@ func (s *AuxInvoiceManager) handleInvoiceAccept(ctx context.Context,
191191
//
192192
// TODO(george): Strict-forwarding could be configurable?
193193
if isAssetInvoice(req.Invoice, s) {
194+
iLog.Debugf("has no asset custom records, but " +
195+
"invoice requires assets, canceling HTLCs")
196+
194197
resp.CancelSet = true
198+
} else {
199+
iLog.Tracef("has no asset custom records, ignoring")
195200
}
196201

197202
return resp, nil
@@ -203,6 +208,9 @@ func (s *AuxInvoiceManager) handleInvoiceAccept(ctx context.Context,
203208
// Since we requested btc we should be receiving btc.
204209
resp.CancelSet = true
205210

211+
iLog.Debugf("has asset custom records, but invoice does not " +
212+
"require assets, canceling HTLCs")
213+
206214
return resp, nil
207215

208216
default:

0 commit comments

Comments
 (0)