-
Notifications
You must be signed in to change notification settings - Fork 321
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
Add RPC Wallet Example #1106
Add RPC Wallet Example #1106
Conversation
We remove `ElectrumUpdate` and return tuples instead for `ElectrumExt` methods. We introduce the `IncompleteTxGraph` structure to specifically hodl the incomplete `TxGraph`. This change is motivated by @LLFourn's comment: bitcoindevkit@794bf37#r1305432603
Co-authored-by: Steve Myers <[email protected]>
Also introduce `bitcoind_rpc` cli example. Add tests: * `test_sync_local_chain` ensures that `Emitter::emit_block` emits blocks in order, even after reorg. * `test_into_tx_graph` ensures that `into_tx_graph` behaves appropriately for both mempool and block updates. It should also filter txs and map anchors correctly.
Replaced `into_tx_graph_update` with `indexed_tx_graph_update`. The latter returns a vec of `(tx, anchors, last_seen)` to be passed into `IndexedTxGraph::insert_relevant_txs`.
8e89e13
to
f8f3ad2
Compare
f8f3ad2
to
7120eaf
Compare
Better if it goes in alpha.2 together with #1041, but in case we can move it to alpha.3 |
I'm moving this to alpha.3 since #1041 already has a non-wallet example and this one will be easier to do once that's merged. |
@vladimirfomene if you this it's still relevant, go ahead and copy/paste in the README from #1019 after you rebase this PR. |
Replaced by #1172 |
Moved this to beta release so we can focus final alpha releases on functional changes, leaving additional test/example/doc changes to beta milestone. |
Closing since it's replaced by #1172 |
Description
This is a demonstration of how to create a wallet with a RPC syncing mechanism. This builds on #1041.
Notes to the reviewers
Will love to hear your feedback on this current implementation.
All Submissions:
cargo fmt
andcargo clippy
before committingNew Features:
Bugfixes: