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

Sort validators like tendermint in HistoricalInfo #7691

Merged
merged 13 commits into from
Oct 29, 2020
Merged

Conversation

AdityaSripal
Copy link
Member

Description

closes: #7676


Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.

  • Targeted PR against correct branch (see CONTRIBUTING.md)
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Code follows the module structure standards.
  • Wrote unit and integration tests
  • Updated relevant documentation (docs/) or specification (x/<module>/spec/)
  • Added relevant godoc comments.
  • Added a relevant changelog entry to the Unreleased section in CHANGELOG.md
  • Re-reviewed Files changed in the Github PR explorer
  • Review Codecov Report in the comment section below once CI passes

@codecov
Copy link

codecov bot commented Oct 27, 2020

Codecov Report

Merging #7691 into master will increase coverage by 0.01%.
The diff coverage is 80.00%.

@@            Coverage Diff             @@
##           master    #7691      +/-   ##
==========================================
+ Coverage   54.13%   54.14%   +0.01%     
==========================================
  Files         611      611              
  Lines       38639    38648       +9     
==========================================
+ Hits        20917    20926       +9     
+ Misses      15590    15588       -2     
- Partials     2132     2134       +2     

@jackzampolin
Copy link
Member

@AdityaSripal take a peek here too. Might want to make sure you can take that output and use ToTMValidators

#7676 (comment)

Copy link
Contributor

@cwgoes cwgoes left a comment

Choose a reason for hiding this comment

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

Not sure about the store fetch change but the sort looks fine modulo existing comments.

x/staking/keeper/historical_info.go Outdated Show resolved Hide resolved
Copy link
Contributor

@cwgoes cwgoes left a comment

Choose a reason for hiding this comment

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

ACK

@colin-axner
Copy link
Contributor

@AdityaSripal it looks like gRPC tests are failing

@AdityaSripal AdityaSripal added the A:automerge Automatically merge PR once all prerequisites pass. label Oct 29, 2020
@mergify mergify bot merged commit b7b925a into master Oct 29, 2020
@mergify mergify bot deleted the aditya/sort-vals-tm branch October 29, 2020 12:17
clevinson pushed a commit that referenced this pull request Oct 29, 2020
* sort validators like tendermint

* address comments

* switch ordering in tests

* change sort logic in error case

* don't change test validators array order

Co-authored-by: Jack Zampolin <jack.zampolin@gmail.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A:automerge Automatically merge PR once all prerequisites pass. C:x/staking
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Sort Validators like Tendermint in HistoricalInfo
7 participants