Merged
Conversation
d5e1c12 to
1c77dbb
Compare
pm47
reviewed
Feb 15, 2021
Member
There was a problem hiding this comment.
This works but may generate warnings in logs. Another strategy would have been to handle delayed input one-by-one, and keep track of the remaining inputs in the BITCOIN_PARENT_TX_CONFIRMED event.
Something like:
case class BITCOIN_PARENT_TX_CONFIRMED(childTx: Transaction, nextCsvTimeouts: Map[ByteVector32, Long]) extends BitcoinEvent
eclair-core/src/main/scala/fr/acinq/eclair/blockchain/bitcoind/ZmqWatcher.scala
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/blockchain/bitcoind/ZmqWatcher.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/blockchain/electrum/ElectrumWatcher.scala
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/blockchain/electrum/ElectrumWatcher.scala
Outdated
Show resolved
Hide resolved
Member
Author
TBH this code is very temporary; I'll completely remove and change how we track and publish txs to support regularly bumping tx fees for anchor outputs, so I'd rather go with the simplest approach / the less code changes for now. |
sstone
reviewed
Feb 17, 2021
eclair-core/src/main/scala/fr/acinq/eclair/blockchain/bitcoind/ZmqWatcher.scala
Outdated
Show resolved
Hide resolved
In some places of the codebase we relied on the fact that lightning transactions had a single input. That was correct with the standard commitments format, but will not be the case with anchor outputs: 2nd-stage txs (htlc-txs) and 3rd-stage txs (claim-htlc-txs) can be RBF-ed and have any number of inputs and outputs.
1c77dbb to
7c7606b
Compare
pm47
approved these changes
Feb 18, 2021
sstone
approved these changes
Feb 18, 2021
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.
In some places of the codebase we relied on the fact that lightning transactions had a single input. That was correct with the standard commitments format, but will not be the case with anchor outputs: 2nd-stage txs (htlc-txs) and 3rd-stage txs (claim-htlc-txs) can be RBF-ed and have any number of inputs and outputs.