-
Notifications
You must be signed in to change notification settings - Fork 32
Description
Feature - Use the signer state when getting the bitcoin chain tip
1. Description
Right now the signers will query the database for the bitcoin chain tip whenever it is needed. This is mostly okay, but the result returned from the database need not be the actual canonical chain tip, in the sense that there may be another block in our database that is the canonical chain tip and our query selected incorrectly.
The block hash returned from the bitcoin core over the ZMQ interface is assumed to be the actual canonical bitcoin chain tip block hash, so we should use that instead.
Note that this hasn't been an issue so far, but it's best to remove the possibility of it happening. After making this change, we do not need to worry about the fact that the chain tip returned from our queries is not guaranteed to be the canonical bitcoin chain tip.
2. Technical Details
We already have the bitcoin chain tip in the SignerState
object, so we should just use that instead of querying the database.
2.1 Acceptance Criteria
- Do not query the database for the bitcoin chain tip, use the signer state instead.
3. Related Issues and Pull Requests (optional)
Metadata
Metadata
Assignees
Labels
Type
Projects
Status