In CheckBalance.scala, we try to group 3rd-stage htlc-delayed txs to their corresponding HTLC transaction:
|
.filter(htlcTx => localCommitPublished.claimHtlcDelayedTxs.exists(_.input.outPoint.txid == htlcTx.tx.txid)) |
However, that doesn't work with anchor outputs, where the htlc transaction we have in LocalCommitPublished does not match the htlc transaction that ends up confirming because fees are set in ReplaceableTxPublisher, which changes the txid.
We should instead use the irrevocablySpent map to map HTLC outputs of the commit tx to the txid of the confirmed HTLC tx that spends it?
In
CheckBalance.scala, we try to group 3rd-stage htlc-delayed txs to their corresponding HTLC transaction:eclair/eclair-core/src/main/scala/fr/acinq/eclair/balance/CheckBalance.scala
Line 122 in f14b92d
However, that doesn't work with anchor outputs, where the htlc transaction we have in
LocalCommitPublisheddoes not match the htlc transaction that ends up confirming because fees are set inReplaceableTxPublisher, which changes thetxid.We should instead use the
irrevocablySpentmap to map HTLC outputs of the commit tx to thetxidof the confirmed HTLC tx that spends it?