-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
[bug]: SendPaymentV2 does not respect fee limit setting in relation to inbound discounts #8940
Comments
I think that the fee limit check may be in the wrong place: Lines 782 to 787 in 8c0d786
It is done on the net amount, only later the discount is applied which reduces the fee. Will check and try to fix it. |
I have two concerns with current path algo. We should take a closer look at them:
|
As discussed in chat, I don't think that it is possible for a route to decrease in weight after a new hop was added, since
This is related to my comment here #6934 (review) (you noted that as well in #8945, which is a better place to discuss it). |
Yes, Agree about the first point and we should outsource the discussion about the second point, |
Background
When paying to a payment request the caller can specify a fee limit for the maximum allowable fees to pay, with the assumption that if there is a route that has a fee within that constraint it will be used for the payment.
With the introduction of inbound discounts for routing fees, the fee limit does not respect these discounts and therefore will return no route found even when there is in fact a route that would fulfill the fee limit constraint after inbound discounts are applied.
This is problematic for probe-first payment flows that use the routing fee found in the probe as an input to the fee limit argument of SendPaymentV2
Describe your issue here.
Your environment
Steps to reproduce
Expected behavior
Actual behavior
The text was updated successfully, but these errors were encountered: