From 82cc96dd92acb572206d59a5aba27e2e5a96a0ec Mon Sep 17 00:00:00 2001 From: yyforyongyu Date: Mon, 6 Nov 2023 17:22:52 +0800 Subject: [PATCH] TODO:routing: conditionally fail payments during startup --- routing/router.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/routing/router.go b/routing/router.go index 4ab43203c3..4aaed6ddf6 100644 --- a/routing/router.go +++ b/routing/router.go @@ -639,6 +639,10 @@ func (r *ChannelRouter) Start() error { // If any payments are still in flight, we resume, to make sure their // results are properly handled. + // + // TODO(yy): check the HTLCs here, if there's no settled HTLCs, and the + // network results of the rest cannot be found, we can fail the payment + // here. payments, err := r.cfg.Control.FetchInFlightPayments() if err != nil { return err