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

fix: introduce VoterSetCounter #347

Merged
merged 7 commits into from
Oct 14, 2021

Conversation

0Tech
Copy link
Collaborator

@0Tech 0Tech commented Oct 6, 2021

Description

Introducing a concept "voter set counter" eases integration
with ostracon's VoterSet.


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

Introducing a concept "voter set counter" eases integration
with `ostracon`'s `VoterSet`.
@0Tech 0Tech self-assigned this Oct 6, 2021
@0Tech 0Tech added the A: improvement Changes in existing functionality label Oct 6, 2021
@0Tech 0Tech marked this pull request as ready for review October 6, 2021 03:16
@egonspace egonspace changed the title feat: introduce VoterSetCounter fix: introduce VoterSetCounter Oct 6, 2021
Now `VoteSetCounter` in HandleValidatorSignature indicates the real
counted number, not a index-like number.
Check the liveness threshold only provided `VoterSetCounter >
SignedBlocksWindow` meaning `VoterSetCounter >= SignedBlocksWindow +
1`.
@codecov
Copy link

codecov bot commented Oct 7, 2021

Codecov Report

❗ No coverage uploaded for pull request base (main@cc78696). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #347   +/-   ##
=======================================
  Coverage        ?   53.17%           
=======================================
  Files           ?      642           
  Lines           ?    67248           
  Branches        ?        0           
=======================================
  Hits            ?    35757           
  Misses          ?    28547           
  Partials        ?     2944           

Log `VoterSetCounter` instead of `minVoterSetCount` which is constant.
Copy link

@egonspace egonspace left a comment

Choose a reason for hiding this comment

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

LGTM. It's very good job!

@0Tech 0Tech added the Draft label Oct 7, 2021
Copy link
Contributor

@iproudhon iproudhon left a comment

Choose a reason for hiding this comment

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

LGTM

@egonspace egonspace merged commit 5975502 into Finschia:main Oct 14, 2021
@egonspace egonspace mentioned this pull request Oct 15, 2021
9 tasks
@0Tech 0Tech deleted the 0Tech/feat/voter_set_counter branch October 18, 2021 03:17
@zemyblue zemyblue mentioned this pull request Jan 26, 2022
5 tasks
zemyblue added a commit to zemyblue/finschia-sdk that referenced this pull request Nov 23, 2023
zemyblue added a commit that referenced this pull request Dec 1, 2023
* chore: revert ostracon slashing changes (revert #347)

* chore: revert block converting

* chore: revert voter set comments

* chore: update changelog

* chore: update changelog category
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A: improvement Changes in existing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants