Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Router SendPayment does not parse Amount when Invoice with dynamic value is set. #174

Open
zoop-btc opened this issue Jan 29, 2024 · 2 comments

Comments

@zoop-btc
Copy link

rpcReq.Amt = int64(request.Amount)

When sending a payment with the parameters request.Invoice set to a 0 amount invoice as well as request.Amount set it will still submit it without the amount as opposed to what is expected for a dynamic value invoice.

I tried it with this invoice. This will result in rpc error: code = Unknown desc = amount must be specified when paying a zero amount invoice

Or is this expected and I have to replace the 0 amount invoice myself first?

@guggero
Copy link
Member

guggero commented Jan 30, 2024

I think this is probably a left-over case from back when zero-amount invoices were unsafe. Should probably be fixed in lndclient.

@zoop-btc
Copy link
Author

zoop-btc commented Feb 2, 2024

I have started to use lnrpc.LightningClient.SendPaymentSync instead and subscribe to status updates immediately after as a workaround.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants