Alessio Treglia
3744e8271d
[R4R] Pass nil to NewValidatorSet() when genesis file's Validators field is nil ( #2617 )
...
* Pass nil to NewValidatorSet() when genesis file's Validators field is nil
Closes : #2616
* Update CHANGELOG_PENDING.md
2018-10-11 23:37:21 -04:00
Anton Kaliaev
0e1cd88863
Remove ConsensusParams.TxSize and ConsensusParams.BlockGossip ( #2364 )
...
* remove ConsensusParams.TxSize and ConsensusParams.BlockGossip
Refs #2347
* block part size is now fixed
Refs #2347
* use max data size, not max bytes for tx limit
Refs #2347
2018-09-12 15:44:43 -04:00
Zarko Milosevic
7b88172f41
Implement BFT time ( #2203 )
...
* Implement BFT time
* set LastValidators when creating state in state helper
for heights >= 2
2018-08-31 19:33:51 -04:00
Ethan Buchman
e1062a657f
fixes for ProposerAddress
...
- state.MakeBlock takes a proposerAddr
- validateBlock only checks that the ProposerAddress is in the validator
set
- fix raceyness from bad proposer test:
- use privValidator to get the proposer address (instead of racy
state)
- note we had to remove the test that checked the correct proposer was
included for higher rounds because we don't have a good way to test
this with multiple consensus states and not using the
privValidator.Address while calling createProposalBlock was a hack!
2018-08-05 15:19:21 -04:00
Anton Kaliaev
bec9d5cba9
add proposer address to block's Header
...
Refs #1134
Validation:
- ignored in block.ValidateBasic since it's stateful information
- checked in blockExec.ValidateBlock
2018-08-05 15:16:49 -04:00
Ethan Buchman
2d1c5a1ce6
Merge remote-tracking branch 'origin/develop' into jae/literefactor4
2018-08-02 19:12:22 -04:00
Ethan Buchman
6046b99197
consensus: include evidence in proposed block parts. fixes #2050
2018-07-24 21:58:39 -04:00
Jae Kwon
a5b7ea93c4
Delay validator set changes by 1 block.
2018-06-25 16:59:00 -07:00
Ethan Buchman
dd62f06994
state: s -> state
2018-06-04 21:20:23 -07:00
Jae Kwon
89cdde7f1e
Fix state tests
2018-04-03 06:50:53 -07:00
Ethan Buchman
eaafd9d61c
state: builds
2018-03-02 01:51:27 -05:00
Ethan Buchman
1d6f00859d
fixes from review
2017-12-28 23:15:54 -05:00
Ethan Buchman
0acca7fe69
final updates for state
2017-12-28 23:15:54 -05:00
Ethan Buchman
f82b7e2a13
state: re-order funcs. fix tests
2017-12-28 23:15:54 -05:00
Ethan Buchman
9e6d088757
state: BlockExecutor
2017-12-28 23:15:54 -05:00
Ethan Buchman
c915719f85
*State->State; SetBlockAndValidators->NextState
2017-12-28 23:15:54 -05:00
Ethan Buchman
f55135578c
state: move methods to funcs
2017-12-28 23:15:54 -05:00
Ethan Buchman
6a4fd46479
fixes from rebase
2017-12-26 20:42:34 -05:00
Ethan Buchman
cc418e5dab
state.VerifyEvidence enforces EvidenceParams.MaxAge
2017-12-26 20:27:32 -05:00
Ethan Buchman
3271634e7a
types: evidence cleanup
2017-12-26 20:26:21 -05:00
Ethan Buchman
6c4a0f9363
cleanup evidence pkg. state.VerifyEvidence
2017-12-26 20:26:21 -05:00
Ethan Buchman
051c2701ab
remove LastConsensusParams
2017-12-26 19:56:39 -05:00
Ethan Buchman
028ee58580
call it LastResultsHash
2017-12-26 19:53:26 -05:00
Ethan Buchman
73fb1c3a17
consolidate saveResults/SaveABCIResponses
2017-12-26 19:24:45 -05:00
Ethan Frey
d65234ed51
Add /block_results?height=H as rpc endpoint
...
Expose it in rpc client
Move ABCIResults into tendermint/types from tendermint/state
2017-12-26 19:24:25 -05:00
Ethan Frey
58c5df729b
Add ResultHash to header
2017-12-26 19:24:25 -05:00
Ethan Frey
632cc918b4
Save/Load Results for every height
...
Add some tests.
Behaves like saving validator set, except it always saves at each height
instead of a reference to last changed.
2017-12-26 19:24:25 -05:00
Ethan Frey
f870a49f42
Add ABCIResults with Hash and Proof to State
...
State maintains LastResultsHash
Verify that we can produce unique hashes for each result,
and provide valid proofs from the root hash.
2017-12-26 19:24:25 -05:00
Ethan Buchman
35521b553a
save historical consensus params
2017-12-21 17:46:25 -05:00
Ethan Buchman
70a744558c
types: params.Update()
2017-12-21 17:00:52 -05:00
Ethan Buchman
3d00c477fc
separate block vs state based validation
2017-12-21 16:49:47 -05:00
Anton Kaliaev
0ffd60b8cf
ValidatorSetUpdates -> ValidatorUpdates
2017-12-21 11:52:26 -06:00
Anton Kaliaev
843e1ed400
Updates -> ValidatoSetUpdates
2017-12-19 13:03:39 -06:00
Ethan Frey
960b25408f
Store LastConsensusHash in State as well
...
Update all BlockValidation that it matches the last state
2017-12-19 12:28:08 -05:00
Ethan Frey
d151e36ea8
Add ConsensusHash to header
2017-12-19 12:28:08 -05:00
Ethan Frey
56cada6a0c
Validate ConsensusParams returned from abci app
2017-12-19 12:28:08 -05:00
Ethan Frey
030fd00232
Added tests for applying consensus param changes
2017-12-19 12:28:08 -05:00
Ethan Frey
d21f39160f
Apply ConsensusParamChanges to state/State
2017-12-19 12:28:08 -05:00
Ethan Frey
4265a94bfe
Update EndBlock parameters
...
* Update abci dependencies
* Modify references from Diffs to Changes
* Fixes issues #924
2017-12-19 12:28:08 -05:00
Ethan Frey
dedf03bb81
Add TotalTx to block header, issue #952
...
Update state to keep track of this info.
Change function args as needed.
Make NumTx also an int64 for consistency.
2017-12-13 12:20:53 +01:00
Anton Kaliaev
922af7c405
int64 height
...
uint64 is considered dangerous. the details will follow in a blog post.
2017-12-01 19:04:53 -06:00
Anton Kaliaev
b3492356e6
uint64 height (Refs #911 )
2017-12-01 17:17:22 -05:00
Anton Kaliaev
f65e357d2b
adapt Tendermint to new abci.Client interface
...
which was introduced in https://github.com/tendermint/abci/pull/130
2017-11-29 14:23:44 -06:00
Anton Kaliaev
29cd1a1b8f
rewrite indexer to be a listener of eventBus
2017-11-29 14:23:44 -06:00
Ethan Buchman
c2803b80e8
update changelog; fixes from rebase
2017-10-23 11:13:12 -04:00
Adrian Brink
036d3b59a3
Address reviews
2017-10-23 11:04:45 -04:00
Adrian Brink
782a836db0
Cleanup of code and code docs
...
This cleans up some of the code in the state package
2017-10-23 11:04:45 -04:00
Anton Kaliaev
c4646bf87f
make state#Params not a pointer
...
also remove the comment
2017-10-16 10:34:02 +04:00
Anton Kaliaev
716364182d
[state] expose ChainID and Params
...
```
jaekwon
Yeah we should definitely expose ChainID.
ConsensusParams is small enough, we can just write it.
```
https://github.com/tendermint/tendermint/pull/676#discussion_r144123203
2017-10-16 10:34:02 +04:00
Anton Kaliaev
1971e149fb
ChainID() and Params() do not return errors
...
- remove state#GenesisDoc() method
2017-10-16 10:34:02 +04:00