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

Update query cli commands to handle Allegra and Mary eras #2136

Merged
merged 5 commits into from Dec 1, 2020

Conversation

Jimbo4350
Copy link
Contributor

No description provided.

@Jimbo4350 Jimbo4350 force-pushed the jordan/update-cli-queries-mary-allegra branch 3 times, most recently from c07b79a to 8b7cb71 Compare November 30, 2020 15:25
@dcoutts dcoutts force-pushed the jordan/update-cli-queries-mary-allegra branch from 8b7cb71 to 74877cb Compare November 30, 2020 16:02
Jimbo4350 and others added 5 commits December 1, 2020 00:41
First step of updating all the query commands to support the Allegra and
Mary eras.

In principle the queries could find out the era from the node itself,
but this is a bit awkward so for now we require an extra cli flag.
We pass the era in where needed. Generalise various helper functions
over era type classes.

For now the UTxO printing code relies on the value type being coin
specifically, which means we do not yet support the Mary era.

Add a couple functions for obtaining required era class constraints
or type equality constraints based on the era:
 * obtainLedgerEraClassConstraints
 * requireValueTypeIsCoin

The latter is used for the UTxO printing part to satisfy their
constraints.
They all follow more or less the same pattern. Various helper functions
become polymorphic with class and type equality constraints.

We then need a couple more helper functions for obtaining the necessary
constraints so they're available where we need them.
@dcoutts dcoutts force-pushed the jordan/update-cli-queries-mary-allegra branch from 74877cb to 99ac681 Compare December 1, 2020 02:25
@dcoutts dcoutts marked this pull request as ready for review December 1, 2020 02:25
Copy link
Contributor

@dcoutts dcoutts left a comment

Choose a reason for hiding this comment

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

Tricky one.

@dcoutts
Copy link
Contributor

dcoutts commented Dec 1, 2020

bors merge

@iohk-bors
Copy link
Contributor

iohk-bors bot commented Dec 1, 2020

@iohk-bors iohk-bors bot merged commit c2bbcbe into master Dec 1, 2020
@iohk-bors iohk-bors bot deleted the jordan/update-cli-queries-mary-allegra branch December 1, 2020 09:44
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.

None yet

3 participants