Implement the interactive-tx protocol#2273
Merged
Merged
Conversation
b2cf365 to
ab70d6f
Compare
ab70d6f to
8056fa9
Compare
sstone
reviewed
Jun 6, 2022
f63bef6 to
7b43477
Compare
After exchanging `open_channel2` and `accept_channel2`, we start building the funding transaction. We stop once we've generated our signatures for the funding transaction, at which point we should store the channel in the DB (which will be done in future commits).
7b43477 to
ba5a730
Compare
pm47
reviewed
Aug 10, 2022
Otherwise there is a risk of losing state in reorgs.
For inputs that can't be used in the interactive-tx construction.
We explicitly handle the case where bitcoind incorrectly reuses unusable inputs that we locked, otherwise we could go into an infinite funding loop.
Codecov Report
@@ Coverage Diff @@
## master #2273 +/- ##
========================================
Coverage 84.84% 84.85%
========================================
Files 195 198 +3
Lines 14850 15255 +405
Branches 609 633 +24
========================================
+ Hits 12600 12945 +345
- Misses 2250 2310 +60
|
pm47
reviewed
Aug 11, 2022
Member
pm47
left a comment
There was a problem hiding this comment.
The send/receive ping-pong is really neat. Yay simple protocols!
Except: - use stash instead of message timer delays - investigate non-initiator fees tweaking Those two deserve their own commit.
When we have change output, it's easy to discount the fees for the common fields.
Explicitly handle cases where bitcoind returns an invalid funded transaction.
pm47
reviewed
Aug 12, 2022
Member
pm47
left a comment
There was a problem hiding this comment.
InteractiveTxBuilderSpec is really nice, just one nit and we are good to go.
pm47
approved these changes
Aug 12, 2022
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.
After exchanging
open_channel2andaccept_channel2, we start building the funding transaction with the interactive-tx protocol.We stop once we've generated our signatures for the funding transaction, at which point we should store the channel in the DB (which will be done in future commits).