-
Notifications
You must be signed in to change notification settings - Fork 44
Description
Description
The TxGraph needs to have the prev txouts of a given tx to calculate the fee. Right now, when we sync/scan from our data source crates (esplora/electrum), these txouts are NOT obtained.
Some users would like to be able to calculate the fee for every full tx in the graph.
Thank you to @afilini for pointing this problem out to me.
Proposal
Add TxGraph::missing_prev_txouts method.
pub fn missing_prev_txouts(&self) -> impl Iterator<Item = OutPoint> { /* TODO */ }Add fetch_txouts_only (better name?) method to EsploraExt and ElectrumExt. This is different to using scan_without_keychain with outpoints set. The intention here is to get partial transactions.
fn fetch_txouts_only(&self, outpoints: impl IntoIterator<Item = OutPoint>) -> <Vec<(OutPoint, TxOut)>, Error>;We also should add a method to Wallet: add_txout(&mut self, outpoint: OutPoint, txout: TxOut), for users who would like to add arbitrary txouts.
Further Notes
Let's move forward with this once everyone comes to consensus as to what is needed.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status