-
Notifications
You must be signed in to change notification settings - Fork 410
Allow setting a payer_note
on pay_for_offer_from_human_readable_name
#3808
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
base: main
Are you sure you want to change the base?
Conversation
👋 Thanks for assigning @carlaKC as a reviewer! |
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.
Mostly looks good to me. Could we add some test coverage in lightning-dns-resolver
's end_to_end_test
to ensure this is working as expected?
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 once @tnull's comments + request for a test are added 👍
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3808 +/- ##
==========================================
+ Coverage 89.89% 89.90% +0.01%
==========================================
Files 160 160
Lines 129136 129223 +87
Branches 129136 129223 +87
==========================================
+ Hits 116088 116183 +95
+ Misses 10354 10349 -5
+ Partials 2694 2691 -3 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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
I took the liberty of pushing three additional commits to this PR branch that cleanup preexisting doc breakage/nits under the dnssec
feature, and ensure we cargo test
/check
/doc
lightning
with dnssec
in CI to make sure we catch such things going forward. (cc @TheBlueMatt)
@@ -405,7 +406,86 @@ mod test { | |||
let params = RouteParametersConfig::default(); | |||
nodes[0] | |||
.node | |||
.pay_for_offer_from_human_readable_name(name, amt, payment_id, retry, params, resolvers) | |||
.pay_for_offer_from_human_readable_name( |
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.
Should be okay for now because kinda pre-existing, but going forward we'll probably want to DRY up that test code instead of copy/pasting the same flow.
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.
+1, happy to review a followup DRYing up these tests
noted, thanks for the review! @tnull |
🔔 1st Reminder Hey @TheBlueMatt @carlaKC! This PR has been waiting for your review. |
1 similar comment
🔔 1st Reminder Hey @TheBlueMatt @carlaKC! This PR has been waiting for your review. |
🔔 2nd Reminder Hey @TheBlueMatt @carlaKC! This PR has been waiting for your review. |
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.
Nice change, good to have docs properly enforced too 👍
@@ -405,7 +406,86 @@ mod test { | |||
let params = RouteParametersConfig::default(); | |||
nodes[0] | |||
.node | |||
.pay_for_offer_from_human_readable_name(name, amt, payment_id, retry, params, resolvers) | |||
.pay_for_offer_from_human_readable_name( |
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.
+1, happy to review a followup DRYing up these tests
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.
This entire branch needs a rebase now though (i.e., don't forget to pull the additional commits first).
pay_for_offer and pay_for_offer_from_human_readable_name take RouteParametersConfig and not max_total_routing_fee_msat.
.. as we'd otherwise never catch any bugs particular to the `dnssec` feature.
.. and link all instances for consistency.
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.
rebase LGTM!
Closes #3780
Allows setting a
payer_note
onpay_for_offer_from_human_readable_name
and added a similarly named field to theAwaitingOffer
. When paying the offer, it will get thepayer_note
fromparams_for_payment_awaiting_offer
.