mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-18 05:12:45 +01:00
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>
This commit is contained in:
parent
edab0df611
commit
ec1505199e
@ -627,7 +627,9 @@ static struct command_result *wait_payment(struct lightningd *ld,
|
|||||||
payment_hash, partid);
|
payment_hash, partid);
|
||||||
if (!payment) {
|
if (!payment) {
|
||||||
return command_fail(cmd, PAY_NO_SUCH_PAYMENT,
|
return command_fail(cmd, PAY_NO_SUCH_PAYMENT,
|
||||||
"Never attempted payment for '%s'",
|
"Never attempted payment part %"PRIu64
|
||||||
|
" for '%s'",
|
||||||
|
partid,
|
||||||
type_to_string(tmpctx, struct sha256,
|
type_to_string(tmpctx, struct sha256,
|
||||||
payment_hash));
|
payment_hash));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user