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

Deal with channels with fees=0 when computing a route #905

Merged
merged 4 commits into from
Mar 26, 2019

Conversation

araspitzu
Copy link
Contributor

@araspitzu araspitzu commented Mar 19, 2019

Channels with feeBase=0 and feeProportional=0 cause issues to the path-finding algorithm, this PR makes eclair consider those channel as feeBase=1msat when computing a route but then when the payment is sent out we use its actual fee (zero).

@araspitzu araspitzu changed the title Ignore channels with fees=0 when computing a route [WIP] Ignore channels with fees=0 when computing a route Mar 19, 2019
@araspitzu araspitzu force-pushed the deal_with_channels_with_zero_fees branch from 9d8f319 to 0765818 Compare March 20, 2019 10:03
@araspitzu araspitzu changed the title [WIP] Ignore channels with fees=0 when computing a route [WIP] Deal with channels with fees=0 when computing a route Mar 20, 2019
@araspitzu araspitzu changed the title [WIP] Deal with channels with fees=0 when computing a route Deal with channels with fees=0 when computing a route Mar 20, 2019
val g = makeGraph(updates)

val route1 = Router.findRoute(g, a, e, DEFAULT_AMOUNT_MSAT, numRoutes = 1, routeParams = DEFAULT_ROUTE_PARAMS)
assert(route1.map(hops2Ids) === Success(1 :: 3 :: Nil))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see where we test that we "treat channels with fees=0 as if they had feeBase=1msat" ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The name has become misleading after i changed the behavior of the implementation, initially we wanted to ignore the 0-fee channels and that test was asserting exactly that.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about 077a4a4?

@sstone sstone merged commit 89ddc52 into master Mar 26, 2019
@sstone sstone deleted the deal_with_channels_with_zero_fees branch March 26, 2019 13:00
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

Successfully merging this pull request may close these issues.

2 participants