-
Notifications
You must be signed in to change notification settings - Fork 417
esplora: chain_update errors if no point of connection
#1971
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
esplora: chain_update errors if no point of connection
#1971
Conversation
65c4f7b to
96a6207
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.
utACK 96a6207
It's valid to note that we covered the fetch_blocks emptyness scenario on the client side too, at bitcoindevkit/rust-esplora-client#113
| while client.get_height().await? < mine_to { | ||
| std::thread::sleep(Duration::from_millis(64)); | ||
| } |
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.
nit: FWIW, you can use wait_until_electrum_sees_block if #1640 ends up landing before this one.
LagginTimes
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.
ACK 96a6207
Before, the `chain_update` function would hit a panic if the local checkpoint was not on the same network as the remote server. Now if we have iterated all of the blocks of the `local_cp` and do not find a "point of agreement", then we return early with a `esplora_client::Error::HeaderHashNotFound`.
96a6207 to
568a366
Compare
Description
Before, the
chain_updatefunction might have panicked if the local checkpoint was not on the same network as the remote server. Now if we have iterated all of the blocks of the local CP and do not find a point of agreement, then we return early with aesplora_client::Error::HeaderHashNotFound.cc bitcoindevkit/bdk_wallet#30
Notes to the reviewers
Changelog notice
Checklists
All Submissions:
cargo +nightly fmtandcargo clippybefore committingNew Features:
Bugfixes: