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

Add Script to Constitution #3556

Merged
merged 1 commit into from
Jul 26, 2023
Merged

Add Script to Constitution #3556

merged 1 commit into from
Jul 26, 2023

Conversation

aniketd
Copy link
Contributor

@aniketd aniketd commented Jul 20, 2023

Description

Resolves #3532

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

@aniketd
Copy link
Contributor Author

aniketd commented Jul 20, 2023

Please especially review the CDDL change. I think I may have got it wrong.

Copy link
Contributor

@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.

I like the idea for creating a separate Constritution type and reusing in all places in this PR.
Note that my comments about serialization will have to travel to the serialization of the Constitution type

@aniketd aniketd force-pushed the aniketd/constitution-script branch from 0deef64 to 9454088 Compare July 21, 2023 17:08
@aniketd aniketd requested review from lehins and Soupstraw July 21, 2023 17:09
Copy link
Contributor

@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.

Couple more minor changes is needed

@aniketd aniketd requested a review from lehins July 24, 2023 11:19
@aniketd aniketd force-pushed the aniketd/constitution-script branch from 87655d5 to 15fa2db Compare July 24, 2023 11:30
Copy link
Contributor

@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.

Looks good. A few changes are needed however.

eras/conway/impl/CHANGELOG.md Outdated Show resolved Hide resolved
eras/shelley/impl/CHANGELOG.md Outdated Show resolved Hide resolved
eras/shelley/impl/CHANGELOG.md Show resolved Hide resolved
@aniketd aniketd force-pushed the aniketd/constitution-script branch from 15fa2db to c756014 Compare July 24, 2023 17:25
@aniketd aniketd requested a review from lehins July 24, 2023 17:25
Copy link
Contributor

@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.

Some more feedback, as we discussed on a call. It is better to just introduce a ConstituitonData instead of using the Constitution era as the phantom type for the Hash

@aniketd aniketd force-pushed the aniketd/constitution-script branch from c756014 to 8c57115 Compare July 25, 2023 13:30
@aniketd aniketd requested a review from lehins July 25, 2023 13:31
@aniketd aniketd force-pushed the aniketd/constitution-script branch 2 times, most recently from 1fd9a52 to e907276 Compare July 26, 2023 08:35
Copy link
Contributor

@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.

Awesome work!

Also,
- Switch phantom type in constitution hash from ByteString to ConstitionData
- Move the Constitution to Shelley.Governance
- Adopt some orphan Default instances
@lehins lehins force-pushed the aniketd/constitution-script branch from e907276 to e2bf392 Compare July 26, 2023 14:57
@lehins lehins enabled auto-merge July 26, 2023 14:58
@lehins lehins merged commit 1614708 into master Jul 26, 2023
10 of 11 checks passed
@iohk-bors iohk-bors bot deleted the aniketd/constitution-script branch July 26, 2023 16:25
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.

Add Script to Constitution
3 participants