Commit Graph

92 Commits

Author SHA1 Message Date
Paul Hauner
177df12149 Testnet stability (#451)
* Change reduced tree for adding weightless node

* Add more comments for reduced tree fork choice

* Small refactor on reduced tree for readability

* Move test_harness forking logic into itself

* Add new `AncestorIter` trait to store

* Add unfinished tests to fork choice

* Make `beacon_state.genesis_block_root` public

* Add failing lmd_ghost fork choice tests

* Extend fork_choice tests, create failing test

* Implement Debug for generic ReducedTree

* Add lazy_static to fork choice tests

* Add verify_integrity fn to reduced tree

* Fix bugs in reduced tree

* Ensure all reduced tree tests verify integrity

* Slightly alter reduce tree test params

* Add (failing) reduced tree test

* Fix bug in fork choice

Iter ancestors was not working well with skip slots

* Put maximum depth for common ancestor search

Ensures that we don't search back past the finalized root.

* Add basic finalization tests for reduced tree

* Change fork choice to use beacon_block_root

Previously it was using target_root, which was wrong

* Change reduced tree for adding weightless node

* Add more comments for reduced tree fork choice

* Small refactor on reduced tree for readability

* Move test_harness forking logic into itself

* Add new `AncestorIter` trait to store

* Add unfinished tests to fork choice

* Make `beacon_state.genesis_block_root` public

* Add failing lmd_ghost fork choice tests

* Extend fork_choice tests, create failing test

* Implement Debug for generic ReducedTree

* Add lazy_static to fork choice tests

* Add verify_integrity fn to reduced tree

* Fix bugs in reduced tree

* Ensure all reduced tree tests verify integrity

* Slightly alter reduce tree test params

* Add (failing) reduced tree test

* Fix bug in fork choice

Iter ancestors was not working well with skip slots

* Put maximum depth for common ancestor search

Ensures that we don't search back past the finalized root.

* Add basic finalization tests for reduced tree

* Add network dir CLI flag

* Simplify "NewSlot" log message

* Rename network-dir CLI flag

* Change fork choice to use beacon_block_root

Previously it was using target_root, which was wrong

* Update db dir size for metrics

* Change slog to use `FullFormat` logging

* Update some comments and log formatting

* Add prom gauge for best block root

* Only add known target blocks to fork choice

* Add finalized and justified root prom metrics

* Add CLI flag for setting log level

* Add logger to beacon chain

* Add debug-level CLI flag to validator

* Allow block processing if fork choice fails

* Create warn log when there's low libp2p peer count

* Minor change to logging

* Make ancestor iter return option

* Disable fork choice test when !debug_assertions

* Fix type, removed code fragment

* Tidy some borrow-checker evading

* Lower reduced tree random test iterations
2019-07-29 13:45:45 +10:00
Age Manning
44c9058477 Integrate discv5 into lighthouse 2019-07-04 14:14:27 +10:00
Paul Hauner
0b2ad4d0a1 Mark reduced_tree fork choice as incomplete 2019-06-24 09:34:54 +10:00
Paul Hauner
3487b16ce5 Add eth2_config crate, integrate into val client 2019-06-08 20:21:50 -04:00
Paul Hauner
d8fc5f31d8 Add Eth2Config to runtime 2019-06-08 13:17:03 -04:00
Paul Hauner
fd6766c268 Tidy beacon node runtime code 2019-06-08 09:46:04 -04:00
Paul Hauner
e74d49fc8a Remove dupe info between ChainSpec and EthSpec 2019-06-08 07:57:25 -04:00
Paul Hauner
e73a31c37f Refactor ClientConfig, add serde to it 2019-06-07 19:44:27 -04:00
Paul Hauner
29c5f297a6 Add database size metric 2019-06-01 14:43:08 +10:00
Paul Hauner
8acffcc0db Make some BeaconChain functions private 2019-05-30 18:38:41 +10:00
Paul Hauner
345f7d5f18 Add global metrics registry, pass to BeaconState 2019-05-28 17:30:09 +10:00
Paul Hauner
3f27fd4edf Parse http CLI args for HTTP server 2019-05-28 13:50:51 +10:00
Paul Hauner
faa682a9b5 Implement saving BeaconChain on client drop 2019-05-27 17:58:15 +10:00
Paul Hauner
9ed8a4d380 Implement basic BeaconChain persistence. 2019-05-27 17:58:15 +10:00
Paul Hauner
ee8d13573f Create BeaconChainTypes, thread through runtime 2019-05-26 15:59:29 +10:00
Paul Hauner
85211ebccd Add basic prometheus endpoint 2019-05-25 17:25:21 +10:00
Paul Hauner
8dd07dd7d2 Add http server to beacon node w/ hello world 2019-05-25 14:31:13 +10:00
Paul Hauner
3bcf5ba706 Rename db crate to store 2019-05-21 18:20:23 +10:00
Paul Hauner
b62f4477e1 More project-wide fixes for new DB 2019-05-21 17:45:35 +10:00
Paul Hauner
fcabef91da Use E for EthSpec trait, instead of B 2019-05-13 14:44:43 +10:00
Paul Hauner
ce8ebeccbc Rename BeaconStateTypes to EthSpec 2019-05-10 14:47:09 +10:00
Paul Hauner
2a938f2fd5 Fix clippy lints 2019-05-09 13:35:00 +10:00
Paul Hauner
4c0c93f0c9 Update beacon_node to work w/ BeaconStateTypes 2019-05-09 09:40:32 +10:00
Paul Hauner
1913be0c6f Fix clippy lints 2019-04-03 16:23:09 +11:00
Age Manning
170f993032 Clean up warnings 2019-04-01 12:14:23 +11:00
Paul Hauner
f18941a01c Block client startup until state is ready 2019-03-27 11:25:15 +11:00
Paul Hauner
b006586d19 Add slot timer to beacon node 2019-03-27 10:36:20 +11:00
Age Manning
05369df7e8 Add PubsubMessage and publish function to behaviour 2019-03-25 22:00:11 +11:00
Age Manning
ca9af49d4e Adds error handling to validator client service 2019-03-25 16:50:15 +11:00
Age Manning
a4cfe68272 Thread beacon node RPC server 2019-03-22 16:46:52 +11:00
Age Manning
ee6a0ccb92 Initial build of server-side BeaconNodeService RPC 2019-03-22 13:37:24 +11:00
Age Manning
4be2eeb792 Correct cli rpc parameters 2019-03-20 09:58:31 +11:00
Age Manning
d2f12b7c18 Add standard RPC service 2019-03-19 23:47:58 +11:00
Age Manning
4b57d32b60 Apply clippy suggestions 2019-03-19 23:20:39 +11:00
Age Manning
e7f87112fb Tidy networking crates 2019-03-19 22:53:51 +11:00
Age Manning
6b5debe654 Organize beacon_chain typing
- Implements ClientTypes
- New network BeaconChain type for the networking service
2019-03-18 17:38:23 +11:00
Age Manning
bbad4bfa19 Starts initialisation of beacon chain in the client 2019-03-18 16:16:54 +11:00
Age Manning
9803ab30f2 Propagate RPC through network service.
- Basic network message handler threading
- Correct references
2019-03-17 21:49:56 +11:00
Age Manning
ae983a9347 Basic networking service with channel 2019-03-12 17:28:11 +11:00
Age Manning
b68adc1ae3 Implement skeleton network/sync framework. 2019-03-04 18:31:01 +11:00
Age Manning
3b8f29a914 [Temp Commit] Implements more basic skeleton code. 2019-03-04 16:39:37 +11:00
Age Manning
2e020a3efa Implement the basic structure of the beacon node. 2019-03-03 18:28:12 +11:00