Skip to content
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

Validate previously enacted govAction #3670

Merged
merged 7 commits into from
Aug 30, 2023
Merged

Validate previously enacted govAction #3670

merged 7 commits into from
Aug 30, 2023

Conversation

teodanciu
Copy link
Contributor

Description

Closes #3656

  • EnactState: store the last enacted GovId for each of the 4 types of actions for which it is relevant (corresponding to GovActionPurpose)
  • Ratify: check that the previous govId that we have from the proposal matches the one that we store in the enact state.
    If it doesn't match, we "drop" the signal (we don't enact it and it will eventually expire)
  • Enact: when enacting, update the stored value for last govId

Checklist

  • Commit sequence broadly makes sense and commits have useful messages
  • New tests are added if needed and existing tests are updated
  • When applicable, versions are updated in .cabal and CHANGELOG.md files according to the
    versioning process.
  • The version bounds in .cabal files for all affected packages are updated. If you change the bounds in a cabal file, that package itself must have a version increase. (See RELEASING.md)
  • All visible changes are prepended to the latest section of a CHANGELOG.md for the affected packages. New section is never added with the code changes. (See RELEASING.md)
  • Code is formatted with fourmolu (use scripts/fourmolize.sh)
  • Cabal files are formatted (use scripts/cabal-format.sh)
  • hie.yaml has been updated (use scripts/gen-hie.sh)
  • Self-reviewed the diff

@teodanciu teodanciu force-pushed the td/validate-prev-govid branch 4 times, most recently from 90035aa to 516de6c Compare August 23, 2023 16:07
Copy link
Collaborator

@lehins lehins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perfect with the respect to logic. Let's converge on the naming and this will be good to be merged

Copy link
Collaborator

@lehins lehins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perfect! Thank you!

eras/conway/impl/src/Cardano/Ledger/Conway/Governance.hs Outdated Show resolved Hide resolved
@lehins lehins enabled auto-merge August 30, 2023 20:55
@lehins lehins merged commit 330b42d into master Aug 30, 2023
10 of 12 checks passed
@iohk-bors iohk-bors bot deleted the td/validate-prev-govid branch August 30, 2023 23:30
Soupstraw pushed a commit that referenced this pull request Aug 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Validate Previous Governance Action Id upon enactment
2 participants