Skip to content

rename Accum -> ProposerPriority#2932

Merged
ebuchman merged 2 commits intodevelopfrom
2915_rename_accum
Nov 28, 2018
Merged

rename Accum -> ProposerPriority#2932
ebuchman merged 2 commits intodevelopfrom
2915_rename_accum

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.

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
cboh4 pushed a commit to scrtlabs/tendermint that referenced this pull request Apr 7, 2025
…int#2932)

Closes tendermint#2923 

Caches the block hash to ensure we only compute it once in consensus
execution.

---

#### PR checklist

- [x] Tests written/updated - not sure what test I should write, any
suggestions?
- [x] Changelog entry added in `.changelog` (we use
[unclog](https://github.com/informalsystems/unclog) to manage our
changelog)
- [ ] Updated relevant documentation (`docs/` or `spec/`) and code
comments
- [x] Title follows the [Conventional
Commits](https://www.conventionalcommits.org/en/v1.0.0/) spec
<hr>This is an automatic backport of pull request tendermint#2924 done by
[Mergify](https://mergify.com).

---------

Co-authored-by: Dev Ojha <ValarDragon@users.noreply.github.com>
Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
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.

5 participants