routerrpc: add more failure reasons and route hints#3156
Merged
Conversation
alexbosworth
reviewed
Jun 4, 2019
74a78fd to
770373d
Compare
2c73dfe to
85fe4d0
Compare
Roasbeef
requested changes
Jul 1, 2019
Member
There was a problem hiding this comment.
Doesn't attempt to also parse the route hints from the regular payment request.
Contributor
Author
There was a problem hiding this comment.
Payment request route hints are appended to the list of hints further down. This allows you to augment the encoded hints with a few more.
Contributor
Author
|
@Roasbeef ptal |
cfromknecht
reviewed
Jul 3, 2019
Contributor
cfromknecht
left a comment
There was a problem hiding this comment.
nice diff, pretty straightforward. some minor comments
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes:
FailureReasonErroradded. This is returned in case we get an unexpected response to our payment attempt for which it does not make sense to try different routes.FailureReasonIncorrectPaymentDetailsadded. This is returned in case the payment hash is unknown, the amount is incorrect and/or the final cltv expiry is incorrect. The route that triggered this failure is returned along side the failure message itself.routerrpc.SendPayment. Previously this was only possible when the route hints were encoded in a payment request. Fixes Allow hop hints to be specified in routerrpc sendPayment #3202These changes allow probing destinations (that may require route hints) with an unknown payment hash. By inspecting the route when a probe succeeds, a realistic fee and time lock estimate can be obtained.