feat(core,chain): implement Display, FromStr, FromSql and ToSql for BlockId#2097
feat(core,chain): implement Display, FromStr, FromSql and ToSql for BlockId#2097luisschwab wants to merge 2 commits intobitcoindevkit:masterfrom
Display, FromStr, FromSql and ToSql for BlockId#2097Conversation
oleonardolima
left a comment
There was a problem hiding this comment.
Concept ACK
It looks good, though I want to test it with the bdk_wallet companion PR before fully ACK'ing it.
|
Also, the PR description is missing the |
|
@luisschwab If you are looking forward to have this on |
|
@oleonardolima I'll make a backport PR once this is merged on master. |
|
It's not obvious that |
Well, since this our type we get to define how it's implemented. But perhaps it would be cleaner to do different rows for height and hash. I'll update this soon with this approach. |
|
This is not needed anymore, since these conversions already exist for |
This PR implements
Display,FromStrforBlockId, andFromSqlandToSqlforImpl<BlockId>, needed to persist the wallet's birthday as aBlockId(height + hash).Changelog notice
DisplayandFromStrforBlockIdFromSqlandToSqlforImpl<BlockId>