Commit Graph

1209 Commits

Author SHA1 Message Date
Preston Van Loon
1b1e994a80
Set committee assignment deadline to 1 epoch (#3902)
* set deadline to epoch end

* fix vis
2019-10-30 18:35:02 -04:00
Nishant Das
2785a6d5ee
move out of go-routine (#3883) 2019-10-30 13:32:53 +08:00
Preston Van Loon
2b444ea954 Add feature flag to enable shuffled index cache (#3893)
* add feature flag to enable shuffled index cache

* gaz'
2019-10-30 10:26:05 +08:00
Preston Van Loon
0481eb4872
Track finalized block root index and filter in blocks by range (#3873)
* checkpoint progress

* feature flag and test

* return true if feature flag is not on

* add lint msg

* rollback tx if failure

* Revert validator/BUILD.bazel
2019-10-29 11:14:17 -04:00
Nishant Das
f1627c0b67 Make No Genesis Delay the Default (#3878) 2019-10-29 07:31:10 -07:00
terence tsao
3d1b69e945
Inclusion rewards are based off previous epoch (#3855) 2019-10-28 22:39:16 -07:00
Nishant Das
f8c870aa91
Fix Failure Counter (#3850)
* fix bug

* return if not ok

* don't set peer status there

* fix build

* fix test

* fix all other tests

* add regression test

* cosmetic changes
2019-10-29 13:23:55 +08:00
Alex
094f1974be fix-roundRobinSync (#3862) 2019-10-28 15:29:33 -04:00
terence tsao
582c382771 Add tracing and annotation for descendent error (#3859)
* Add annotation

* Revert
2019-10-26 20:26:51 -07:00
terence tsao
c5b0b3c326 Prune states since last finalized (#3856)
* Prune states since last finalized

* Fixed test

* Renmaed to prevFinalizedCheckpt
2019-10-25 18:16:10 -07:00
terence tsao
57036d16f9
Fix remove older than last finalized state (#3847) 2019-10-25 09:51:08 -07:00
Nishant Das
1c4b4c8393 fix references to use ComputeDomain (#3854) 2019-10-25 08:05:53 -07:00
Preston Van Loon
acf11262de Add feature flag for state pruning (#3845)
* Add feature flag for state pruning

* gaz
2019-10-23 23:45:52 -07:00
Preston Van Loon
2d98902eed
Require state to exist when updating finalized checkpoint (#3843)
* require state to exist before saving finalized checkpoint

* Add comment

* gaz

* fix test

* fix test
2019-10-23 22:50:33 -07:00
terence tsao
ae1e435231 Guard against deleting genesis and finalized state in DB (#3842)
* Don't delete boundary state

* Lint

* Test

* Feedback

* Batch and better comment

* Fix test

* zzzzzz

* rmStatesOlderThanLastFinalized
2019-10-23 22:39:41 -07:00
Preston Van Loon
544ce2b4ed add peer to span and log (#3838) 2019-10-23 18:35:08 -07:00
terence tsao
9a0fb5dca1
Delete DB states older than finalized checkpoint (#3824) 2019-10-23 08:30:21 -07:00
Preston Van Loon
27bd188ea8
Add a tool to extract genesis.ssz from existing database (#3827)
* Add a tool to extract genesis.ssz from existing database

* close db

* panic on nil
2019-10-22 22:43:41 -07:00
terence tsao
be5451abef
Removed extra save genesis block root (#3829) 2019-10-22 17:49:18 -07:00
Preston Van Loon
552baf1c21 Revert "Fix Round Robin Test (#3775)" (#3823) 2019-10-22 14:44:52 -07:00
Preston Van Loon
e37e757226 Limit init sync to 15 peers (#3821) 2019-10-22 11:43:07 -07:00
terence tsao
f86b7ac62d
Add State Batch Delete for DB (#3820) 2019-10-22 11:13:41 -07:00
Nishant Das
a440c32155 Blacklist Peer if they fail Handshake too many times (#3815)
* add new changes

* add changes to set

* Revert "add changes to set"

This reverts commit 07fd48c15fede3c592d837e5620cbd6e7020baef.

* Revert "Revert "add changes to set""

This reverts commit 6b84a6017e9939e1bb2cfac3553bcc427a680bcd.

* new changes

* add blacklist

* gaz

* add test

* fix visibility

* Update beacon-chain/sync/rpc_status_test.go

Co-Authored-By: Preston Van Loon <preston@prysmaticlabs.com>

* preston's review
2019-10-21 17:43:44 -07:00
Preston Van Loon
1138c2cb51 Gateway registers gRPC gateway handlers (#3818) 2019-10-21 17:15:57 -07:00
terence tsao
97905c3e79
Refactor operation service.go into smaller files (#3808)
* Different files

* Preston's feedback
2019-10-21 09:37:50 -07:00
Preston Van Loon
d8e70fe83c
do not use mutliple read locks (#3812) 2019-10-20 22:37:39 -07:00
Jim McDonald
5000535907 Waiting condition check prior to waiting log entry (#3802) 2019-10-19 13:35:45 -07:00
terence tsao
1433fab0d4
Use lowest included slot for precompute (#3805)
* Fix attestations

* Fix new

* Testing state transition

* Fix

* Runtime works
2019-10-18 21:47:54 -07:00
terence tsao
e42af4f11d
Check attestations bitfield overlaps (#3804) 2019-10-18 17:41:27 -07:00
terence tsao
a05dca18c7
Add spec tests for process_slashing and process_justification_finalization (#3803)
* Add precompute spec tests

* Gazelle
2019-10-18 09:09:38 -07:00
terence tsao
a41ac6b498 Implement ProcessEpochPrecompute (#3798)
* Implemented ProcessSlashingsPrecompute

* Tests for ProcessSlashingsPrecompute

* Gaz

* Lint

* Feature flags

* Hook in ProcessEpochPrecompute

* Hook it to spec test

* Seperate test into it's own package to avoid circular dependency

* Lint

* Gazelle

* Preston's feedback

* Nishant's feedback
2019-10-18 16:38:47 +08:00
Preston Van Loon
fb510a3510 Reject blocks from the future in regular sync (#3799)
* reject blocks from the future in syncing

* fix test and gofmt
2019-10-18 11:30:14 +08:00
terence tsao
aedd38092f Process slashing with precompute (#3797)
* Implemented ProcessSlashingsPrecompute

* Tests for ProcessSlashingsPrecompute

* Gaz

* Lint

* Removed comment
2019-10-18 09:10:41 +08:00
terence tsao
89ef6d6648
Process rewards and penalties with precompute (#3793) 2019-10-17 10:54:03 -07:00
terence tsao
921d0a6e7e
Process justification with precompute (#3792) 2019-10-17 02:24:13 -07:00
Preston Van Loon
6bf14dedcd
Better aggregated attestations pool (#3761)
* WIP of aggregated signatures in DB

* new lines at end

* taking a nap on the plane now

* fix tests

* remove duplication of attestations. so much for that airplane nap lol

* benchmark before flight lands

* gaz

* manual gaz

* fully contained checks

* quick improvement before landing

* new bitlist with fixes

* doesn't need real signatures

* it works, mostly

* print shard too

* some refactoring

* Revert "some refactoring"

This reverts commit 377ce7fbfb02321c20522da2eb27208a20a67669.

* Revert "Revert "some refactoring""

This reverts commit b46a458898acd214da44fc20dfae920d2725b6e8.

These changes are ok, just need to update the expected values

* fix tests

* lint

* lint

* upstream changes

* fix tests

* what

* resolve TODOs

* gofmt

* revert unrelated pb

* remove debug statement
2019-10-16 23:46:07 -07:00
terence tsao
2d863a1e63
Methods to precompute process_epoch records (#3788) 2019-10-16 17:48:26 -07:00
terence tsao
a62ac97a35
Type for process epoch optimization (#3783) 2019-10-16 11:26:02 -07:00
Preston Van Loon
86a8ec035c
Aggregation helper improvements (#3789)
* aggregation helper

* lint
2019-10-16 11:11:58 -07:00
Nishant Das
00a5a25323
Fix Round Robin Test (#3775)
* fix round robin test

* add comment
2019-10-15 14:06:44 +08:00
Preston Van Loon
9e6b4d1f29
some fixes for bazel v1 (#3754) 2019-10-12 16:55:56 +09:00
Preston Van Loon
d4001a8b29
Annotate errors / spans in block processing queue (#3751)
* annotation error in span

* added more annotations and spans to process pending blocks

* use diff

* workspace dep
2019-10-10 17:44:24 +09:00
Nishant Das
964c54f911
Continue Writing to The Stream Despite Failures (#3743)
* don't fail if block doesn't exist

* fix nogo
2019-10-09 14:57:43 +08:00
terence tsao
9bf55e53e7 Add context and tracing to attestation pool (#3737)
* Test case for overlapping aggregation bits

* Add ctx and tracing for attestation pool and beyond

* No nil

* Use real ctx

* Use real ctx

* Fix test

* Fix test

* Fix test

* Fix test

* Fixed imports
2019-10-09 06:42:17 +08:00
Jim McDonald
1c4ea5c471 Additional log information for invalid deposits (#3740)
* Additional log information for invalid deposits

* Update field names
2019-10-08 18:28:20 +08:00
Raul Jordan
1a94ef12b9
Ensure Blocks Are Not Duplicated When Saved to DB (#3739)
* dedup

* tests pass when using the fallback
2019-10-08 13:47:48 +09:00
terence tsao
46ecbdc997
Tests for process att with overlapping bits (#3734) 2019-10-08 10:52:07 +09:00
Preston Van Loon
4e22f52ab3 Testnet restart and hotfixes (#3736)
* hotfix for round robin, hotfix for grpc recovery

* gofmt

* break

* wrong subtraction

* lint

* testnet fork version update

* ignore relay / DHT protocol not supported error
2019-10-08 07:59:08 +08:00
Preston Van Loon
23764c4640
Abstract verifySlot to helper package (#3731)
* Abstract verifySlot to helper package

* blocks -> slots

* fix test
2019-10-07 16:15:50 +09:00
terence tsao
750bc83369
Clean up feature flag namings (#3715) 2019-10-07 14:11:49 +09:00