Commit Graph

198 Commits

Author SHA1 Message Date
Paul Hauner
343909ef31
Fix boolean-bitfield serialization 2019-04-17 17:17:07 +10:00
Paul Hauner
c3779caede
Add extra info to block proc. error message 2019-04-17 13:59:40 +10:00
Michael Sproul
f592183aa9
Fix signed_root vs tree_hash_root in per_slot 2019-04-17 12:00:24 +10:00
Michael Sproul
701cc00d08
questionable patch for TreeHashVector 2019-04-17 12:00:23 +10:00
Michael Sproul
d95ae95ce8
spec: update tags to v0.5.1 2019-04-17 12:00:23 +10:00
Michael Sproul
2914d77cd3
spec: update to v0.5.1 2019-04-17 12:00:23 +10:00
Michael Sproul
4f63c89bb6
jenkins: run all state tests 2019-04-17 12:00:23 +10:00
Michael Sproul
a19f8580f5
travis: state transition tests 2019-04-17 12:00:23 +10:00
Michael Sproul
32547373e5
spec: simplify cache_state
The `latest_block_root` input argument was unnecessary as we were always setting it to something
almost equivalent to `state.latest_block_root` anyway, and more importantly, it was messing up the
caching of the state root. Previously it was possible for the function to update the state's latest
block root, and then hash the outdated block root that was passed in as an argument.
2019-04-17 12:00:23 +10:00
Michael Sproul
19fad1012f
state transitions tests: check more fields 2019-04-17 12:00:22 +10:00
Michael Sproul
b21cc64949
state transition tests: check expected state 2019-04-17 12:00:22 +10:00
Michael Sproul
71a0fed8eb
testing: add a fake_crypto feature 2019-04-17 12:00:22 +10:00
Michael Sproul
300fcd6ec3
state transition test progress 2019-04-17 12:00:22 +10:00
Michael Sproul
0a02567440
bitfield: fix bit ordering issue with YAML parsing 2019-04-17 12:00:22 +10:00
Michael Sproul
8da8730dca
spec: check ProposalSlashing epochs, not slots
As per v0.5.{0,1} of the spec, we only need to check that the epochs of two proposal slashings are
equal, not their slots.
2019-04-17 12:00:21 +10:00
Paul Hauner
49d066015b
Make genesis beacon state return a beacon state 2019-04-17 10:33:31 +10:00
Paul Hauner
f69b56ad60
Add new tree_hash crate project wide. 2019-04-16 14:25:43 +10:00
Paul Hauner
b8c4c3308a
Update types to new tree_hash crate 2019-04-16 14:14:38 +10:00
Paul Hauner
89bc15f77e
Move some long-running tests to release-only 2019-04-15 09:59:35 +10:00
Paul Hauner
914e0cf1fc
Skip long-running tests in debug 2019-04-03 17:27:32 +11:00
Paul Hauner
1913be0c6f
Fix clippy lints 2019-04-03 16:23:09 +11:00
Paul Hauner
38f2cb9555
Run rustfmt 2019-04-02 14:30:32 +11:00
Paul Hauner
3fe7dd80e2
Merge branch 'validator-enhancements' into testnet-client 2019-04-02 14:29:43 +11:00
Paul Hauner
e53e23175a
Merge pull request #330 from sigp/state-transition-tests
[WIP] State transition tests
2019-04-02 14:01:23 +11:00
Paul Hauner
206f651895
Merge pull request #293 from michaelsproul/operation-pool
Implement Operation Pool
2019-04-02 13:53:22 +11:00
Paul Hauner
bd860eb3e1
Fixes bug in epoch processing.
- Was using the wrong slot to determine relative epoch.
- Added a non-related test I build during the search
2019-03-31 15:30:09 +11:00
Paul Hauner
b5f176a152
Merge branch 'master' into blop-pool 2019-03-29 17:49:33 +11:00
Kirk Baird
c1d7e26cac
Merge branch 'yaml-test-downloads' into state-transition-tests 2019-03-29 11:48:26 +11:00
Kirk Baird
023b4e8c92
Merge master and remove ssz length encoding from FakeBLS 2019-03-29 11:47:22 +11:00
Paul Hauner
b887509607
Fix double advance-cache calls bug 2019-03-27 10:35:46 +11:00
Kirk Baird
033ae1b747
WIP begin testing 2019-03-26 18:28:29 +11:00
Michael Sproul
99dbed86f1
types: PendingAttestation::from_attestation 2019-03-26 18:20:01 +11:00
Kirk Baird
9d65ee130d
Include yaml-utils/specs folder 2019-03-25 18:42:41 +11:00
Kirk Baird
d76baa1cc1
Allow downloading of large tests from EF github and fix issues with serde 2019-03-25 18:02:37 +11:00
Michael Sproul
518359e898
op-pool: implement attester slashings 2019-03-25 16:58:20 +11:00
Michael Sproul
e512f7c0e1
op-pool: validate_attestation_time_independent_only 2019-03-25 11:29:03 +11:00
Michael Sproul
95ed402228
op-pool: rename to verify_*_time_independent_only 2019-03-25 11:29:03 +11:00
Michael Sproul
b2fe14e12c
Operation pool: refactor verify_deposit/exit 2019-03-25 11:29:03 +11:00
Michael Sproul
8f4a2fbde1
Implement transaction pool basics 2019-03-25 11:29:03 +11:00
Kirk Baird
8fd2e47e99
Modifications to serde 2019-03-22 16:10:43 +11:00
Kirk Baird
192a49a23d Merge branch 'master' of github.com:sigp/lighthouse into v0.5.0-state-transition-tests 2019-03-22 09:23:56 +11:00
Paul Hauner
84f373fcc2
Fix clippy lints 2019-03-20 10:51:53 +11:00
Paul Hauner
baca2c90ab
Add last of 0.5.0 upgrades. Woo! 2019-03-19 19:43:31 +11:00
Paul Hauner
35b90728c7
Push more epoch processing fns to 0.5.0 2019-03-19 19:27:10 +11:00
Kirk Baird
26f8694161
Begin updating serde such that it can read the yaml test files 2019-03-19 18:05:05 +11:00
Paul Hauner
61f6fe25e7
Tidy reward processing 2019-03-19 17:26:20 +11:00
Paul Hauner
d20fb93f0c
Update rewards processing to v0.5.0 2019-03-19 17:16:51 +11:00
Paul Hauner
37b8e9f39a
Move get_active_validator_indices to state 2019-03-19 09:09:57 +11:00
Paul Hauner
1028acf3f1
Move state trans fns into state_processing 2019-03-18 21:34:42 +11:00
Paul Hauner
7503f31ddc
Fix bug with per-block processing 2019-03-18 18:09:31 +11:00
Paul Hauner
edeace9e75
Fix issues with building on genesis block 2019-03-18 16:53:59 +11:00
Paul Hauner
191761f356
Allow epoch cache with zero validators. 2019-03-17 23:32:27 +11:00
Paul Hauner
816c2c651b
Modify genesis processing process.
- Removed BeaconStateBuilder
- Added genesis code to `state_processing`.
2019-03-17 23:11:07 +11:00
Paul Hauner
8677b9e9cc
Fix bug with epoch caches, add tests 2019-03-17 21:07:19 +11:00
Paul Hauner
3a384d93f8
Allow state processing to compile under v0.5.0 2019-03-17 17:47:12 +11:00
Paul Hauner
3b8c1df5da
Fix bug in per block processing. 2019-03-17 12:49:55 +11:00
Paul Hauner
6bd2055a0a
Update block processing to v0.5.0 2019-03-17 12:25:37 +11:00
Paul Hauner
ef86948259
Add bones of YAML state test parsing.
Is incomplete, need to update all our types to v0.5.0 first
2019-03-15 13:32:23 +11:00
Paul Hauner
236b97476a
Marge fixes to test_harness, add serdehex crate 2019-03-15 13:31:30 +11:00
Paul Hauner
96d96ba9ba
Remove assertion in benches 2019-03-14 20:54:30 +11:00
Paul Hauner
4fd8551e8b
Update loglevel, comments in benches 2019-03-14 17:49:39 +11:00
Paul Hauner
2535f47f13
Add builder for benches
Also adds a "sane" case for block processing
2019-03-14 16:44:56 +11:00
Paul Hauner
ed49023b87
Merge branch 'faster-rewards' into sane-case 2019-03-14 16:11:41 +11:00
Paul Hauner
fc0cdb8226
Start building non-worst case benches 2019-03-14 18:10:36 +13:00
Paul Hauner
1c1c15a122
Tidy per epoch processing
- Add comments to ValidatorStatuses
- Add some checks to guard against a bad statuses list
- Remove unused attester_sets.rs file.
2019-03-14 16:00:22 +11:00
Paul Hauner
10aee6214c
Tidy per_epoch_processing
Mainly renaming variables and files for readability.
2019-03-14 14:59:30 +11:00
Paul Hauner
95599ddc66
Update Attesters struct
- Renames variables
- Moves total balance calculation into struct
2019-03-14 12:49:48 +11:00
Paul Hauner
a319144835
Improve crosslink reward processing 2019-03-14 12:17:43 +11:00
Paul Hauner
6f919e6f7d
Add first iteration on faster rewards processing. 2019-03-14 11:53:50 +11:00
Paul Hauner
587be831b5
Add method for dropping pubkey cache. Add bench. 2019-03-13 16:49:32 +11:00
Paul Hauner
6cd3c4bd1a
Add a cache for public keys to BeaconState
This allows for a fast lookup of "is this public key already in the
validator registry".
2019-03-13 16:40:28 +11:00
Paul Hauner
f949919b9b
Add comments to epoch_processing 2019-03-12 18:02:53 +11:00
Paul Hauner
fbfa233d36
Add debug messages to TestingBeaconStateBuilder 2019-03-12 17:16:12 +11:00
Paul Hauner
cce88c9923
Improve DX for loading validator keys from file 2019-03-12 14:39:16 +11:00
Paul Hauner
f34ae86cde
Add support for loading keypairs from file 2019-03-12 12:46:44 +11:00
Paul Hauner
9de6a0c733
Rename benching files 2019-03-12 09:57:00 +11:00
Paul Hauner
e81f1c31c9
Fix proof-of-possession issues.
These were introduced in an earlier commit
2019-03-11 19:47:33 +11:00
Paul Hauner
292991810d
Move state processing benches around 2019-03-11 19:46:22 +11:00
Paul Hauner
36085f63e9
Rename state trans benches 2019-03-11 14:52:21 +11:00
Paul Hauner
0b7082e2b9
Move benching_utils structs into types 2019-03-11 11:17:27 +11:00
Paul Hauner
6ae99a1462
Ensure drop times aren't included in benchmarks
Also moves to the new `iter_batched` method on criterion (instead of
`iter_with_setup`.
2019-03-11 10:56:31 +11:00
Paul Hauner
53456a6c79
Remove last inclusion_slot(..) call 2019-03-10 21:06:40 +11:00
Paul Hauner
21d75ef0bd
Add tree hash benches 2019-03-10 18:31:14 +11:00
Paul Hauner
f27b62d410
Add optimisation for epoch processing 2019-03-10 17:49:06 +11:00
Paul Hauner
9cc8e2598f
Organise epoch benching file 2019-03-10 17:48:26 +11:00
Paul Hauner
89fc386264
Add extra checks for epoch benches finalization 2019-03-10 13:38:57 +11:00
Paul Hauner
c33e299176
Ensure epoch processing benches get new eth1 data 2019-03-10 12:56:37 +11:00
Paul Hauner
3f98849362
Optimise attester slashing processing. 2019-03-10 08:55:45 +11:00
Paul Hauner
e7fba3a473
Process transfers in parallel. 2019-03-10 08:36:49 +11:00
Paul Hauner
1ca99b8c4c
Optimise deposits processing. 2019-03-10 08:33:17 +11:00
Paul Hauner
5f3da0732f
Fix attestations bug in block builder.
It was previously producing too many attestations in some scenarios.
2019-03-10 08:31:40 +11:00
Paul Hauner
90d00773cb
Add slashings back into per-block processing.
I thought they would invalidate the attestations but I was wrong.
2019-03-10 08:30:36 +11:00
Paul Hauner
c1e386a0b1
Add deposits, transfers and exits to benches 2019-03-09 22:10:47 +11:00
Paul Hauner
6250c81bb9
Fix bug in attestation verification
We were ensuring that a validator was present on the aggregation
bitfield before adding their signature to the agg pub
2019-03-09 20:09:17 +11:00
Paul Hauner
62ab782ee2
Add TestingAttestationBuilder 2019-03-09 20:09:02 +11:00
Paul Hauner
f8ec1e0cfa
Add slashings and attestations to per block benching 2019-03-09 18:56:01 +11:00
Paul Hauner
73ebb4bc2e
Add incomplete per-block processing benchmarks
Still needs to fill block with operations
2019-03-09 14:11:49 +11:00
Paul Hauner
ca5d9658ce
Move epoch processing benches into separate file 2019-03-09 10:45:28 +11:00
Paul Hauner
63743a962c
Add per-epoch benchmarks, optimise function. 2019-03-09 10:38:53 +11:00
Paul Hauner
f479beb87e
Implement deposit merkle root verification.
It is currently disabled, but it's there for later.
2019-03-08 09:26:03 +11:00