bitcoindevkit / bitcoindevkit/bdk_wallet
Wallet's persistence should have a fixed "header" section
Open
new feature
- Dominant language
- Rust
- Stars
- 59
- Forks
- 105
- Avg merge
- 10d 9h
- Merged PRs (30d)
- 1
Description
**Describe the enhancement**
Add a fixed header section to the wallet's persistence.
This is initially proposed by @LLFourn: https://github.com/bitcoindevkit/bdk/pull/1178#discussion_r1379454497
**Use case**
This can be used to store data that are mostly unchanging such as network type, version, etc.
**Implementation proposal**
```rust
pub struct Database: PersistBackend {
fn write_header(&mut self, header: H) -> Result<(), Self::WriteError>;
fn load_header(&self) -> Result;
}
```
Contributor guide
Assessment
This issue has not been assessed yet.