-
Notifications
You must be signed in to change notification settings - Fork 86
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 GetRewardInfoPools
local state query
#3423
Conversation
Isn't this one a bit redundant with |
GetRewardInfoPool
local state queryGetRewardInfoPools
local state query
Unfortunately, it's not redundant enough. 😅 Specifically,
* "current" pool parameters (cost, margin) include any parameter changes from the previous epoch, but not from the current epoch. |
Well, that's unfortunate 😅... Although, as far as I remember, the main reason for introducing GetRewardProvenance was to give local clients means to make educated delegation choices. So perhaps the semantic of this query needs to be revised 🤔? |
Maybe, but changing the query semantics would not be backwards compatible (for example, the data types differ). My thinking was that adding a new query and deprecating the old one later would be the least disruptive path to getting a query with suitable semantics. |
69187b9
to
31a44bf
Compare
Please also add an entry atop the https://github.com/input-output-hk/ouroboros-network/blob/master/ouroboros-consensus/docs/interface-CHANGELOG.md file. Thanks! |
We reviewed the use of versions here during a recent Consensus Planning call. I think the PR looks good. @HeinrichApfelmus What's the status here? Do you have a plan for the CI failures? I'm just double-checking that you're not blocked on us. Thanks. |
Also, we merge with |
Lastly (I'm sorry for the comment barrage), we just merged a PR that updates the |
For posterity here the comments that were originally in the PR description:
|
Great, thanks! The merge of the PR from cardano-ledger-specs is essentially what I was waiting for. There is little point in appeasing CI if the main function to be called does not exist yet. 😄 |
e22fbff
to
81a85ad
Compare
@@ -361,6 +362,21 @@ pattern CardanoNodeToClientVersion7 = | |||
:* Nil | |||
) | |||
|
|||
-- | The hard fork enabled, and the Shelley, Allegra, Mary and Alonzo eras enabled | |||
-- Using 'ShelleyNodeToClientVersion5' for the Shelley-based eras , which | |||
-- enables new queries. |
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.
Would it make sense to refer to what these new queries are?
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 figured that since comments are particularly susceptible to bitrot, it would be best if I mention the specific queries in a single place only, in this case the definition of ShelleyNodeToClientVersion5
.
But I you prefer, I'm happy to the specific query (GetRewardInfoPools
) at the definition of CardanoNodeToClientVersion8
as well.
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 figured that since comments are particularly susceptible to bitrot, it would be best if I mention the specific queries in a single place only, in this case the definition of ShelleyNodeToClientVersion5.
Sure, that makes sense. I'm ok with the comment as is.
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.
LGTM!
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.
@HeinrichApfelmus Please issue bors merge
whenever you're content with the commits (eg after one final rebase, etc). Thanks!
… and try to add appropriate version numbers. NOTE: This depends on a new function `getRewardInfoPools` in `cardano-ledger-specs`
… as suggested by @nfrisby
81a85ad
to
2da0d31
Compare
bors merge |
Build succeeded: |
Issue number
CAD-3479
Summary
Introduces a new local state query
GetRewardInfoPools
which provides up-to-date information the stake pool rewards and ranking.