-
Notifications
You must be signed in to change notification settings - Fork 266
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
Implement the KeySend feature, spontaneous payments #1485
Conversation
dd4e3f2
to
3a894ef
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good job, this is very clean for a first PR!
I've put many comments for things you simply couldn't have guessed.
This needs some tests for the payment reception part, here is what comes to mind:
- test we can receive a single HTLC keysend payment
- test we can receive a multipart keysend payment (with two HTLCs)
- test we reject keysend payments when the feature is disabled in
nodeParams.features
This will allow you to touch many of our infrastructure code, it's great ;)
eclair-core/src/main/scala/fr/acinq/eclair/payment/receive/MultiPartHandler.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/receive/MultiPartHandler.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/receive/MultiPartHandler.scala
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code looks good, once we have tests we should be good to go!
d53f00f
to
df00ec0
Compare
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
fc9c7cd
to
a8f89d7
Compare
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
Signed-off-by: Donovan Jean <donovan@acinq.fr>
eclair-core/src/test/scala/fr/acinq/eclair/payment/MultiPartHandlerSpec.scala
Outdated
Show resolved
Hide resolved
Signed-off-by: Donovan Jean <donovan@acinq.fr>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Support for receiving and sending KeySend payment is added. For an explanation of the KeySend feature see: ElementsProject/lightning#3611
What is KeySend?
For an explanation of the feature see the PR from c-lightning.
Testing
Support for receiving and sending is added. This was tested against each Lightning implementations (
Sender -> Receiver
):Eclair -> Eclair
Eclair -> lnd
Eclair -> c-lightning
lnd -> Eclair
Sending support is not currently merged in c-lightning, so testing in this way
c-lightning -> Eclair
cannot be performed yet.