Preston Van Loon
9ec4f727c6
Remove unnecessary state copy ( #8303 )
2021-01-20 20:00:01 -06:00
terence tsao
ffcadcf184
Rm forkchoice attestation verification ( #8301 )
...
* Rm fork choice attestation sig verification
* Unit test
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-20 21:46:13 +00:00
Ivan Martinez
7c59615ae2
Remove go-ssz entirely from prysm ( #8257 )
...
* Add DepositSigningData
* gaz
* Add to ssz tests
* Rename to DepositMessage
* Remove deprecated comment
* Remove return
* Fixes from review
* Fixes
* Remove some of gossz
* Remove go-ssz entirely
* Remove unneeded file
* Fix runtime with ssztypes
* Add back ssz files
* Fix formatting
* tidy
* Remove go-ssz from static
* tidy again
* Add tests
* Change to sig
* Fix test
* fx
* Fix visiblity
* Revert "Remove unneeded file"
This reverts commit d66fcda92925133db1a95f8f94ac61bbc6095c69.
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: Preston Van Loon <preston@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-20 21:03:46 +00:00
Preston Van Loon
d6cccc18c3
verifyDepositDataWithDomain: Use helpers.ComputeSigningRoot ( #8302 )
2021-01-20 20:30:58 +00:00
terence tsao
befe8d88b8
Remove duplicated target root check for fork choice attestation ( #8277 )
...
* Rm redundant target root check for fork choice attestation
* Comments
* Revert back verifyBeaconBlock
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
2021-01-20 18:27:10 +00:00
Radosław Kapka
153737803a
Implement ListPeers in the node API ( #8288 )
...
* add span
* update ethereumapis
* align server with ethereumapis
* benchmark
* naive implementation
* rename two status functions
* new Inbound and Outbound status functions
* tests
* 'enr:' prefix
* refactoring
* gzl
* case when one filter is empty
* empty filter condition fix
* deepsource
* rename getPeer to peerInfo
* bring back correct version of ethereumapis
* go mod tidy
2021-01-20 15:52:33 +00:00
Radosław Kapka
4b14fa4317
Better receiver names in validator and slasher modules ( #8296 )
...
* validator
* slasher
* rename db to s for store
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-20 14:39:07 +00:00
Victor Farazdagi
27847ee2fe
Update bitfield dependency ( #8299 )
2021-01-20 13:39:54 +00:00
terence tsao
578dabe27c
Remove duplicated LMD FFG check for fork choice attestation ( #8276 )
...
* Rm redundant lmd<->ffg check for fork choice attestation
* Comments
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: Nishant Das <nishdas93@gmail.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-20 10:19:43 +00:00
Victor Farazdagi
ed2c0a3e5e
Update bitfield dependency ( #8295 )
2021-01-20 06:55:53 +00:00
terence tsao
5d841874f7
Return error on AttestingIndices
bitfield length check ( #8285 )
...
* Return error on committee len check
* AttestingIndices unit test
* Add equality check
* Fixing more tests
* Fix rest of the tests
* Fix invalid bit length test
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-20 03:00:52 +00:00
terence tsao
ab9d596a5f
Update fastssz ( #8291 )
...
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-19 23:48:22 +00:00
terence tsao
084e5bd020
Add test TestStore_OnAttestation_Ok ( #8293 )
...
* Add test TestStore_OnAttestation_Ok
* Handle errors
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-19 23:10:10 +00:00
terence tsao
bc2c206832
Add verify slot target epoch function and apply all ( #8273 )
...
* Add verify slot target epoch function and apply all
* Fix TestProcessAttestationsNoVerify_IncorrectSlotTargetEpoch
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
2021-01-19 21:41:44 +00:00
Preston Van Loon
655a7e98c3
Stamp binaries by default ( #8292 )
2021-01-19 20:43:30 +00:00
Radosław Kapka
f89fd67952
Better receiver names in beacon chain module ( #8286 )
2021-01-19 13:21:32 +00:00
Nishant Das
20b836d038
Add Initial Support For Gossip Scoring Service ( #8275 )
...
* checkpoint progress
* gaz
* fix
* add it in
* Update beacon-chain/p2p/pubsub.go
* fmt
* reformat imports
Co-authored-by: Victor Farazdagi <simple.square@gmail.com>
2021-01-19 12:13:08 +00:00
Preston Van Loon
b33a8eb59f
Revert "Use remote cache in CI" ( #8281 )
...
This reverts commit 8b6abcbf0c
.
2021-01-19 01:55:00 +00:00
Preston Van Loon
8b6abcbf0c
Use remote cache in CI ( #8280 )
...
* Use remote cache in CI
* Update .buildkite-bazelrc
* Update .buildkite-bazelrc
2021-01-18 22:22:37 +00:00
Raul Jordan
9b367b36fc
add happy/sad tests ( #8279 )
2021-01-18 11:32:17 -08:00
pinglamb
09a792ded4
isCanonical for slot 0 should return true ( #8269 )
...
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
Co-authored-by: Preston Van Loon <preston@prysmaticlabs.com>
2021-01-16 16:14:14 +00:00
terence tsao
cf343be76a
Add a helper to validate nil attestation ( #8272 )
...
* Add verify nil attestation function and apply all
* Remove invalid attestatione debug log
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
2021-01-15 22:19:17 +00:00
Raul Jordan
4c19e622cd
Implement Migration Up/Down Logic for Validator DB ( #8271 )
...
* rollback logic
* implement up down logic
* begin down migration tests
* rollback works
* unset test
* remove iface
* gaz
* add comment
* fix ineff assign
* preston comment
* add progress
2021-01-15 15:35:21 -06:00
pinglamb
d7d2c6354b
Blocks filtering should return genesis when startSlot=0 and endSlot=0 ( #8270 )
...
Co-authored-by: Preston Van Loon <preston@prysmaticlabs.com>
2021-01-15 18:36:17 +00:00
terence tsao
b6c4bc197f
Add on_block
finality test ( #8266 )
...
* Can generate at epoch boundary
* Remove extra space
* Add on block finality test
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-15 13:42:49 +00:00
Nishant Das
ce397ce797
Prune Excess Peers Better ( #8260 )
...
* add method
* add changes
* formatting
* choose
* fix waitgroup
* add
* add debug logs
* gaz
* make it better
* fix
* godoc
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-14 21:28:20 +00:00
Radosław Kapka
2d75b12791
Implement GetIdentity in the node API ( #8230 )
...
* initial implementation
* register metadata provider
* final implementation
* tests
* fixed imports
* gazelle
* code review
* small cleanup
* change errors.Wrap to status.Errorf
* gazelle + goimports
Co-authored-by: Preston Van Loon <preston@prysmaticlabs.com>
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-14 20:48:40 +00:00
terence tsao
40155c9828
Testutil: Can generate attestation at epoch boundary ( #8265 )
2021-01-14 10:22:53 -08:00
Radosław Kapka
a2d4e3302c
Implement GetPeer in the node API ( #8264 )
...
* tests
* capitalize error message
2021-01-14 10:26:16 -06:00
Nishant Das
612e6ebdc4
gogo protobuf ( #8263 )
2021-01-14 17:17:26 +08:00
Raul Jordan
fff6472a04
Allow Multiple Targets Per Source Epoch in Attester Protection ( #8262 )
2021-01-13 23:23:29 +00:00
terence tsao
daf6da5beb
Add hydrate indexed att test helper ( #8261 )
...
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
2021-01-13 22:05:57 +00:00
pinglamb
9369bb6781
Copied over ssz.DeepEqual as sszutil.DeepEqual from go-ssz ( #8258 )
...
* Copied over ssz.DeepEqual as sszutil.DeepEqual from go-ssz
* Added test cases for DeepEqual
* Remove commented code
2021-01-13 20:40:56 +00:00
terence tsao
eeda9f18fe
Disallow duties request where req.Epoch > current.Epoch+1 ( #8252 )
...
* Disallow request epoch to be out of bound
* Input Slot and epoch checks
* Tests
* Review feedbacks
* Unavailable error code
* Rename genesis time fetcher to time fetcher
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-12 23:27:37 +00:00
Preston Van Loon
e967a65b68
Update prometheus/client_golang ( #8256 )
2021-01-12 22:56:57 +00:00
Preston Van Loon
c87ef2f0e7
Coverage results upload fix for CI ( #8255 )
...
* Check in gocovmerge, add all-in-one coverage.sh script for CI
* annotate script
* Annotate tools/gocovmerge/main.go
* deepsource suggestions
2021-01-12 20:12:09 +00:00
pinglamb
1a9207ba46
Removed some simple go-ssz usage ( #8250 )
...
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: Preston Van Loon <preston@prysmaticlabs.com>
2021-01-12 19:31:34 +00:00
pinglamb
9f423617cb
Added db.BlocksBySlot and db.BlockRootsBySlot ( #8184 )
...
* Added blockBySlot and blockRootBySlot
* Changed to BlocksBySlot and BlockRootsBySlot
* Updated to use BlocksBySlot and BlockRootsBySlot
* Added missing passthrough to karfa exporter
* Return hasBlocks/hasBlockRoots in the new getters
* Fixed CI lint
* Replace call to bytes.Compare with bytes.Equal
* Reordered the returns of the new getters
Co-authored-by: Nishant Das <nishdas93@gmail.com>
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
2021-01-12 18:31:15 +00:00
Radosław Kapka
015102c2d5
Implement GetSyncStatus in the node API ( #8241 )
...
* Implement GetSyncStatus in the node API
* gazelle
* add HeadSlot function to fuzz tests' fakeChecker
* use HeadFetcher to get head slot
* remove useless code
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-12 17:17:20 +00:00
Radosław Kapka
aa69e5edcc
Allow to create an empty imported wallet ( #8251 )
...
* reload keys into empty wallet
# Conflicts:
# validator/accounts/accounts.go
* removed warning on wallet creation
* export AccountsKeystoreRepresentation type
* rename error message variable
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-12 16:52:01 +00:00
Radosław Kapka
5dda2ca328
Replace HTTP code with gRPC code in GetHealth API endpoint ( #8249 )
...
* Replace HTTP code with gRPC code in GetHealth API endpoint
* gazelle
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-12 16:20:20 +00:00
Raul Jordan
470d5aa491
Cleanup Attester DB Protection Files and Add Back Save Lowest Epochs Functionality ( #8232 )
...
* cleanup for att protection
* rename to deprecated
* rem old item
* imports
2021-01-12 09:32:13 -06:00
Raul Jordan
d2bd954a6c
Remove Snappy from Validator Slashing Protection DB ( #8248 )
...
* no snappy
* Update validator/db/kv/migration_optimal_attester_protection.go
* fmt
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-12 01:10:11 +00:00
Ivan Martinez
e5556db49d
Add DepositMessage in preparation to remove go-ssz ( #8244 )
...
* Add DepositSigningData
* gaz
* Add to ssz tests
* Rename to DepositMessage
* Remove deprecated comment
* Remove return
* Fixes from review
* Fixes
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
2021-01-12 00:45:11 +00:00
Raul Jordan
d97596348e
Add Back New Attester Protection DB Logic ( #8242 )
...
* Revert "Revert New Attester Protection DB Logic (#8237 )"
This reverts commit 6738fa3493
.
* Batch Attestation Records and Flush All at Once in Validator DB (#8243 )
* begin flushing logic
* finalize logic before starting tests
* make code DRY
* better log fields
* gaz
* tweak parameter
* rename
* clarifying comment on error handling in event feed
* comprehensive tests
* more comments
* explain parameters in comments
* renamed consts
* Apply suggestions from code review
* gaz
* simplify
* typo
* comments
2021-01-11 23:59:17 +00:00
terence tsao
323eac6d6c
Remove timeout debug log ( #8247 )
...
* Disallow request epoch to be out of bound
* Remove debug log
* Revert "Disallow request epoch to be out of bound"
This reverts commit d2dc7db594a8565ee6a613d1ee8cd0bcf84c72ff.
2021-01-11 22:23:13 +00:00
Radosław Kapka
5fd03f8fb0
Unify the pattern of using a package-level logger ( #8245 )
...
Co-authored-by: Preston Van Loon <preston@prysmaticlabs.com>
2021-01-11 20:03:28 +00:00
terence tsao
18bb86754a
Hydrate signed block helper ( #8246 )
...
Co-authored-by: Radosław Kapka <rkapka@wp.pl>
2021-01-11 19:27:30 +00:00
Preston Van Loon
97320a0a8e
Remove snappy compression migration for attestation history ( #8238 )
...
* Remove snappy compression migration for attestation history
* gofmt
* remove more snappy stuff
* revert validator/db/kv/historical_attestations.go
2021-01-11 09:28:34 -08:00
terence tsao
9a1866b735
Hydrate header test helper ( #8234 )
...
* Hydrate headers and fix tests
* Gazelle
* Fix a slashing test
Co-authored-by: Radosław Kapka <rkapka@wp.pl>
2021-01-09 16:45:45 +00:00