-
Notifications
You must be signed in to change notification settings - Fork 371
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
Handle fallible commitment secret #3152
Handle fallible commitment secret #3152
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3152 +/- ##
==========================================
+ Coverage 89.83% 90.08% +0.25%
==========================================
Files 121 121
Lines 100612 102971 +2359
Branches 100612 102971 +2359
==========================================
+ Hits 90380 92766 +2386
- Misses 7564 7571 +7
+ Partials 2668 2634 -34 ☔ View full report in Codecov by Sentry. |
cf058bc
to
18acc2a
Compare
This needs rebase now 🎉 |
18acc2a
to
e296b74
Compare
Rebased! Btw, for the missing test coverage in #3150, I'll get to those in the PR where I handle fallible per commitment point for the channel reestablish case (as opposed to here), since I think those cases will require that - hoping to make that PR this week |
50df53a
to
e4ad15b
Compare
CI is very, very sad. |
Otherwise basically LGTM, nice and easy PR :) |
e4ad15b
to
3413032
Compare
lol yesterday i thought i fixed the CI error but didn't commit anything and did an empty force push 😆 |
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.
Just nits, feel free to land!
@@ -10,18 +10,21 @@ | |||
//! Tests for asynchronous signing. These tests verify that the channel state machine behaves | |||
//! properly with a signer implementation that asynchronously derives signatures. | |||
|
|||
use std::collections::HashSet; |
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.
nit: in most files we have a use crate::prelude::*;
, which I believe would avoid this
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.
Ah, right, think that means this file will fail to build no-std, though we can also fix that when we drop the cfg flag.
log_trace!(logger, "Last revoke-and-ack pending in channel {} for sequence {} because the next per-commitment point is not available", | ||
&self.context.channel_id(), self.context.holder_commitment_point.transaction_number()); |
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.
nit: I think this log is redundant with the ones above
Gonna land, @alecchendev can handle the followups in #3109. |
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
This also slightly refactors get_funding_signed_msg to match the logic more similarly, as well as removes a log to fix a nit from lightningdevkit#3152.
For all of our async signing logic in channel establishment v1, we set signer flags in the method where we create the raw lightning message object. To keep things consistent, this commit moves setting the signer flags to where we create funding_created, since this was being set elsewhere before. While we're doing this cleanup, this also slightly refactors our funding_signed method to move some code out of an indent, as well as removes a log to fix a nit from lightningdevkit#3152.
For all of our async signing logic in channel establishment v1, we set signer flags in the method where we create the raw lightning message object. To keep things consistent, this commit moves setting the signer flags to where we create funding_created, since this was being set elsewhere before. While we're doing this cleanup, this also slightly refactors our funding_signed method to move some code out of an indent, as well as removes a log to fix a nit from lightningdevkit#3152.
For all of our async signing logic in channel establishment v1, we set signer flags in the method where we create the raw lightning message object. To keep things consistent, this commit moves setting the signer flags to where we create funding_created, since this was being set elsewhere before. While we're doing this cleanup, this also slightly refactors our funding_signed method to move some code out of an indent, as well as removes a log to fix a nit from lightningdevkit#3152.
For all of our async signing logic in channel establishment v1, we set signer flags in the method where we create the raw lightning message object. To keep things consistent, this commit moves setting the signer flags to where we create funding_created, since this was being set elsewhere before. While we're doing this cleanup, this also slightly refactors our funding_signed method to move some code out of an indent, as well as removes a log to fix a nit from lightningdevkit#3152.
Builds on
#3149,#3150. Most of the logic for this was added in the prerequisite PRs. Here we just set thesigner_pending_revoke_and_ack
flag if we fail to get the commitment secret.