-
Notifications
You must be signed in to change notification settings - Fork 5
feat: Expanded drep_state with historical state and rollback support #122
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
Conversation
Signed-off-by: William Hankins <william@sundae.fi>
Signed-off-by: William Hankins <william@sundae.fi>
Signed-off-by: William Hankins <william@sundae.fi>
golddydev
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.
this looks fine to me.
| } | ||
|
|
||
| pub async fn init(&self, context: Arc<Context<Message>>, config: Arc<Config>) -> Result<()> { | ||
| fn get_bool_flag(config: &Config, key: (&str, bool)) -> bool { |
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.
Feels like these could go in a common/config helper?
sandtreader
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.
Great stuff - only comment is whether we should define a hash type.
|
Merged but left branch open in case you want to do the hash type |
…pansion feat: Expanded drep_state with historical state and rollback support
This PR expands the
drep_statemodule to support all state data needed to align with all /governance/dreps/ related Blockfrost endpoints. A follow up PR will wire these endpoints to the newhistorical_drepsdata.Main changes:
HistoricalDRepStatekeyed byDRepCredentialstoring:tx_hashandcert_index)StateHistoryto commit state changes by block, enabling rollback support.cardano.governance(for votes whenstore-votesenabled)cardano.protocol.parameters(for drep expiration tracking whenstore-infoenabled)GovernanceProceduresMessageto includevote_indexin eachVotingProcedure.DRepRegistration,DRepDeregistration, andDRepUpdatetypes ofTxCertificatewithtx_hashandcert_index.This implementation makes storage configurable within the module so users can keep resource costs low when DRep data isn't needed.