Commit Graph

360 Commits

Author SHA1 Message Date
Jerry Fireman
79eb9a5230 Update Get Block Root function (#1339) 2019-02-05 11:55:15 -06:00
Preston Van Loon
58ca71af23 Insert pending deposits (#1495)
* Update config for deposits processing

* Add pending deposits database methods

* oops forgot the files

* move the lock after the nil check

* move the lock after the nil check

* test inclusion behavior

* Insert pending deposits on process deposit log
2019-02-05 11:25:09 -06:00
Preston Van Loon
2a0eae163e
Handle idx panic (#1492)
* fix panic on empty first committee

* fix issue in validator server too
2019-02-05 11:15:54 -05:00
Preston Van Loon
4b27b8408b
Fix travis (#1493)
* fix travis

* test 2

* goimports

* Remove unused p2p config

* remove unused var
2019-02-05 10:46:32 -05:00
Preston Van Loon
4fc8a3881a
Use a better message for notifying of a new deposit (#1491) 2019-02-05 09:07:42 -05:00
Preston Van Loon
4add403335
Validator Proposer Rewrite (#1462)
* WIP - with TODOs

* interface w/ test

* basic test for broadcast

* Add computeStateRoot funciton

* remove custody challenge

* resolve TODO lint issues

* more TODOs

* revert new line in types.proto

* broadcaster comment

* one of several failure condition tests

* Add test cases

* handle compute state error test case

* fix config in validator helpers

* fix tests too

* fix conflict

* partial PR feedback

* remove p2p

* gazelle

* package comment

* Better godoc
2019-02-05 08:47:25 -05:00
Preston Van Loon
45a4442f53
fix config in validator helpers (#1483)
* fix config in validator helpers

* fix tests too
2019-02-04 20:56:08 -05:00
Andrei Ivasko
4672859832 Create RPC health check (#1385)
* rpcHealth

* TestBadEndPoint not passed

* Crasher and TestCrasher()

* panic and recover

* assertPanic , TestBadEndPoint failed because of panic in goroutine

* log not found: Starting go routine

* TestLogger implementation

* Testlogger with map  and overriden Fatalf

* rebased

* testLogger - modified the severity of message - added TestStatus - goimports

* fix test issues

* fmt
2019-02-04 15:54:30 -06:00
terence tsao
720c80d8ee Aligning ETH2.0 spec - Make Epoch First Citizen (Package: Committee) (#1477)
* able to bazel build beacon chain.. yay

* fixed package validator tests

* fixed a few more package tests (epoch, blockops, forkchoice)

* fixed all the tests! and lint. Woohoo

* moving committee helpers to own package

* more fixes at epoch processing

* fixed rewards and penalties tests

* fixed rest of the tests. yay
2019-02-04 15:27:28 -06:00
terence tsao
21ac564631
Aligning ETH2.0 spec - Make Epoch First Citizen (Package: Validators) (#1460) 2019-02-04 21:34:33 +01:00
Preston Van Loon
721a3bfb6a Pending deposits db (#1475)
* Update config for deposits processing

* Add pending deposits database methods

* oops forgot the files

* move the lock after the nil check

* test inclusion behavior

* Update db.go

* Add debug logs if processing nil data

* missing return statement

* /before/until/
2019-02-04 21:47:17 +08:00
terence tsao
d1df055ab1
Aligning ETH2.0 spec - Removed Balances from Validator Proto (#1470) 2019-02-04 08:31:43 +01:00
terence tsao
176aa2688e
Implement Attestation Pool for Fork Choice (#1402) 2019-02-04 00:05:34 +01:00
Raul Jordan
088507af66
Initialize State from ChainStart Deposits in POWChainService (#1474)
* tests passing once again in db package

* fixed all tests

* revert some weird p2p changes made accidentally

* fix repeated code

* build fixed

* fix p2p

* fix all tests
2019-02-03 16:44:48 -06:00
Preston Van Loon
30080656bc Update config for deposits processing (#1473) 2019-02-03 20:21:18 +01:00
Nishant Das
9a4418c990
Clean Up Simulated Backend (#1433)
* initialize beacon state separately

* extracting out testcase into another func

* creating function for simulated objects

* creating simulated object struct

* final clean up

* documentation

* lint

* review comments
2019-02-03 18:58:36 +08:00
Ivan Martinez
5b209a2b18 Update DepositRoot to Eth1Data (#1403)
* update proto fileds

* Start writing ProcessETH1Data function

* More progress on tests

* Continue more work on tests

* Fix almost all the tests

* Fix all tests

* Fix everything

* Fix after rebase

* Fix for suggestions and fix per-epoch operation

* Remove method usage

* Fix build

* Fix suggestions

* Fix merge issues and suggestions

* Fix rebase issues

* Remove the error from ProcessETH1Data

* WIP write test

* Update test to reach crosslinks

* Revert "Update test to reach crosslinks"

This reverts commit 5ff9177f96c12c98c54eafffcfb385bd966b0888.

* Revert "WIP write test"

This reverts commit f7e7ed715c4af6b7e3c95643f7ebf85830caf638.
2019-02-02 16:24:42 -05:00
terence tsao
3acffd878c
Aligning ETH2.0 spec - RANDAO helpers (#1454) 2019-02-01 22:22:52 +01:00
terence tsao
cdf50e2fa2 Aligning ETH2.0 Spec - Implemented Slot & Epoch Helpers (#1447)
* starting to use SlotToEpoch...

* updated exisiting functions...

* fixed epoch tests

* fixed rest of the tests

* tests for newly added helper functions

* fixed visiblity

* added PrevEpoch and NextEpoch helpers

* lint

* removed file from other commit
2019-02-02 00:52:35 +08:00
terence tsao
72542d5fc7
removed exit count (#1455) 2019-02-01 17:07:11 +01:00
terence tsao
8c355497ee
Beacon Block Operation Pool to store Attestation (#1444) 2019-01-31 19:54:24 +01:00
terence tsao
3eff953df3
Inclusion Distance with Multiple Attestations (#1404) 2019-01-31 10:33:12 +01:00
Raul Jordan
cec6c8de83 Standardize Naming of Shared Packages, Remove Deprecated Packages (#1435)
* rem txpool

* standardize repo shared utils, remove deprecated items

* complete

* package lvl godoc
2019-01-31 10:53:58 +08:00
terence tsao
844f61d32c
fixed test (#1440) 2019-01-30 20:59:33 +01:00
terence tsao
665f3f885c
New Operation Service Part 1 - Sync and DB connection (#1437) 2019-01-30 20:48:50 +01:00
Raul Jordan
425ec4eee1
Add NoSigVerification Option to State Transition (#1434)
* no sig verify

* gofmt
2019-01-30 13:45:01 +01:00
Raul Jordan
ec9240106e
Implement WaitForChainStart RPC Server and Client (#1421) 2019-01-30 13:28:53 +01:00
terence tsao
c0f36e467b
Eliminate Custody Logic for Phase 0 (#1408) 2019-01-30 11:11:13 +01:00
terence tsao
a52f73b78f
Remove Shard Committees Last Part (#1411) 2019-01-29 14:56:32 +01:00
Raul Jordan
07c0387be1
Validator Epoch Assignments RPC Implementation (#1419)
* begin reorder

* move into beacon server

* add proposer server

* fix

* add proposer server

* wrap up rpc reorder

* eliminated deprecated RPC endpoints

* formatted nicely

* RPC protos

* fix lint

* integrate hash proto

* epoch assignments

* deprecated committee code

* remove deprecated messages

* fixed mocks, added tests for validator epoch assignments

* gazelle

* fix broken bazel

* nishant comment
2019-01-29 13:56:14 +01:00
terence tsao
9e6782da04
add spec comments to fork choice functions (#1401) 2019-01-29 12:19:17 +01:00
Ivan Martinez
e9cfc08549 Update all beacon constants to latest in spec (#1407)
* Update all beacon constants

* Fix documentation

* Fix sync time in config

* Fix some names
2019-01-29 12:16:50 +08:00
Raul Jordan
4c46b02dac
Deprecating Old RPC Methods (#1410)
* begin reorder

* move into beacon server

* add proposer server

* fix

* add proposer server

* wrap up rpc reorder

* eliminated deprecated RPC endpoints

* formatted nicely

* RPC protos

* fix lint

* integrate hash proto

* autoclean

* deprecate all old code

* include the rest of methods mocks

* bazel run

* lint fixes
2019-01-28 20:41:04 +01:00
Raul Jordan
b86388410d
Restructure RPC Server Into Individual Servers (#1393)
* begin reorder

* move into beacon server

* add proposer server

* fix

* add proposer server

* wrap up rpc reorder

* gazelle

* lint fix

* fix broken build
2019-01-28 16:40:40 +01:00
Raul Jordan
98a4274b81
Refactor ChainService for Synchronous Tests and ChainStart (#1347)
* can now test blockchain service synchronously

* completed chainstart listener

* fix comment

* completed refactor

* fix

* fix build

* rem genesis fetch

* fix broken

* fixed concurrency bug

* comments
2019-01-28 19:59:37 +08:00
Nishant Das
1e862511aa
Replace Solidity Contract With Vyper (#1343)
* adding deposit contract

* Adding bindings

* remove unused info

* shifting deploy function over

* new changes

* fixing tests and moving log utils to contract package

* new changes,helpers, fixing tests

* fix failing test

* readme

* contract change

* changes to contract

* new changes,helpers, fixing tests

* missing files

* adding constructor to contract

* lint

* updating with spec

* finally got it fixed

* add in deposit arguments

* new changes

* all tests pass

* addresing raul's and terence's comments

* remove vrc
2019-01-28 16:45:28 +08:00
Ivan Martinez
8d88394b28 Hotfix/rename caspervotes (#1384)
* Begin renaming

* Missing goimports

* Continue rename

* Fix errors and mismatches

* Run proto script

* Fix proto

* Fix some more issues

* Fix tests
duh

* Fix goimports
2019-01-28 14:13:37 +08:00
Raul Jordan
4d43f5128a Remove Simulator Service (#1392)
* remove all instances of simulator service

* fix flag decl

* fix lint
2019-01-27 12:51:44 -08:00
Arun Kumar
f661053ea3 Update ProcessValidatorExits spec definition in comment (#1398) 2019-01-26 13:19:36 +08:00
terence tsao
af1c382828
Remove Shard Committees 5 - Align Core Package (#1379) 2019-01-25 08:20:02 -08:00
Dean Eigenmann
5d4af67e7d Update attestation_test.go (#1394) 2019-01-25 20:00:01 +08:00
Ivan Martinez
858231c90c Change baserewardquotient to spec and remove Gwei from config (#1388)
* Change baserewardquotient to spec and remove Gwei from config

* Attempt to fix test

* Fix tests
2019-01-25 15:10:53 +08:00
Preston Van Loon
956721fe43 Simplified validator workflow 2 - updateAssignments (#1371)
* Add attestation p2p messages

* first pass refactor

* lint

* viz fix

* comment unused const for now

* Add opentracing spans

* PR feedback

* added updateAssignments implementation

* update proto

* handle error in runner

* only do updates on epoch start

* gazelle

* goimports
2019-01-25 11:26:03 +08:00
Ivan Martinez
45e9eda43c Normalize ETH to Gwei client-wide (#1381) 2019-01-24 15:29:04 -08:00
terence tsao
821e7148f8
Remove Shard Committees 4 - Validator Registries Processing (#1368) 2019-01-23 23:09:52 -08:00
terence tsao
987b6e53b8
Remove Shard Committees 3 - Get RANDAO Mix Helper (#1364) 2019-01-23 22:44:19 -08:00
terence tsao
5cb361895d
Rm Shard Committees 2 - Get Crosslink Committees Helpers (#1360) 2019-01-21 23:38:26 -08:00
Ed Mazurek
10b237e72d db methods: remove Get prefix (#1351)
* db methods: remove Get prefix for getter functions

* db methods: consistent test names by removing Get
2019-01-21 17:34:11 +08:00
Nishant Das
7ff544fddf
Fix travis and Other Linter Errors (#1356)
* fix travis and other linter errors

* remove megacheck
2019-01-21 13:35:34 +08:00
terence tsao
779bccba1e
Rm Shard Committees 1 - Update Protos and Configs (#1353) 2019-01-20 10:26:33 -08:00