-
Notifications
You must be signed in to change notification settings - Fork 427
fix(esplora): deduplicate missing txids in fetch_txs_with_outpoints #2104
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: master
Are you sure you want to change the base?
fix(esplora): deduplicate missing txids in fetch_txs_with_outpoints #2104
Conversation
evanlinjin
left a comment
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.
cACK
Looks good, thanks for fixing this.
Just a minor thing before merging - could you combine the two commits and include the scope?
I.e.
fix(esplora): deduplicate missing txids in fetch_txs_with_outpoints
2c95146 to
0071ee6
Compare
Did it |
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.
ACK 787e07c
0071ee6 to
787e07c
Compare
oleonardolima
left a comment
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.
cACK 787e07c
|
Can you update the PR description to follow the template, and also add the changelog changes in it ? |
Previously
fetch_txs_with_outpointscollected spend txids into a Vec, so the same txid could be pushed multiple times when one transaction spent several input outpoints. This caused redundantget_tx_infocalls to Esplora for the same transaction, wasting network and CPU without changing the resultingTxUpdate.Use
HashSet<Txid>formissing_txsin both async and blockingfetch_txs_with_outpoints,so each txid is only requested once while keeping the observable behaviour ofSyncResponse/TxUpdateunchanged.