Paul Hauner
da74c4ce74
Add tree shrinking for u64 vec
2019-04-14 16:50:00 +10:00
Paul Hauner
9bc0519092
Add tree shrink fn
2019-04-14 16:31:47 +10:00
Paul Hauner
582f465ffd
Add test for growing vec of structs
2019-04-14 14:20:33 +10:00
Paul Hauner
737e6b9a86
Fix failing tree hash test
2019-04-14 13:54:04 +10:00
Paul Hauner
e038bd18b5
Add failing test for grow merkle tree
2019-04-14 10:34:54 +10:00
Paul Hauner
1ce1fce03c
Fix failing grow tree test
2019-04-13 17:28:27 +10:00
Paul Hauner
42d6a39832
Refactor TreeHashCache splice method
2019-04-13 13:18:18 +10:00
Paul Hauner
0420607ff1
Tidy, remove debug prints
2019-04-13 13:02:41 +10:00
Paul Hauner
0b186f772f
Refactor resize functions for clarity
2019-04-13 12:12:56 +10:00
Paul Hauner
75177837d0
Add first pass of grow cache algo
2019-04-13 09:42:43 +10:00
Paul Hauner
a124042e30
Start implementing grow merkle fn
2019-04-13 09:11:19 +10:00
Paul Hauner
d79616fee6
Fix failing struct vec vectors
2019-04-12 16:52:11 +10:00
Paul Hauner
48cf75e394
Add failing test for extending struct list
2019-04-12 15:05:26 +10:00
Paul Hauner
55ee8e20ae
Add more passing tests for vec hash caching
2019-04-11 17:40:11 +10:00
Paul Hauner
0bdd61e564
Fix failing vec hashing test
2019-04-11 17:21:57 +10:00
Paul Hauner
0c0eebd774
Add progress on variable list hashing
2019-04-11 12:57:36 +10:00
Paul Hauner
e5783d43a9
First passing vec modified cache test
2019-04-10 16:59:14 +10:00
Paul Hauner
56fe15625b
Allow for building cached vec
2019-04-10 15:47:42 +10:00
Paul Hauner
19465268ec
Merge branch 'master' into simple-cached-tree-hash
2019-04-08 19:50:55 +10:00
Luke Anderson
3ad40dac9b
Fixed *all* cargo fmt
2019-04-08 15:39:26 +10:00
Luke Anderson
177a351462
Added deterministic keypair generation.
...
- The Account Manager has a new subcommand, allowing generation of deterministic keys given a particular validator index.
- Split functionality in generate_deterministic_keypair function
- Fixed up READMEs to reflect new functionality & correct naming.
2019-04-08 15:02:11 +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
1d34e2b2a5
Fix bug in bitfield.
2019-04-02 15:34:18 +11:00
Paul Hauner
f61db9cac8
Fix merge conflict in bls
...
Issue came about from Michael and Kirk doing simultaneous work.
2019-04-02 15:33:38 +11:00
Paul Hauner
3a42d7fa6e
Disable some blop pool tests during debug
2019-04-02 15:33:18 +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
Age Manning
3f160d3b99
Correct bootnodes cli parameter
2019-04-01 16:29:11 +11:00
Michael Sproul
ddd9654f70
op-pool: fix bug in attestation_score
...
The attestation scoring function was looking only at the previous epoch, but
should really look at whichever epoch is appropriate for a given attestation.
We also avoid including attestations that don't pay us any reward, as they
simply bloat the chain.
2019-04-01 13:50:09 +11:00
Paul Hauner
9a0ebac687
Merge branch 'validator-enhancements' into paul-gossip-test
2019-03-31 17:47:35 +11:00
Paul Hauner
a93f898946
Improve gossipsub block processing
2019-03-31 17:27:04 +11:00
Age Manning
e0b5e74e7c
Removes further unneccessary debug output
2019-03-31 15:48:11 +11:00
Age Manning
b5ae39dda0
Merge remote-tracking branch 'origin/paul-gossip-test' into validator-enhancements
2019-03-31 15:36:39 +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
Age Manning
33473892f2
Validator client fixes. Hack fix for genesis start time
2019-03-31 14:26:58 +11:00
Age Manning
b4c21ccca3
Merge remote-tracking branch 'origin/paul-gossip-test' into validator-enhancements
2019-03-31 13:58:38 +11:00
Paul Hauner
b26f1f8e1c
Add build_all_caches
method to BeaconState
...
Also adds a few more cache builds in BeaconChain.
2019-03-31 13:42:49 +11:00
Age Manning
77fb738c78
Merge latest gossip branch
2019-03-31 11:02:57 +11:00
Paul Hauner
d2b5cf5a32
Improve queueing in SimpleSync
2019-03-31 09:44:58 +11:00
Age Manning
4fb95d06d1
Correct cache race condition
2019-03-31 00:08:55 +11:00
Age Manning
fc5142c09a
Registers the attester service to the beacon node RPC client
2019-03-30 19:32:32 +11:00
Paul Hauner
c2b6f949c0
Restrict blop pool from re-including attestations
2019-03-30 18:25:32 +11:00
Age Manning
a952acb86f
Add committee_len to attestation data
2019-03-30 17:20:33 +11:00
Paul Hauner
ed6d0b46d0
Add committee len to AttesterDuties
2019-03-30 17:16:04 +11:00
Age Manning
bb8938c564
Use AttestationDuty in epoch duties
2019-03-30 17:14:38 +11:00
Paul Hauner
dbcc88ad67
Ensure BitVec is initialized using a multiple of 8
...
I found it was panic-ing when supplied a non-power-of-zero len.
2019-03-30 17:13:23 +11:00
Age Manning
bc305cacc2
Merge branch 'blop-pool' into validator-enhancements
2019-03-30 16:16:30 +11:00
Paul Hauner
397e104f9b
Implement Attestation
building in test harness
2019-03-30 16:02:09 +11:00
Age Manning
6e254551af
Implement produce beacon block on gRPC beacon node server
2019-03-30 15:58:31 +11:00
Age Manning
d3a6d73153
Implements Signer generic for validator client and epoch duties
2019-03-30 14:27:37 +11:00
Age Manning
ba771282fa
Merges in validator client branch
2019-03-30 13:17:24 +11:00
Paul Hauner
cd9494181c
Push RwLock down into OperationPool
...
There used to be one massive lock on `BeaconChain.op_pool`, however that
would cause unnecessary blocking.
2019-03-30 12:26:25 +11:00
Paul Hauner
46a978a5a9
Implement op pool for all ops execpt attestations
2019-03-29 18:30:03 +11:00
Paul Hauner
dd2351020c
Impl add_aggregate
for FakeAggSig
2019-03-29 17:58:02 +11:00
Paul Hauner
b5f176a152
Merge branch 'master' into blop-pool
2019-03-29 17:49:33 +11:00
Paul Hauner
fc17d5fea4
Fix failing tree hash tests
2019-03-29 14:37:27 +11:00
Paul Hauner
e0104e6199
Move offset_handler construction into self
2019-03-29 13:04:01 +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
267c978abb
Tidy cache hash API
2019-03-29 02:36:34 +11:00
Age Manning
68b33620c2
Implement Display and clean validator output
2019-03-29 02:23:03 +11:00
Paul Hauner
7b05c506df
Add new build method for cached hashes
2019-03-29 00:47:42 +11:00
Age Manning
1e760d6719
Add Display for PublicKey
2019-03-29 00:43:53 +11:00
Paul Hauner
40bfd5a6c7
Add offset manager method to cache hash trait
2019-03-28 23:58:27 +11:00
Paul Hauner
2dcf1c857c
Fix failing cache hashing test
2019-03-28 23:21:24 +11:00
Luke Anderson
87acaac8a0
Ran cargo fmt.
2019-03-28 21:01:47 +11:00
Luke Anderson
ba71e8adca
Merged age-validator-client into luke's changes on validator_client, and fixed all the merge conflicts.
2019-03-28 20:55:07 +11:00
Paul Hauner
ca0849edc5
Fix cargo fmt error
...
It's a rookie mistake and you hate to see it
2019-03-28 19:02:33 +11:00
Paul Hauner
49639c40ee
Implement failing cache hash test
2019-03-28 19:01:31 +11:00
Age Manning
2a2660ce62
Cleanup debug issues, corrects RPC server logic
2019-03-28 17:24:49 +11:00
Luke Anderson
c9e8fe53bc
Merged Age's changes and ripped out heaps of now obsolete stuff in the validator client.
...
- Replaced most instances of PublicKey with KeyPair, since they need to be passed into each validator thread now.
- Pulled out a bunch of FreeAttestations, and replaced with regular Attestations (as per Paul's suggestion)
- Started generalising pubkeys to 'signers' (though they are still just Keypairs)
- Added validator_index into a few structs where relevant
- Removed the SlotClock and DutiesReader from the BlockProducer and Attester services, since this logic is now abstracted to the higher level process.
- Added a Hash trait to the Keypair (rather than just pubkey) which assumes the Pubkey uniquely defines it.
2019-03-28 15:50:57 +11:00
Paul Hauner
f21409fee1
Build breaking recursion tests for cache hashing
2019-03-28 14:44:10 +11:00
Age Manning
6f0c0e47c3
Update Validator RPC and cache building
2019-03-28 14:32:02 +11:00
Paul Hauner
0d8d3385be
Pass tree hash caching tests
2019-03-28 14:17:25 +11:00
Paul Hauner
224a967cce
Implement basic vec tree hash cache
2019-03-28 13:05:24 +11:00
Paul Hauner
7af6eecb44
Merge branch 'yaml-test-downloads' into cached-tree-hash
2019-03-28 11:24:15 +11:00
Paul Hauner
31e9853463
Merge branch 'little-endian-ssz' into cached-tree-hash
2019-03-28 11:13:11 +11:00
Paul Hauner
1285f1e9f8
Restructure cached tree hash files, breaks tests
2019-03-28 11:11:20 +11:00
Paul Hauner
3c7e18bdf3
Sanitize for odd leaf count
2019-03-28 10:56:20 +11:00
Luke Anderson
bda381a264
More progress towards getting the attester working.
2019-03-28 09:38:39 +11:00
Paul Hauner
b05787207f
Refactor CachedTreeHash into owned bytes
...
Instead of slices
2019-03-28 09:33:44 +11:00
Paul Hauner
acb1dd47cd
Make tree hash pass tests
2019-03-27 19:31:02 +11:00
Luke Anderson
16706d322f
Merge remote-tracking branch 'origin/master' into validator_client-luke_wip
2019-03-27 19:10:36 +11:00
Paul Hauner
e33d1d0ebb
First passing tree hash test
2019-03-27 18:55:39 +11:00
Paul Hauner
839ff3ea3b
Implement (failing) cached tree hash tests
2019-03-27 18:34:10 +11:00
Paul Hauner
ad4000cbdf
Remove unused code
2019-03-27 17:46:12 +11:00
Paul Hauner
35ceb92f2e
Refactor with TreeHashCache struct
2019-03-27 17:45:27 +11:00
Paul Hauner
e28e97d3c7
Add initial work on tree hash caching
2019-03-27 15:59:27 +11:00
Paul Hauner
0c4306cd18
Move genesis time forward
2019-03-27 11:57:38 +11:00
Paul Hauner
c52da489cb
Merge branch 'master' into paul-gossip-test
2019-03-27 11:26:06 +11:00
Paul Hauner
8733740f8b
Move genesis time closer to now
2019-03-27 10:36:37 +11:00
Paul Hauner
b006586d19
Add slot timer to beacon node
2019-03-27 10:36:20 +11:00
Paul Hauner
b887509607
Fix double advance-cache calls bug
2019-03-27 10:35:46 +11:00
Michael Sproul
e5a3b3dd06
op-pool: attestation tests
2019-03-26 18:29:02 +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
Luke Anderson
1584469b7c
Renamed attestation -> attestation_data for fetch, but not publish, to acknowledge the difference in the spec. Also started implementing the gRPC get_attestation_data functionality in the BeaconNode.
2019-03-26 17:41:43 +11:00
Age Manning
96ccd58414
Merge branch 'libp2p-patch'
2019-03-26 16:49:43 +11:00
Kirk Baird
e12ce2bd5c
Merge branch 'master' into yaml-test-downloads
2019-03-26 16:47:24 +11:00
Kirk Baird
fd2f9d0d15
Remove ssz encoding of length from; Signature, AggregateSiganture, PublicKey, SecretKey
2019-03-26 16:45:25 +11:00
Age Manning
507c8efbfb
Update to latest gossipsub
2019-03-26 16:38:50 +11:00
Paul Hauner
7cba9f4126
Merge branch 'master' into paul-gossip-test
2019-03-26 16:09:47 +11:00
Paul Hauner
9224558e06
Set genesis time for testing state builder
2019-03-26 15:53:49 +11:00
Kirk Baird
336b3a8a59
Consolidate branches
2019-03-26 15:47:16 +11:00
Paul Hauner
00b546e6b8
Update slot clock to use genesis slot
2019-03-26 15:44:28 +11:00
Kirk Baird
864ef137ef
Merge ssz little endian branch
2019-03-26 15:44:01 +11:00
Kirk Baird
299dfe43aa
Add .gitignore to make .../yaml_utils/specs a valid directory again
2019-03-26 15:16:55 +11:00
Age Manning
6955330f6c
Merge branch 'libp2p-patch'
2019-03-26 15:14:29 +11:00
Age Manning
b2ae54043c
Fix libp2p version to specific commit
2019-03-26 15:06:41 +11:00
Kirk Baird
116d995960
Merge current master and fix ssz-fuzzing
2019-03-26 14:53:50 +11:00
Age Manning
52b31b2009
Implement initial pubsub message handling
2019-03-25 23:02:51 +11:00
Age Manning
214fb5b8ff
Merge RPC branch
2019-03-25 21:31:49 +11:00
Kirk Baird
9d65ee130d
Include yaml-utils/specs folder
2019-03-25 18:42:41 +11:00
Luke Anderson
4cdeb6abe5
Progress towards validator signing attestations.
...
- Added a 'beacon_attester' RPC endpoint, so the BeaconNode can supply attestation data.
- Renamed 'attestation_data' to just 'attestation' throughout (except where it is actually just the data structure).
2019-03-25 18:32:27 +11:00
Kirk Baird
2f11b0ff71
Merge branch 'master' into v0.5.0-state-transition-tests
...
Signed-off-by: Kirk Baird <baird.k@outlook.com>
2019-03-25 18:21:12 +11:00
Kirk Baird
df7c04fe16
Merge branch 'master' into v0.5.0-state-transition-tests
...
Signed-off-by: Kirk Baird <baird.k@outlook.com>
2019-03-25 18:04:35 +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
Luke Anderson
2f49289c28
Merged master and fixed merge conflicts with Config updates.
2019-03-25 17:03:17 +11:00
Michael Sproul
518359e898
op-pool: implement attester slashings
2019-03-25 16:58:20 +11:00
Age Manning
209614e373
Merge pull request #295 from sigp/validator-updates
...
Persisting (random) Validator Keys
2019-03-25 14:40:11 +11:00
Michael Sproul
bde7ab79c8
types: aggregate signatures in attestations
2019-03-25 13:53:24 +11:00
Michael Sproul
0bf8cb953e
BLS: wrap AggregateSignature::add_aggregate
2019-03-25 12:44:30 +11:00
Michael Sproul
22a90a0224
op-pool: check previous epoch in get_attestations
2019-03-25 11:56:30 +11:00
Michael Sproul
e512f7c0e1
op-pool: validate_attestation_time_independent_only
2019-03-25 11:29:03 +11:00
Michael Sproul
3396f2f08e
op-pool: propagate errors, sort by transfer fee
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
03c01c8a8d
Operation pool: HashMap instead of BTreeMap
2019-03-25 11:29:03 +11:00
Michael Sproul
05dd936a97
Operation pool: deposit pruning tests
2019-03-25 11:29:03 +11:00
Michael Sproul
9c2dfba843
Operation pool: prune attestations
2019-03-25 11:29:03 +11:00
Michael Sproul
a8224aa4ec
Operation pool: add prune_all
2019-03-25 11:29:03 +11:00
Michael Sproul
8a7c51271e
Bitfield: use BitOr instead of BitAnd for union
...
Closes #314
2019-03-25 11:29:03 +11:00
Michael Sproul
18a7bd243c
Bitfield: implement union/intersection/difference
2019-03-25 11:29:03 +11:00
Michael Sproul
1fca8a063c
Operation pool: add attestation support
2019-03-25 11:29:03 +11:00
Michael Sproul
c2e5d3c45a
BLS: fix description of AggregatePublicKey
2019-03-25 11:29:03 +11:00
Michael Sproul
8f4a2fbde1
Implement transaction pool basics
2019-03-25 11:29:03 +11:00
Paul Hauner
f918f42b28
Merge branch 'master' into paul-sync
2019-03-24 16:36:18 +11:00
Paul Hauner
a57a7c2394
Implement block imports for sync
2019-03-23 18:48:09 +11:00
Kirk Baird
8fd2e47e99
Modifications to serde
2019-03-22 16:10:43 +11:00
Kirk Baird
5204fc81ff
cargo fmt
2019-03-22 14:52:37 +11:00
Kirk Baird
4324097904
Allow for conversion to/from empty_signature
2019-03-22 14:51:49 +11:00
Age Manning
844fdc0fb9
Rename network_id to chain_id
2019-03-22 12:39:45 +11:00
Paul Hauner
dba972c748
Merge branch 'debug-no-crypto' into paul-sync
2019-03-22 10:20:41 +11:00
Paul Hauner
7cbee46227
Add FakeSignature and FakeAggregateSignature
...
They replace Signature and FakeAggregateSignature when compling with
debug. Compiling with release uses the real structs.
2019-03-22 10:08:40 +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
7a75ee3d19
Merge branch 'master' into paul-sync
2019-03-22 07:11:04 +11:00
Paul Hauner
ca18d4390a
Add first changes to syncing logic
...
- Adds testing framework
- Breaks out new `NetworkContext` object
2019-03-21 17:17:01 +11:00