-
Notifications
You must be signed in to change notification settings - Fork 16
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
Plug *-poll legacy commands back #349
Conversation
e2a4f8a
to
2810fa1
Compare
cardano-cli/src/Cardano/CLI/EraBased/Commands/Governance/Poll.hs
Outdated
Show resolved
Hide resolved
cardano-cli/src/Cardano/CLI/EraBased/Options/Governance/Poll.hs
Outdated
Show resolved
Hide resolved
cardano-cli/src/Cardano/CLI/EraBased/Options/Governance/Poll.hs
Outdated
Show resolved
Hide resolved
f659c2a
to
34ca701
Compare
|
||
runGovernanceCreatePoll | ||
:: BabbageEraOnwards era |
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.
Change this to be BabbageEraOnly
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 can't yet, because we need a release of cardano-api
to bring the PR introducing BabbageEraOnly
. But I will do so when possible 👍
86eb26d
to
7d3d364
Compare
( runGovernancePollCmds, | ||
runGovernanceCreatePoll, {- For legacy caller only -} | ||
runGovernanceAnswerPoll, {- For legacy caller only -} | ||
runGovernanceVerifyPoll {- For legacy caller only -} |
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.
We don't need to add a comment here. It is okay to export run commands even if no-one uses them.
In fact, it is preferred in case we want to change the tests to use these instead of the CLI.
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.
Changed 👍
| GovernanceVerifyPoll | ||
(File GovernancePoll In) -- Poll file | ||
(File (Tx ()) In) -- Tx file | ||
(Maybe (File () Out)) -- Tx file |
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.
Comments are good. If used, then use -- ^
.
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.
Good catch 👍 Changed.
{- TODO replace BabbageEraOnwardsBabbage by BabbageEraOnlyBabbage when available -} | ||
runGovernanceAnswerPoll BabbageEraOnwardsBabbage poll ix mOutFile | ||
GovernanceVerifyPoll poll metadata mOutFile -> | ||
{- TODO replace BabbageEraOnwardsBabbage by BabbageEraOnlyBabbage when available -} |
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.
We shouldn't have to add these comments because when the run
command's eon witness type is changed we will get a type error here and know to change it.
In any case, I originally asked for this to be changed to BabbageEraOnly
. I now think we should keep the eon type as it is. When we hard fork to Conway, users of this command should still expect this to continue working.
We can deprecate it post-Conway hard-fork.
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.
Removed the comments 👍
You're right, I add in mind those poll
commands where babbage
only, but this is the legacy part we're speaking here; so it doesn't apply.
7d3d364
to
77b483d
Compare
Changelog
Context
@newhoggy witnessed after #322 merge that it was removing two many cmomands: the
legacy
voting commands should have been kept.This PR brings back the
legacy
poll commands.Fix #340
Checklist
See Running tests for more details
.cabal
files are updatedhlint
. See.github/workflows/check-hlint.yml
to get thehlint
versionstylish-haskell
. See.github/workflows/stylish-haskell.yml
to get thestylish-haskell
versionghc-8.10.7
andghc-9.2.7