Skip to content

Commit e6edb76

Browse files
committed
lightningd: fix failure message in waitsendpay with multi-part payments.
Bastien TEINTURIER <bastien@acinq.fr> writes: > One thing I noticed but didn't investigate much: after sending the two > payments, I tried using `waitsendpay` and it reported an error *208* > (*"Never attempted payment for > '98ee736d29d860948e436546a88b0cc84f267de8818531b0fdbe6ce3d080f22a'"*). > > I was expecting the result to be something like: "payment succeeded for > that payment hash" (the HTLCs were correctly settled). Indeed, if you waitsendpay without specifying a partid, you are waiting for 0, which may not exist. Clarify the error msg. Reported-by: @t-bast Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
1 parent 207ae69 commit e6edb76

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

lightningd/pay.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -627,7 +627,9 @@ static struct command_result *wait_payment(struct lightningd *ld,
627627
payment_hash, partid);
628628
if (!payment) {
629629
return command_fail(cmd, PAY_NO_SUCH_PAYMENT,
630-
"Never attempted payment for '%s'",
630+
"Never attempted payment part %"PRIu64
631+
" for '%s'",
632+
partid,
631633
type_to_string(tmpctx, struct sha256,
632634
payment_hash));
633635
}

0 commit comments

Comments
 (0)