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

rename Accum -> ProposerPriority #2932

Merged
merged 2 commits into from Nov 28, 2018
Merged

rename Accum -> ProposerPriority #2932

merged 2 commits into from Nov 28, 2018

Conversation

liamsi
Copy link
Contributor

@liamsi liamsi commented Nov 28, 2018

ref #2915

  • Updated all relevant documentation in docs
  • Updated all code comments where relevant
  • Wrote tests
  • Updated CHANGELOG_PENDING.md

 - rename fields, methods, comments, tests
@liamsi liamsi changed the title rename Accum -> ProposerPriority: rename Accum -> ProposerPriority Nov 28, 2018
Copy link
Contributor

@melekes melekes left a comment

Choose a reason for hiding this comment

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

💎

@liamsi
Copy link
Contributor Author

liamsi commented Nov 28, 2018

Merging in develop shortly to resolve the conflicts.

@@ -275,7 +275,7 @@ func randPubKey() crypto.PubKey {

func randValidator_() *Validator {
val := NewValidator(randPubKey(), cmn.RandInt64())
val.Accum = cmn.RandInt64()
val.ProposerPriority = cmn.RandInt64() % MaxTotalVotingPower
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I had to change this too (unrelated to the renaming). Without this, TestValidatorSetBasic would panic (and fail) on rare occasions. Namely, if cmn.RandInt64() > MaxTotalVotingPower.

@codecov-io
Copy link

Codecov Report

❗ No coverage uploaded for pull request base (develop@3f987ad). Click here to learn what that means.
The diff coverage is 100%.

@@            Coverage Diff             @@
##             develop    #2932   +/-   ##
==========================================
  Coverage           ?   62.76%           
==========================================
  Files              ?      212           
  Lines              ?    17294           
  Branches           ?        0           
==========================================
  Hits               ?    10855           
  Misses             ?     5524           
  Partials           ?      915
Impacted Files Coverage Δ
rpc/core/consensus.go 0% <ø> (ø)
consensus/state.go 79.64% <100%> (ø)
state/execution.go 72.79% <100%> (ø)
state/state.go 90.9% <100%> (ø)
state/store.go 69.28% <100%> (ø)
p2p/metrics.go 17.94% <100%> (ø)

Copy link
Contributor

@ValarDragon ValarDragon left a comment

Choose a reason for hiding this comment

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

Awesome!

@ebuchman ebuchman merged commit b30c34e into develop Nov 28, 2018
@ebuchman ebuchman deleted the 2915_rename_accum branch November 28, 2018 20:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants