-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Added /consensus_params endpoint #2415
Conversation
I would really appreciate some early feedback |
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.
👍 🍡
Thanks for your contribution and the clean addition provided!
rpc/core/types/responses.go
Outdated
// ConsensusParams for given height | ||
type ResultConsensusParams struct { | ||
BlockHeight int64 `json:"block_height"` | ||
ConsensusParams *types.ConsensusParams `json:"consensus_params"` |
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.
Minor nit, should not be a pointer as it is non-optional.
Codecov Report
@@ Coverage Diff @@
## develop #2415 +/- ##
===========================================
- Coverage 60.99% 60.91% -0.09%
===========================================
Files 197 197
Lines 16313 16322 +9
===========================================
- Hits 9950 9942 -8
- Misses 5496 5513 +17
Partials 867 867
|
This also needs a changelog entry ( |
@zramsay Any docs that need to be updated with this new endpoint being introduced? |
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.
Thanks for writing this !! Only other thing missing is the changelog entry :)
return nil, err | ||
} | ||
|
||
consensusparams, err := sm.LoadConsensusParams(stateDB, height) |
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.
consensusParams
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.
@ebuchman What should I fill in the changelog entry ? can you help me with that?
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 I open a new PR for incorporating these changes ?
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.
no worries we'll cover it! thanks again for the contribution!
for reference, for the next PR, add a note about your change in the CHANGELOG_PENDING.md file: https://github.com/tendermint/tendermint/blob/develop/CHANGELOG_PENDING.md
Be sure to follow the formats used there :)
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.
Sure thanks 😄
Fixes #2311