lndk-org/lndk

Bug: A payment error prevents lndk from being able to make subsequent payments

Closed this issue · 1 comments

Describe the bug

A payment error prevents lndk from being able to make subsequent payments

  • Expected Behavior:

future payments should not error because of a past payment attempt failure

  • Actual Behavior:

Once a payment has failed, all payments fail.

$ lndk-cli --address=https://olympus-lndus1:10009 --tls-cert=/lndk/.lnd/tls.cert --macaroon=/lndk/.lnd/data/chain/bitcoin/regtest/admin.macaroon --grpc-host=localhost pay-offer lno1qgsqvgnwgcg35z6ee2h3yczraddm72xrfua9uve2rlrm9deu7xyfzrc2zfjx7mnpw35k7m3qw3hjqetrd3skjuskyypdejcr3vdjzdfwft48l2j3slmm3wlsvv4ea9jjngancl3jsdhqeqg 10000
Error paying for offer: Status { code: Internal, message: "Internal error: Error signing invoice request: Verification(InvalidSignature)", metadata: MetadataMap { headers: {"content-type": "application/grpc", "date": "Sun, 12 May 2024 10:27:13 GMT", "content-length": "0"} }, source: None }
$ 
$ bash
lndk@753febb267b9:~$ lndk-cli --address=https://olympus-lndus1:10009 --tls-cert=/lndk/.lnd/tls.cert --macaroon=/lndk/.lnd/data/chain/bitcoin/regtest/admin.macaroon --grpc-host=localhost pay-offer lno1qgsqvgnwgcg35z6ee2h3yczraddm72xrfua9uve2rlrm9deu7xyfzrc2zfjx7mnpw35k7m3qw3hjqetrd3skjuskyypdejcr3vdjzdfwft48l2j3slmm3wlsvv4ea9jjngancl3jsdhqeqg 10000
Error paying for offer: Status { code: AlreadyExists, message: "LNDK is already trying to pay for provided offer", metadata: MetadataMap { headers: {"content-type": "application/grpc", "date": "Sun, 12 May 2024 10:27:22 GMT", "content-length": "0"} }, source: None }

Environment

  • LND Version: master
  • LNDK Version: #104
  • Operating System: Linux 753febb267b9 6.6.22-linuxkit #1 SMP Fri Mar 29 12:21:27 UTC 2024 aarch64 GNU/Linux

_Please do not include private information in bug reports! _

To Reproduce

  1. Attempt a payment that will fail. It will fail with InvalidSignature error.
  2. Attempt the same payment again. It will fail with AlreadyExists. It should fail with InvalidSignature again.

Additional context
Add any other context about the problem here.

I pushed a fix for this to the grpc server PR: #104
In this commit: d1ac5b3

If you get another chance to test, let me know :) But I think that should close out this issue.