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
Stake address and stake pool delegation certificates #890
Conversation
cardano-api/src/Cardano/Api.hs
Outdated
-- ^ Pool owners. | ||
-> Seq.StrictSeq Shelley.StakePoolRelay | ||
-- ^ Pool relays. | ||
-> Shelley.StrictMaybe Shelley.PoolMetaData |
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.
-> Shelley.StrictMaybe Shelley.PoolMetaData | |
-> Shelley.StrictMaybe Shelley.PoolMetaData | |
-- ^ Pool metadata. |
'cause why not 🤷♂️
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.
I've not done a proper review yet, but the suggestion below should fix the test failure, as well as being the "right thing" TM
deriving newtype Show | ||
deriving Eq |
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.
Should be able to do:
deriving newtype Show | |
deriving Eq | |
deriving newtype (Eq, Show) |
That is, unless there's some reason for not doing that, that I'm not aware of.
e5016bb
to
d65766d
Compare
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.
Looking good!
A few things below.
= ShelleyDelegationCertificate !ShelleyCertificate | ||
| ShelleyStakePoolCertificate !ShelleyCertificate | ||
deriving (Eq, Show) |
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.
If these are the same type, do we need two constructors?
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.
I use them in the CBOR: 68ef28c#diff-14c30ebd1606eb8a1efa6f0e506e71a8R79
d65766d
to
73b5ea3
Compare
1799505
to
b2ee7f7
Compare
Create certificates to delegate your stake
b2ee7f7
to
196b756
Compare
<*> genRewardAccountShelley | ||
<*> genStakePoolOwnersShelley | ||
<*> Gen.list (Range.linear 1 5) genStakePoolRelayShelley | ||
<*> (Just <$> genPoolMetaDataShelley) |
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.
If that genuinely is optional, you should use Gen.maybe
which is Nothing
about 30% of the time.
…ates Integrate delegation and stake pool certificates in `buildShelleyTransaction`
196b756
to
9df4f1c
Compare
bors merge |
890: Stake address and stake pool delegation certificates r=Jimbo4350 a=Jimbo4350 Issue ----------- - This PR **results** in breaking changes to upstream dependencies. Checklist --------- - [x] I have committed clear and descriptive commits. Be considerate as somebody else will have to read these. - [x] I have added the appropriate labels to this PR. Co-authored-by: Jordan Millar <jordan.millar@iohk.io>
Timed out |
bors merge |
Build succeeded |
895: Genesis stake address and MIR certificates r=Jimbo4350 a=Jimbo4350 Issue ----------- - Depends on #890 - This PR **does not result** in breaking changes to upstream dependencies. Checklist --------- - [x] I have committed clear and descriptive commits. Be considerate as somebody else will have to read these. - [x] I have added the appropriate labels to this PR. Co-authored-by: Jordan Millar <jordan.millar@iohk.io>
Issue
Checklist
I have committed clear and descriptive commits. Be considerate as somebody else will have to read these.
I have added the appropriate labels to this PR.