-
Notifications
You must be signed in to change notification settings - Fork 322
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
refactor: Implement generics for CheckPoint
, LocalChain
, and spk_client
types
#1582
base: master
Are you sure you want to change the base?
Conversation
CheckPoint
takes a genericCheckPoint
and LocalChain
a899049
to
7c13781
Compare
7c13781
to
d934a6c
Compare
ea1cf8b
to
bf90ea5
Compare
c278804
to
6300d7c
Compare
CheckPoint
and LocalChain
CheckPoint
, LocalChain
, and spk_client
types
6300d7c
to
315f687
Compare
7ef16f5
to
b7c5a9a
Compare
CheckPoint
, LocalChain
, and spk_client
typesCheckPoint
, LocalChain
, and spk_client
types
5f2d199
to
6b3ffa9
Compare
6b3ffa9
to
367099a
Compare
367099a
to
27fe3bb
Compare
/// If `header` is of the genesis block, the checkpoint won't have a `prev` node. Otherwise, | ||
/// we return a checkpoint linked with the previous block. | ||
#[deprecated( | ||
since = "0.1.1", |
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.
❓ Is this version correct ?
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.
Thanks for pointing this out! The version number for bdk_core
has been updated since this PR was created. This will need to be updated as well.
/// The effect of `insert` depends on whether a height already exists. If it doesn't the | ||
/// `block_id` we inserted and all pre-existing blocks higher than it will be re-inserted after | ||
/// it. If the height already existed and has a conflicting block hash then it will be purged | ||
/// along with all block followin it. The returned chain will have a tip of the `block_id` |
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.
/// along with all block followin it. The returned chain will have a tip of the `block_id` | |
/// along with all blocks following it. The returned chain will have a tip of the `block_id` |
Implements #1757.
Description
This PR is a step towards header checkpointing for
bdk_electrum
. The goal is to be able to store whole headers inCheckPoint
so they do not have to be re-downloaded. Storing headers this way would be a prerequisite for caching of merkle proofs and for median time passed.TODO:
CheckPoint
to take in a generic.LocalChange
to take in a generic.spk_client
types to take in generics.Notes to the reviewers
Changelog notice
CheckPoint
takes in a generic.LocalChain
andChangeSet
take in generics.spk_client
types can take in generics.Checklists
All Submissions:
cargo fmt
andcargo clippy
before committing