Hsiao-Wei Wang
96b71a19de
Avoid Python-specific negative operation
2020-06-30 16:58:56 +08:00
Hsiao-Wei Wang
2c0595da01
PR feedback from Danny
2020-06-30 00:11:43 +08:00
Hsiao-Wei Wang
4b239e94b7
Mix PR feedback from Danny and Proto
2020-06-29 12:50:01 +08:00
Hsiao-Wei Wang
1d954ee9bd
PR feedback from @ericsson49
...
Co-authored-by: Alex Vlasov <avv49@mail.ru>
2020-06-29 12:33:52 +08:00
protolambda
3b7617f51a
make extracted byte uint8 for bitshift, do not use negative slice indexing, avoid negative comparison in test
2020-06-26 16:14:27 +02:00
protolambda
531184f42b
Infer types where possible, e.g. uint64+uint64=uint64
2020-06-26 15:41:47 +02:00
Hsiao-Wei Wang
a159a2da82
Merge pull request #1928 from ethereum/hwwhww/shard-block-tests
...
Add tests for `shard_state_transition` and some refactorings
2020-06-26 11:54:23 +08:00
Hsiao-Wei Wang
94c231cf98
Fix `ShardTransition.shard_data_roots` and add test
...
1. Fix `ShardTransition.shard_data_roots`: use `get_block_data_merkle_root` helper to calculate it.
2. Rework `get_valid_custody_chunk_response` testing helper: accept
`block_length_or_custody_data`
3. Add `test_with_custody_challenge_and_response` test
2020-06-26 01:46:45 +08:00
Hsiao-Wei Wang
a061758a66
Use `encode_bytes` to implement `int_to_bytes`
...
Rename `bytes_to_int` to `bytes_to_uint64`
Use `encode_bytes` to implement `int_to_bytes`
Rename `int_to_bytes` to `uint_to_bytes` and move it to `ssz_impl.py`
2020-06-25 20:20:39 +08:00
Hsiao-Wei Wang
b239f6108c
Merge branch 'dev' into hwwhww/strict-uint64
2020-06-25 17:18:16 +08:00
Hsiao-Wei Wang
2a7b5f7e68
PR feedback from Danny: nuke optional beacon_parent_state
2020-06-25 11:14:25 +08:00
Hsiao-Wei Wang
79b6bc616d
PR feedback from danny
2020-06-25 10:58:04 +08:00
terence tsao
7e04c70ca1
Update beacon-chain.md
2020-06-24 16:53:53 -07:00
Hsiao-Wei Wang
661959c13e
Add `process_shard_block` verification
2020-06-24 18:18:50 +08:00
Hsiao-Wei Wang
4a46fb2a8a
Refactor phase 1 block tests a bit and add `shard_state_transition`
...
tests
1. Refacotr phase1/sanity/test_blocks.py
2. Add phase1/sanity/test_shard_blocks.py for testing `verify_shard_block_message` and `verify_shard_block_signature`
2020-06-24 18:08:26 +08:00
Hsiao-Wei Wang
c4973792e2
Make `get_pending_shard_blocks` return `Sequence[SignedShardBlock]`
2020-06-24 12:50:27 +08:00
Hsiao-Wei Wang
021788a634
Merge pull request #1925 from ethereum/hwwhww/shard_state_transition
...
Rework `shard_state_transition` interface + fix #1922
2020-06-24 12:29:31 +08:00
Hsiao-Wei Wang
dbd1d4e589
PR feedback: Enable `verify_shard_block_signature`
2020-06-24 12:22:24 +08:00
Hsiao-Wei Wang
e4d4527845
Merge pull request #1921 from ethereum/hwwhww/shard-tests
...
Fix no winning root case + add tests + fix #1881
2020-06-24 11:21:23 +08:00
Hsiao-Wei Wang
e52c19896d
Update
...
1. Check on-time attestations fit `attestation.data.shard_transition_root != hash_tree_root(ShardTransition())`
2. Move `attestation.data.shard_head_root` check to after winning root
2020-06-23 18:22:18 +08:00
Hsiao-Wei Wang
db5da9dc97
Fix return type
...
Co-authored-by: Danny Ryan <dannyjryan@gmail.com>
2020-06-23 10:50:41 +08:00
Danny Ryan
05dc8fe9a0
Merge pull request #1922 from terencechain/patch-105
...
Remove shard check in `verify_shard_block_message`
2020-06-22 12:05:32 -06:00
Danny Ryan
e61efc14a3
Merge pull request #1886 from ethereum/fix_store_target_checkpoint_state
...
Fix store_target_checkpoint_state
2020-06-22 11:38:40 -06:00
Hsiao-Wei Wang
eec1442417
Reorg `shard_state_transition` argument and fix `get_shard_transition_fields`
2020-06-22 23:41:02 +08:00
Hsiao-Wei Wang
4f618fc62d
Rework `shard_state_transition` interface
...
To make `shard_state_transition` similar to phase 0
`state_transition` function
1. Rename old `shard_state_transition` to `process_shard_block`
2. Add `shard_state_transition` with `validate_message` flag, we only
validate it in shard fork choice
2020-06-22 23:21:24 +08:00
ericsson
723784b408
replace `[[]]*num` with `[()]*num` to avoild problems with mutability, as [] or () is copied
2020-06-20 01:02:19 +03:00
ericsson
40b397f53f
use [[]] * num instead of just [] * num
2020-06-20 00:09:59 +03:00
terence tsao
769e1d0339
Update shard-transition.md
2020-06-19 09:06:37 -07:00
Hsiao-Wei Wang
1a5016157a
Fix
...
1. To make it more compatible, update `is_on_time_attestation` argument: replace `attestation: Attestation` with `attestation_data:
AttestationData`
2. Fix `get_sample_shard_transition`
2020-06-19 23:46:01 +08:00
Hsiao-Wei Wang
c28857e4e1
Fix `attestation.data.shard_head_root` bug
2020-06-19 23:34:51 +08:00
Hsiao-Wei Wang
c2c2b4c444
Crosslink bugfix
...
1. Fix `is_winning_attestation` condition
2. Fix `process_crosslink_for_shard`: we can only check
`shard_data_roots` if `shard_transition != ShardTransition()`
2020-06-19 22:19:21 +08:00
Hsiao-Wei Wang
76840c9178
Merge branch 'dev' into hwwhww/strict-uint64
2020-06-19 17:01:04 +08:00
terence tsao
3888dc27a9
@djrtwo's feedback
2020-06-18 12:39:48 -07:00
terence tsao
db81f88c4e
Update beacon-chain.md
2020-06-18 10:59:37 -07:00
Danny Ryan
bd61c2686b
PR feedback
2020-06-18 09:45:10 -06:00
Danny Ryan
948ad23f96
Merge branch 'dev' into epochwise_committee_count_per_slot
2020-06-18 09:44:02 -06:00
Danny Ryan
05453b786d
Merge pull request #1895 from ethereum/hwwhww/attestation-shard
...
Add `shard: Shard` field to `AttestationData`
2020-06-18 09:37:07 -06:00
Danny Ryan
02d518c9e3
Merge pull request #1919 from ethereum/hwwhww/shard_block_length
...
Fix shard_block_length type in `compute_updated_gasprice`
2020-06-18 09:35:59 -06:00
Danny Ryan
13e7e7986d
Merge pull request #1915 from ethereum/hwwhww/fix-validator-arguments
...
Fix missing arguments of validator guide
2020-06-18 09:34:45 -06:00
Hsiao-Wei Wang
fe47869d5f
Revert `process_crosslinks` and add comment
2020-06-18 23:32:23 +08:00
Hsiao-Wei Wang
35bf3b5290
Refactor `validate_attestation`
...
Co-authored-by: Danny Ryan <dannyjryan@gmail.com>
2020-06-18 23:20:24 +08:00
Hsiao-Wei Wang
8cf0774290
Fix shard_block_length type in `compute_updated_gasprice`
2020-06-18 20:39:29 +08:00
Hsiao-Wei Wang
6aca7afd81
Add notes of active shard count
2020-06-18 17:35:24 +08:00
Hsiao-Wei Wang
7dbecdf904
Fix some missing arguments
2020-06-18 17:35:16 +08:00
Hsiao-Wei Wang
c0b6df8fd0
Merge pull request #1906 from terencechain/patch-102
...
Fix links in phase1 validator doc
2020-06-18 15:10:43 +08:00
Hsiao-Wei Wang
4428a6aedf
Fix table
2020-06-18 13:50:10 +08:00
Hsiao-Wei Wang
0ae11cd70c
Merge pull request #1911 from terencechain/patch-103
...
get_shard_winning_roots uses on_time_slot
2020-06-18 12:28:23 +08:00
Hsiao-Wei Wang
0eeffc47bc
Merge pull request #1909 from ericsson49/fix_process_custody_game_operations
...
Fix typing error in `process_custody_game_operations`
2020-06-18 12:22:35 +08:00
protolambda
41ebd51aff
Merge branch 'dev' into hwwhww/strict-uint64
2020-06-18 02:49:09 +02:00
ericsson
9dc43957e2
a fix according to @protolambda comments
2020-06-18 03:39:51 +03:00
ericsson
e479e96480
lint fix
2020-06-18 02:46:06 +03:00
terence tsao
cc84b49d13
on_time_attestation_slot instead of current_slot
2020-06-17 16:20:46 -07:00
ericsson
adced70c54
use `aggregate.data` instead of hust `data`
2020-06-18 02:04:16 +03:00
ericsson
17c86177d9
Change types of BeaconBlockBody chunk_challenges and
...
chunk_challenge_responses to List[CustodyChunkChallenge, ...]
2020-06-18 01:43:41 +03:00
terence tsao
3eabcddb4c
Update validator.md
2020-06-17 13:24:00 -07:00
protolambda
ce0371a66b
fix comment: committees per slot for given *epoch*
2020-06-17 20:23:26 +02:00
protolambda
9b60a9b799
Avoid state usage in p2p validation, compute committee count per slot for epoch as a whole
2020-06-17 20:19:32 +02:00
Danny Ryan
fbf10a0db3
fix tests
2020-06-16 22:32:09 -06:00
Hsiao-Wei Wang
23cbbb1d08
Fix shard number assertion and refactor it
2020-06-17 09:48:47 +08:00
Hsiao-Wei Wang
c8ae7d99f9
Fix after auto-merge
2020-06-17 09:05:44 +08:00
Danny Ryan
a21f93646c
Merge pull request #1878 from ethereum/hwwhww/remove_digest
...
Remove `ShardState.transition_digest`
2020-06-16 16:40:52 -06:00
Danny Ryan
759185632f
Merge branch 'dev' into phase1-validator
2020-06-16 16:07:20 -06:00
Danny Ryan
2e0950560b
PR feedback
2020-06-16 16:03:36 -06:00
Hsiao-Wei Wang
7fba94a73d
Merge branch 'dev' into hwwhww/attestation-shard
2020-06-17 01:58:05 +08:00
Dankrad Feist
e6e694fad9
Fix toc
2020-06-16 17:35:33 +01:00
Dankrad Feist
58935c19d6
Move constant
2020-06-16 17:23:09 +01:00
Dankrad Feist
df1a932534
Rename misleading variable all_secrets_are_revealed
2020-06-16 15:19:45 +01:00
dankrad
4bc849bcc2
Update specs/phase1/custody-game.md
...
Co-authored-by: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-06-16 15:05:12 +01:00
dankrad
4b8b3f2cbc
Update specs/phase1/custody-game.md
...
Co-authored-by: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-06-16 15:05:01 +01:00
Dankrad Feist
a4c2950c4a
Phase 1 validator guide stub. This is to start collecting important details with correct validator operation.
2020-06-16 14:48:00 +01:00
Danny Ryan
a0175ca1b3
Merge branch 'dankrad-custody-256bit' into dankrad-custody-0.01bit
2020-06-16 07:15:00 -06:00
Hsiao-Wei Wang
3ee0761d17
Add `shard: Shard` field to `AttestationData`
2020-06-16 00:17:49 +08:00
Hsiao-Wei Wang
50ac8ebb0c
Fix DOMAIN_CUSTODY_BIT_SLASHING
2020-06-15 21:25:40 +08:00
Hsiao-Wei Wang
458d343497
Fix configs and put domain types to the same table
2020-06-15 21:15:11 +08:00
Hsiao-Wei Wang
be607e97f6
Merge branch 'dev' into phase1-validator
2020-06-15 21:09:43 +08:00
Danny Ryan
f62125eaa6
add phase 1 on-time aggregation
2020-06-15 06:54:48 -06:00
Hsiao-Wei Wang
8697b30eea
Fix configuration
2020-06-15 15:30:32 +08:00
Hsiao-Wei Wang
e80f6727dc
Merge branch 'dev' into dankrad-custody-256bit
2020-06-15 15:13:45 +08:00
Danny Ryan
e955e6f6e1
Merge pull request #1884 from paulhauner/patch-25
...
Use parent_root for finalized chain check
2020-06-13 16:09:16 -05:00
Danny Ryan
fdb6f15867
unhandled exceptions do not modify forkchoice store
2020-06-13 15:59:04 -05:00
Danny Ryan
df9b5f18a4
Merge pull request #1885 from paulhauner/patch-26
...
Fork choice: minor formatting change
2020-06-13 15:51:03 -05:00
Dankrad Feist
f6d7dac30c
Change to 2**14 epoch (73 day) custody periods as per #1888
2020-06-13 15:15:37 +01:00
Paul Hauner
7ad1bb508d
Ensure parent is checked before store lookup
2020-06-13 16:04:16 +10:00
Dankrad Feist
42a9f1afdf
Fix Legendre bit computations
2020-06-12 23:44:36 +01:00
Aditya Asgaonkar
993ed5c2c6
Resetting branch to dev and adding single commit
2020-06-12 14:37:07 -07:00
Dankrad Feist
04fb9926e8
Remove custody bits from phase 1 and tests
2020-06-12 17:16:08 +01:00
Dankrad Feist
29c1569251
Merge branch 'dev' into dankrad-custody-256bit
...
# Conflicts:
# specs/phase1/beacon-chain.md
2020-06-12 12:29:57 +01:00
Dankrad Feist
398fc833b8
Fix TOC
2020-06-12 12:07:31 +01:00
Dankrad Feist
59b35afcd9
Refactor universal hash function
2020-06-12 12:04:30 +01:00
Dankrad Feist
65c3417f90
Fix replace_empty_or_append, remove assert False & test
2020-06-12 11:53:32 +01:00
dankrad
7bf491d49d
Update specs/phase1/custody-game.md
...
Co-authored-by: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-06-12 11:28:49 +01:00
dankrad
0e8bba2ce3
Update specs/phase1/custody-game.md
...
Co-authored-by: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-06-12 11:28:30 +01:00
dankrad
d41b6a5775
Update specs/phase1/custody-game.md
...
Co-authored-by: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-06-12 11:18:07 +01:00
dankrad
31654d8bf4
Update specs/phase1/custody-game.md
...
Co-authored-by: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-06-12 11:17:44 +01:00
dankrad
7c6280aa8e
Update specs/phase1/custody-game.md
...
Co-authored-by: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-06-12 11:16:19 +01:00
Danny Ryan
67c9c062e0
Merge pull request #1880 from paulhauner/patch-24
...
Fork choice: avoid redundant call to get_ancestor
2020-06-11 10:23:27 -05:00
Paul Hauner
a1a75a38fe
Tidy, add comment
2020-06-11 11:51:18 +10:00
Danny Ryan
85b227da78
Merge branch 'dev' into phase1-validator
2020-06-10 11:34:55 -05:00
Danny Ryan
4b8f132957
pr feedback
2020-06-10 11:32:02 -05:00
Dankrad Feist
e46d5effe4
Add test for slashing after failing to respond to custody chunk challenge
2020-06-10 17:20:42 +01:00
Danny Ryan
1dc6b55617
rearrange fork choice condition for clarity
2020-06-10 09:40:34 -05:00
Hsiao-Wei Wang
479c40450d
Friendly lint fix
2020-06-10 18:16:26 +08:00
Paul Hauner
29d968bb2e
Use parent_root for finalized chain check
2020-06-10 15:09:40 +10:00
Paul Hauner
378d249487
Avoid redundant call to get_ancestor
2020-06-10 11:02:10 +10:00
terence tsao
0f6efcd50d
Update toc
2020-06-09 15:38:40 -07:00
terence tsao
ef11e924fa
Update phase1 beacon-chain config table
2020-06-09 13:34:46 -07:00
Hsiao-Wei Wang
dacf86a5c0
Remove `transition_digest`
2020-06-10 02:43:59 +08:00
Danny Ryan
65a739fe41
Merge branch 'dev' into phase1-validator
2020-06-08 15:50:51 -06:00
Hsiao-Wei Wang
41cfa7fdf6
Merge branch 'dev' into dankrad-custody-256bit
2020-06-09 01:39:51 +08:00
Hsiao-Wei Wang
2d895e9388
PR feedback from danny
2020-06-09 00:13:27 +08:00
Hsiao-Wei Wang
3b749d72c8
Merge branch 'dev' into hwwhww/shard_fork_choice
2020-06-08 23:57:19 +08:00
Hsiao-Wei Wang
9b3f45dfd0
Merge pull request #1875 from ethereum/hwwhww/shard_fork_choice_part2
...
Handle `beacon_parent_root` checks
2020-06-08 23:53:31 +08:00
Hsiao-Wei Wang
e03a970eaf
PR feedback from danny: simplify `verify_shard_block_message` params
2020-06-08 23:49:24 +08:00
Danny Ryan
dce82e76bc
Merge pull request #1870 from ethereum/hwwhww-patch-1
...
Use shard_block.slot to get seed for proposer selection
2020-06-08 09:19:23 -06:00
Hsiao-Wei Wang
435505746c
PR feedback from Terence: fix `get_shard_latest_attesting_balance`
...
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
2020-06-08 17:12:46 +08:00
Hsiao-Wei Wang
a4cc189f2b
Apply PR feedback from Danny
2020-06-06 05:19:46 +08:00
Hsiao-Wei Wang
a71c0a5ccc
Per #1704 discussion, remove `on_time_slot`: the given `beacon_state`
...
should be transitioned.
2020-06-06 02:39:47 +08:00
Hsiao-Wei Wang
2d4788fe7d
Fix `verify_shard_block_message`
...
Add check for `block.beacon_parent_root` per Terence's suggestion
Update `get_shard_transition`
1. Disable verification: it will be fix in v-guide
2. Use `on_time_slot` to compute offset_slots
Rework tests
2020-06-06 02:39:47 +08:00
Hsiao-Wei Wang
a154d0c22b
Fix typo
2020-06-06 02:39:11 +08:00
Hsiao-Wei Wang
6f9c290bfb
Add TODO flag of latest message
2020-06-06 02:39:11 +08:00
Hsiao-Wei Wang
f8597d2965
Add `get_pendings_shard_blocks`
2020-06-06 02:39:10 +08:00
Hsiao-Wei Wang
727353c054
Verify shard_block.slot fits the expected offset_slots
2020-06-06 02:39:10 +08:00
Danny Ryan
8a9ccc4f34
clarify attestations as coming from block.body when getting winning roots in validator guide
2020-06-05 12:12:12 -06:00
Danny Ryan
8e5c98ef3c
PR feedback
2020-06-05 12:01:53 -06:00
Danny Ryan
7e44456be5
mod compute_subnet_for_attestation to be usable for lookahead
2020-06-05 09:50:49 -06:00
Danny Ryan
52de25048a
fix lihth client refs in val guide
2020-06-05 09:35:09 -06:00
Michael Sproul
c2b7ff7422
Re-clarify proposer slashing check
...
Fixes a typo from #1871
2020-06-04 16:16:37 +10:00
Hsiao-Wei Wang
8afb93f5a3
Add `shard_block.slot` to seed
2020-06-04 11:19:04 +08:00
Michael Sproul
376c836190
Clarify proposer slashing gossip conditions
2020-06-04 12:51:17 +10:00
Hsiao-Wei Wang
26aae40941
Use epoch of the shard_block.slot for generating seed
2020-06-04 05:31:53 +08:00
Hsiao-Wei Wang
d344521741
Bugfix: should set `shard` for empty proposal
2020-06-04 05:30:13 +08:00
Hsiao-Wei Wang
c0108afe77
Use shard_block.slot to get seed for proposer selection
2020-06-04 05:06:04 +08:00
Danny Ryan
b1ff00aab0
Merge branch 'dev' into phase1-validator
2020-06-03 12:18:17 -06:00
Danny Ryan
74204f795d
udpate validator guide to work with all updated phase 1 constructions
2020-06-03 12:16:39 -06:00
Hsiao-Wei Wang
e1981a7bfd
`head_shard_root` -> `shard_head_root`
2020-06-04 01:00:52 +08:00
Hsiao-Wei Wang
58e75c27ed
Merge branch 'dev' into hwwhww/shard_fork_choice
2020-06-04 00:56:25 +08:00
Hsiao-Wei Wang
eb21648146
Merge pull request #1858 from ethereum/hwwhww/get_start_shard
...
`get_start_shard` proposal
2020-06-04 00:46:12 +08:00
Danny Ryan
d1647c28e0
Merge branch 'dev' into phase1-validator
2020-06-03 10:43:42 -06:00
Hsiao-Wei Wang
5c5cedd60d
Apply PR feedback from Danny and Terence
2020-06-03 22:31:16 +08:00
Danny Ryan
cc5116bf33
Merge pull request #1837 from status-im/ssz-string
...
Use SSZ types in p2p spec
2020-06-02 16:35:31 -06:00
Danny Ryan
09b387bdc9
Merge pull request #1862 from terencechain/patch-100
...
Tidying up `shard_state_transition`
2020-06-02 14:19:31 -06:00
Diederik Loerakker
e814d52ee5
Merge pull request #1866 from ethereum/tunable-genesis
...
Tunable genesis
2020-06-02 22:19:13 +02:00
Danny Ryan
cf7b9993b5
clarify `head_root` is for a `BeaconBlock`
...
Co-authored-by: Diederik Loerakker <proto@protolambda.com>
2020-06-02 13:51:43 -06:00
Danny Ryan
06dfff022b
add comment about default of 0x00 for genesis finalized checkpoint in p2p spec
2020-06-02 11:22:09 -06:00
Danny Ryan
671fae6efe
change note about genesis delay in p2p spec to match new GENESIS_DELAY config value; fix tests
2020-06-02 11:09:42 -06:00
Raw Pong Ghmoa
34412130c5
phase0: enable a tunable genesis time
2020-06-02 10:55:13 -06:00
terence tsao
24427947b1
Moved transition_digest to last
2020-06-02 08:09:43 -07:00
Hsiao-Wei Wang
142ba17451
PR review from Danny
2020-06-02 18:08:28 +08:00
Paul Hauner
2a125e8497
Update fork-choice.md
2020-06-02 17:22:33 +10:00
Paul Hauner
c6aac16506
Reword fork choice comment
2020-06-02 17:16:25 +10:00
Danny Ryan
d6435d0cbf
Merge branch 'dev' into dankrad-custody-256bit
2020-06-01 18:49:11 -06:00
Danny Ryan
3a4db69a20
Merge branch 'dev' into dankrad-custody-256bit
2020-06-01 18:45:22 -06:00
terence tsao
2a218520a1
Tidying up `shard_state_transition`
2020-06-01 14:31:45 -07:00
Hsiao-Wei Wang
5f10ac13bf
PR feedback from Terence and Danny: refactor `get_committee_count_delta`
2020-06-01 23:22:59 +08:00
Hsiao-Wei Wang
30f72dd696
Fix `get_shard` and `compute_shard_from_committee_index` calls
2020-06-01 23:15:16 +08:00
Hsiao-Wei Wang
9567c238d4
Merge branch 'dev' into hwwhww/get_start_shard
2020-06-01 18:17:58 +08:00
Hsiao-Wei Wang
92db6da508
Apply suggestions from Terence
...
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
2020-06-01 17:56:22 +08:00
Hsiao-Wei Wang
31127b7024
Merge branch 'dev' into hwwhww/phase1_refactor_part2
2020-06-01 17:50:49 +08:00
Hsiao-Wei Wang
6317bd68aa
PR feedback from Danny
...
Co-authored-by: Danny Ryan <dannyjryan@gmail.com>
2020-06-01 17:47:47 +08:00
Hsiao-Wei Wang
8e5db1b49f
Merge pull request #1856 from ethereum/hwwhww/verify_empty_shard_transition
...
Rework `Shard transition processing`
2020-06-01 17:47:00 +08:00
Hsiao-Wei Wang
8f570b461d
Merge pull request #1854 from ethereum/hwwhww/phase1_refactor
...
Some phase1 refactoring
2020-06-01 17:46:16 +08:00
Jacek Sieka
33e115f8c6
Clean up remaining `[]` List syntax
...
..and use List[byte, 256] for error message
2020-05-30 20:59:12 +02:00
Alex Stokes
437b2ebb90
Update fork choice spec comment for clarity
...
I think this change more clearly specifies the intended behavior. Given the terseness of the spec's code representation, I think we should aim for as much clarity as possible.
2020-05-29 18:16:06 -07:00
Hsiao-Wei Wang
63de59d5f6
Merge branch 'dev' into hwwhww/shard_fork_choice_3
2020-05-30 03:57:17 +08:00
Hsiao-Wei Wang
327deb40b2
Adjust function blocks
2020-05-30 03:14:51 +08:00
Hsiao-Wei Wang
cceeab2657
Combine `process_crosslinks` and `verify_empty_shard_transition` into `process_shard_transitions`
2020-05-30 03:13:20 +08:00
Hsiao-Wei Wang
9b9507c138
Merge branch 'dev' into hwwhww/phase1_refactor_part2
2020-05-30 03:11:28 +08:00
Hsiao-Wei Wang
f70224b84e
Extract `compute_committee_source_epoch`
2020-05-30 03:09:42 +08:00
Hsiao-Wei Wang
2dc041807a
Implement `get_start_shard`
2020-05-30 01:26:00 +08:00
Hsiao-Wei Wang
b16e6d7a86
PR feedback from Danny
...
Co-authored-by: Danny Ryan <dannyjryan@gmail.com>
2020-05-29 12:58:19 +08:00
Hsiao-Wei Wang
bd9f983eea
Minor fix
2020-05-29 02:20:38 +08:00
Hsiao-Wei Wang
8ae7f5b6fa
Refactor `is_valid_indexed_attestation`: extract `verify_attestation_custody`
2020-05-29 01:24:17 +08:00
Hsiao-Wei Wang
7509ecb742
Add comments, minor refactoring
2020-05-29 00:13:08 +08:00
Hsiao-Wei Wang
19262888e4
Rename `verify_shard_transition_false_positives` to `verify_empty_shard_transition`
2020-05-28 21:55:49 +08:00
Hsiao-Wei Wang
8c9bbc48d8
Rework `is_shard_attestation`
...
Change it to `is_on_time_attestation` so that it could be reused in
`validate_attestation`.
2020-05-28 21:49:36 +08:00
Hsiao-Wei Wang
ca48963032
Rename `head_shard_root` to `shard_head_root`
2020-05-28 21:38:11 +08:00
Hsiao-Wei Wang
c437578280
Add `shard` field to `ShardBlock`
2020-05-28 21:32:27 +08:00
Alex Stokes
75633cfcf1
Update link so gossipsub encodings match the correct section
2020-05-26 11:00:02 -07:00
Danny Ryan
8eb1d2e940
Merge pull request #1844 from ericsson49/ericsson49/fix_shard_state_transition
...
`compute_shard_transition_digest` expects `Root` as a fourth parameter
2020-05-26 10:17:55 -06:00
Danny Ryan
753a25e5db
Merge pull request #1843 from terencechain/patch-99
...
Use `compute_previous_slot` for `slot - 1` occurrences
2020-05-26 10:02:14 -06:00
Ali Atiia
75787d92a8
broken link
...
broken link to custory-game.md
2020-05-25 16:45:44 -04:00
ericsson
d3c26d6b8b
`compute_shard_transition_digest` expects `Root` as a fourth parameter
2020-05-25 18:45:38 +03:00
terence tsao
ce1d22d71c
Use helper `compute_previous_slot`
2020-05-23 15:22:49 -07:00
Jacek Sieka
56309342c0
Use `Bytes32` for `error_message`
...
`ErrorMessage.error_message` is a leftover from an older version of SSZ
that was able to encode unbounded lists. This is no longer the case -
all collection types now have a fixed upper bound on length.
In general, the `error_message`, just like the `graffitti` field, should
not be interpreted in any particular way except for debugging and vanity
- as such, using the same type, a `Bytes32`, seems reasonable.
An alternative would be `List[byte, 256]` which maybe could be
"reasonably backwards compatible" with whatever clients are are doing
now - depending on how they are dealing with this field type that no
longer exists in the SSZ spec :) It would however be the only place
where `List[uintN, N]` is used in the current spec.
As an exercise, this could be considered a security issue since it's
essentially unbounded and undefined behaviour.
2020-05-21 15:33:47 +02:00
Danny Ryan
96f785e84b
ensure only forward progress with eth1data voting
2020-05-20 13:56:43 -06:00
Danny Ryan
aa6352608e
Merge pull request #1835 from ethereum/strict-block-range
...
Strict block range (Rebase and extend #1827 )
2020-05-20 13:00:29 -06:00
protolambda
522e34efcf
Fix markdown, use multiple lines for change-control, and add step >= 1 case
2020-05-20 20:46:08 +02:00
Danny Ryan
a6d4566f51
Merge pull request #1834 from ethereum/clarify-genesis-safety
...
clarify that eth1 block follow distance for genesis
2020-05-20 12:44:29 -06:00
protolambda
59a43142c2
Rebased on latest BlocksByRange spec, fix conflicts, clarify single chain, even with higher step
2020-05-20 20:39:52 +02:00
Jacek Sieka
a29cbebc0e
cover `step` parameter in stricter range request
2020-05-20 20:29:43 +02:00
Jacek Sieka
607e23949c
require blocks to be ordered consecutively in block range request
...
Per the spec, if I request range 5-10, it is permissible for a client to
answer with block 7, 9 - even if the blocks 5, 6 and 8 exist.
Because blocks 7 and 9 cannot be validated as they arrive in such a
request, it seems better to close this gap - this update adds the spec
language that forbids well-behaving clients from answering this way.
2020-05-20 20:29:37 +02:00
Danny Ryan
4ac2fc7eff
add missing column description fo SECONDS_PER_ETH1_BLOCK
...
Co-authored-by: Diederik Loerakker <proto@protolambda.com>
2020-05-20 12:28:08 -06:00
Danny Ryan
c9f21f1f43
clarify that eth1 blocks must be at a safe fllow distance before being considered for genesis
2020-05-20 10:44:08 -06:00
Danny Ryan
943e51aef1
hww feedback for finality rewards fix
2020-05-20 10:12:57 -06:00
Danny Ryan
95c3295eeb
move proposer negation to inactivity_penalty deltas
2020-05-19 17:17:20 -06:00
Danny Ryan
85e78223dd
ensure when performing optimally that you don't lose money during a leak
2020-05-19 16:51:46 -06:00
Hsiao-Wei Wang
cd91380d80
PR feedback from proto: set `length` back to `int`
2020-05-20 03:05:03 +08:00
Hsiao-Wei Wang
8f70453aef
PR feedback from Proto
2020-05-20 03:04:52 +08:00
Hsiao-Wei Wang
9f340d5fd1
(i) Fix leftover (ii) `SHARD_COMMITTEE_PERIOD` should be uint64
2020-05-20 03:04:41 +08:00
Hsiao-Wei Wang
88d7315739
Fix typing
2020-05-20 03:04:29 +08:00
Hsiao-Wei Wang
2bf020d49d
Apply strict uint64 casting
2020-05-20 03:04:15 +08:00
Danny Ryan
fdc7e846df
remove incorrect table format
2020-05-19 10:37:42 -06:00
Danny Ryan
724139a1f8
change gossipsub protocol ID to /meshsub/1.1.0
2020-05-19 10:23:12 -06:00
Danny Ryan
095b87c2a2
Merge branch 'dev' into v012x
2020-05-19 10:02:18 -06:00
Danny Ryan
de03ebb143
many custody game formatting cleanups
2020-05-19 09:58:33 -06:00
Danny Ryan
78947548e6
add process_challenge_deadlines to process_epoch
2020-05-19 08:31:01 -06:00
Danny Ryan
1623086088
make get_validator_from_deposit for better code reuse across phase 0 and 1
2020-05-19 08:14:04 -06:00
Danny Ryan
7fc9dbf297
clarify comment for ShardTransition.shard_data_roots
2020-05-19 07:52:26 -06:00
Danny Ryan
3f0e58a8ed
add chunk challenge and response to block and operations
2020-05-19 07:50:05 -06:00
Danny Ryan
3851a26a0f
add phase 1 custody objects to custody-game.md
2020-05-19 07:34:06 -06:00
Danny Ryan
665538253a
Merge pull request #1807 from ericsson49/ericcson49/fix_is_valid_fraud_proof
...
is_valid_fraud_proof bug fixes
2020-05-18 13:37:13 -06:00
Danny Ryan
c5367295c3
Merge branch 'dev' into v012x
2020-05-18 13:32:24 -06:00
Danny Ryan
b7cfa94cb4
Merge branch 'dev' into v0113-dev-merge
2020-05-18 13:22:16 -06:00
Danny Ryan
6f685a97e2
Merge branch 'dev' into v012x
2020-05-18 09:29:47 -06:00
Danny Ryan
7daa6c0039
Merge pull request #1810 from terencechain/patch-97
...
Make obvious that `source_epoch` does not underflow
2020-05-18 08:12:50 -06:00
Danny Ryan
4a86c39712
Merge pull request #1799 from ethereum/bls_v2
...
Update to IETF BLS draft-irtf-cfrg-bls-signature-02 + draft-irtf-cfrg-hash-to-curve-07
2020-05-18 07:35:49 -06:00
Danny Ryan
74c900f814
add conditoin that block must be later than latest_block_header
2020-05-15 16:43:53 -06:00
terence tsao
6f5cbe6182
Update shard-transition.md
2020-05-14 14:55:29 -07:00
Danny Ryan
96ab76dcb2
Merge pull request #1804 from ethereum/use-all-attnets
...
[for discussion] Use all attestation subnets in phase 0
2020-05-14 14:29:05 -06:00
Danny Ryan
483f9a1d7b
Update specs/phase0/p2p-interface.md
...
Co-authored-by: Diederik Loerakker <proto@protolambda.com>
2020-05-14 14:25:32 -06:00
Hsiao-Wei Wang
ab3cbdae75
Add a note of `len(attestations) > 0`
2020-05-15 04:05:51 +08:00
Danny Ryan
3dd168335b
reformat compute_subnet_for_attestation to not use for loop
2020-05-14 13:50:29 -06:00
Danny Ryan
689a6955b0
Merge pull request #1812 from ethereum/no_signature
...
Handle phase 1 `PKs == []` cases
2020-05-14 11:15:06 -06:00
Hsiao-Wei Wang
f0c4623871
Apply PR feedback: add docstring
2020-05-15 01:05:32 +08:00
Danny Ryan
c91e017b1f
Merge pull request #1801 from ethereum/non-aggregator-att
...
Loosen restrictions for aggregate propogation
2020-05-14 11:01:32 -06:00
Hsiao-Wei Wang
6a3241be61
Remove leading space
...
Co-authored-by: Danny Ryan <dannyjryan@gmail.com>
2020-05-15 00:48:53 +08:00
Hsiao-Wei Wang
aa436d91b2
Use NO_SIGNATURE (0x00...) approach
2020-05-14 22:25:55 +08:00
Hsiao-Wei Wang
183b197888
Update specs/phase1/beacon-chain.md
2020-05-14 21:25:36 +08:00
terence tsao
23e2b83e20
Update specs/phase1/beacon-chain.md
...
Co-authored-by: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-05-14 06:21:44 -07:00
terence tsao
f3448e51dd
Update specs/phase1/beacon-chain.md
...
Co-authored-by: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-05-14 06:21:36 -07:00
terence tsao
aef564733a
Update beacon-chain.md
2020-05-13 10:56:52 -07:00
protolambda
68442c2eef
Update testing and restrict to incremental block transitions
2020-05-13 16:46:28 +02:00
ericsson
b41410eade
lint problem fixed
2020-05-13 16:25:16 +03:00
ericsson
4431e399b1
Fix bugs:
...
- `range(len(col))`` instead of `range(col)`
- `beacon_parent_block.body.shard_transitions` instead of `beacon_parent_block.shard_transitions`
- `shard_states[len(shard_states)-1]` instead of `shard_states[-1]`
2020-05-13 16:13:33 +03:00
Hsiao-Wei Wang
4a246ba5ac
Apply feedback from Danny, add a note of the hash to curve configuration
2020-05-13 13:01:08 +08:00
Hsiao-Wei Wang
3c11a4dc02
Fix `AggregateVerify` param name: `message` -> `messages`
...
Co-authored-by: Danny Ryan <dannyjryan@gmail.com>
2020-05-13 12:56:50 +08:00
Hsiao-Wei Wang
2718dcc4ab
Update IETF standard description
2020-05-13 02:34:10 +08:00
Danny Ryan
511f803496
use all attnets across the epoch even when not max committees per slot
2020-05-11 12:52:52 -06:00
Danny Ryan
ef18010778
Merge pull request #1800 from ethereum/reqresp-sizes
...
Update p2p reqresp with explicit handling of reqresp size bounds
2020-05-11 11:48:31 -06:00
Danny Ryan
ca1876e12f
Merge pull request #1795 from ethereum/clarify-blocks-request
...
Clarify BlocksByRange request
2020-05-11 11:39:10 -06:00
Danny Ryan
30ecd9b602
p2p PR feedback
2020-05-11 11:22:34 -06:00
Danny Ryan
17f656cefe
Merge branch 'dev' into v012x
2020-05-11 10:41:35 -06:00
protolambda
fcf003859d
remove duplicate response diagram
2020-05-11 17:01:18 +02:00
Danny Ryan
b4bc2038e1
clarify that clients MAY stop block requests if fork choice changes
2020-05-11 08:39:30 -06:00
Danny Ryan
7d4d3e43ef
remove aggregate clarifiyng text that is not longer valid
...
Co-authored-by: Diederik Loerakker <proto@protolambda.com>
2020-05-11 08:38:22 -06:00
Paul Hauner
b3dd99f4f4
Loosen restrictions for aggregate propogation
2020-05-11 08:28:21 -06:00
Danny Ryan
3fb4c43fae
Merge pull request #1794 from ethereum/2x-attester-slashings
...
MAX_ATTESTER_SLASHINGS == 2 and add multiple slashings per block tests
2020-05-11 08:12:23 -06:00
protolambda
a8e3fe7551
Update p2p reqresp with explicit handling of reqresp size bounds
2020-05-09 21:44:28 +02:00
Hsiao-Wei Wang
cdd0ed0f7b
Update to IETF BLS draft-irtf-cfrg-bls-signature-02
2020-05-09 11:48:48 +08:00
Danny Ryan
fdcc6d65bc
gossipsub v1.1 and extended validators for gossip conditions
2020-05-08 12:00:05 -06:00
Danny Ryan
01eaf6cc99
Clarify the response of BlocksByRange to address #1765
2020-05-08 11:09:12 -06:00
Danny Ryan
7a130606ac
hww feedback
2020-05-08 10:51:41 -06:00
Danny Ryan
1137e0332d
move MAX_ATTESTER_SLASHINGS to 2, add multiple slashings per block tests
2020-05-08 10:43:11 -06:00
Danny Ryan
08652f543b
Merge branch 'v012x' into empty-bits-case
2020-05-07 10:17:26 -06:00
Danny Ryan
7625728fb8
Merge pull request #1742 from ethereum/ffg_lmd_vote_consistency
...
Added FFG-LMD vote consistency checks
2020-05-07 09:36:52 -06:00
Danny Ryan
4f401133e1
address PR feedback from @protolambda
2020-05-05 15:37:14 -06:00
Danny Ryan
b71a0ee6b9
Merge branch 'v012x' into ffg_lmd_vote_consistency
2020-05-05 13:40:27 -06:00
Danny Ryan
38f29ba0a8
remove PERSISTENT_COMMITTEE_PERIOD in favor of SHARD_COMMITTEE_PERIOD
2020-05-05 11:44:53 -06:00
Danny Ryan
b2c36112f6
Merge branch 'dev' into v012x
2020-05-05 09:44:27 -06:00
Hsiao-Wei Wang
79b1b4bdbe
Add `(shard, shard_root)` to `LatestMessage`
2020-05-05 21:42:18 +08:00
Hsiao-Wei Wang
fca1bbccb9
Remove `get_filtered_shard_block_tree`
2020-05-05 21:42:13 +08:00
Hsiao-Wei Wang
8fafb6a9e5
Make `ShardStore` an independent object
2020-05-05 21:42:06 +08:00
Hsiao-Wei Wang
cddf9cf114
Refactor
2020-05-05 21:42:00 +08:00
Hsiao-Wei Wang
dab5a936c4
wip shard fork choice rule
2020-05-05 21:41:46 +08:00
Hsiao-Wei Wang
ee4c866575
Merge branch 'dev' into dankrad-custody-256bit-merging
2020-05-05 15:22:36 +08:00
Danny Ryan
3f250f7dd3
PR feedback
2020-05-04 21:05:10 -06:00
Danny Ryan
a7354bd358
Merge branch 'dev' into rewards-rework
2020-05-04 13:34:35 -06:00
Danny Ryan
71dc744f42
Merge pull request #1703 from ethereum/hwwhww/signed_pattern
...
Rework shard block and fraud proof (shard state transition) spec
2020-05-04 10:39:47 -06:00
Hsiao-Wei Wang
7a770186b5
Reorg beacon-chain spec a bit
2020-05-02 02:32:37 +08:00
Hsiao-Wei Wang
4558c7db4e
Reorg the file structure
2020-05-02 02:32:37 +08:00
Hsiao-Wei Wang
b43e24acb6
specs/phase1/fraud-proofs.md -> specs/phase1/shard-transition.md
2020-05-02 02:32:37 +08:00
Hsiao-Wei Wang
ff85025113
PR feedback from terence
2020-05-02 02:32:37 +08:00
Hsiao-Wei Wang
e758fb76c2
Check `head_shard_root` of all `transition_attestations`
2020-05-02 02:32:36 +08:00
Hsiao-Wei Wang
524ba166d1
[squashed] shard chain updates wip
...
Fix wrong field names
Fix `build_attestation_data` and other PR feedback from Danny and
Terence
1. Rename `get_previous_slot` to `compute_previous_slot`
2. Break down `build_empty_block` into
`get_state_and_beacon_parent_root_at_slot`, use it in
`build_shard_block`
3. Set defult `slot` to `shard_state.slot + 1` in `build_shard_block`
Update `verify_shard_block_message`: check beacon_parent_root at fork
choice rule stage instead of state transition
Fix `beacon-chain.md`
1. Fix typo `attestation.slot == state.slot` -> `attestation.data.slot == state.slot` in `is_winning_attestation`
2. Check `verify_shard_transition_false_positives` **after** `process_operations`
3. Fix `shard_attestations` filter in `process_crosslinks`: since attestations come from block, should use `attestation.data.slot + MIN_ATTESTATION_INCLUSION_DELAY == state.slot`
4. [TBD] Allow empty `light_client_signature` to make the tests pass
5. [TBD] Add `is_shard_attestation`, filter out empty `ShardTransition()`
Rework `test_process_crosslink`
Add basic phase 1 `test_blocks`
Add more test cases
Revert `is_shard_attestation` and fix test cases backward compatibility.
Remove `test_process_beacon_block_no_shard_transition` and consider it as invalid case.
2020-05-02 02:32:31 +08:00
Hsiao-Wei Wang
c8a473ba24
Apply suggestions from code review
...
Co-Authored-By: Danny Ryan <dannyjryan@gmail.com>
2020-05-02 02:32:30 +08:00
Hsiao-Wei Wang
40483b587b
[squashed] shard chain updates wip
...
Use `ShardBlock` in `shard_state_transition`
PR feedback
1. Rename `ShardState.data` -> `ShardState.transition_digest`
2. Rename `compute_shard_transition_data` to `compute_shard_transition_digest`
3. Add `assert state.slot > PHASE_1_GENESIS_SLOT` just in case, may move it later
Add `get_post_shard_state` as a pure function wrapper
2020-05-02 02:32:24 +08:00
Hsiao-Wei Wang
85d5a9abaf
[squashed] shard chain updates wip
...
PR feedback from Danny and some refactor
1. Add stub `PHASE_1_GENESIS_SLOT`
2. Rename `get_updated_gasprice` to `compute_updated_gasprice`
3. Rename `compute_shard_data_roots` to `compute_shard_body_roots`
Apply shard transition for the skipped slots
Refactor `shard_state_transition`
Get `beacon_parent_root` from offset slot
Add more test
Add `verify_shard_block_message`
Add `> 0`
Keep `beacon_parent_block` unchanged in `is_valid_fraud_proof`
Remove some lines
Fix type
Refactor + simplify skipped slot processing
2020-05-02 02:31:54 +08:00
Hsiao-Wei Wang
9724cb832d
Apply suggestions from code review from @djrtwo
...
Co-Authored-By: Danny Ryan <dannyjryan@gmail.com>
2020-05-02 02:31:53 +08:00
Hsiao-Wei Wang
afa12caf1f
Refactor `get_shard_state_transition_result`
2020-05-02 02:31:53 +08:00
Hsiao-Wei Wang
4e8a7ff115
[squashed] shard transition wip
...
Fix the wrong `get_shard_proposer_index` parameters order
Phase 1 WIP
Add shard transition basic test
Fix lint error
Fix
2020-05-02 02:31:10 +08:00
Hsiao-Wei Wang
849d3f83bf
Apply @terencechain 's review feedback
...
Co-Authored-By: terence tsao <terence@prysmaticlabs.com>
2020-05-02 02:31:09 +08:00
Hsiao-Wei Wang
247a6c8fca
Add `verify_fraud_proof` function
2020-05-02 02:31:09 +08:00
Hsiao-Wei Wang
be50020bf8
Refactor `get_light_client_committee` to similar to
...
`get_shard_committee`
2020-05-02 02:31:08 +08:00
Hsiao-Wei Wang
5f69afea38
Make `shard_state_transition` more like beacon state_transition function
2020-05-02 02:31:08 +08:00
Hsiao-Wei Wang
e9f1e4186d
Add `proposer_index` to shard block
2020-05-02 02:31:08 +08:00
Hsiao-Wei Wang
feb27a14be
beacon-chain.md: Replace block wrapper with signable pattern
2020-05-02 02:31:08 +08:00
Danny Ryan
c2c27791c5
Merge branch 'dev' into rewards-rework
2020-05-01 10:52:19 -06:00
protolambda
09cae4b3cc
Handle empty-aggregation-bits case, and add tests. See #1713
2020-05-01 15:17:41 +02:00
Dankrad Feist
964bf42335
Fix type
2020-05-01 00:32:02 +01:00
Dankrad Feist
d30f11a781
Fix lint
2020-05-01 00:16:00 +01:00
Dankrad Feist
d58d7627b7
Fix toc
2020-04-30 19:25:18 +01:00
Danny Ryan
4b4fc32f9c
Merge pull request #1755 from paulhauner/patch-23
...
Fork choice: Remove redundant check in validate_on_attestation
2020-04-30 11:06:29 -06:00
Paul Hauner
2dc5156651
Add message about delaying consideration
2020-04-30 16:27:02 +10:00
Danny Ryan
6a40f71a31
add note about beacon committees not going into attnets
2020-04-29 20:29:48 -06:00
Danny Ryan
cd27e5e045
add tests for source, target, head
2020-04-29 10:23:12 -06:00
Danny Ryan
5f18dd778c
add baseline get_target_deltas tests
2020-04-28 19:26:14 -06:00
Danny Ryan
4a086fba5c
Merge branch 'dev' into rewards-rework
2020-04-28 17:24:45 -06:00
Dankrad Feist
0e2931b9b3
All tests passed
2020-04-28 01:09:20 +01:00
Danny Ryan
87586837c3
remove interop from phase 0 p2p specs
2020-04-27 17:39:39 -06:00
Danny Ryan
d128400da5
remove interop from header and gossip sections in network spec
2020-04-27 17:39:31 -06:00
Danny Ryan
553a33cd2d
Merge pull request #1766 from ethereum/dev
...
backport dev to v012x
2020-04-27 17:35:28 -06:00
Diederik Loerakker
9d39c292e0
Merge pull request #1763 from ethereum/master
...
Backport v0.11.2 hotfixes from master to dev
2020-04-28 00:18:52 +02:00
Danny Ryan
dae623b097
Merge pull request #1756 from byz-f/q9-genesis-eth1
...
genesis: clarify that eth1 timestamp can be less than min genesis time
2020-04-27 10:15:18 -06:00
Dankrad Feist
2449db1bb6
Phase 1 block tests are working
2020-04-27 16:08:49 +01:00
Hsiao-Wei Wang
2dbc333270
Make `compute_new_state_root` a pure function
2020-04-27 22:18:43 +08:00
Hsiao-Wei Wang
4d980aec71
Fix validator guide
...
1. Avoid negative computation in `is_candidate_block`
2. Fix `get_block_signature`: avoid extra casting; it's simpler to use BeaconBlock instead of
BeaconHeader
2020-04-27 21:47:24 +08:00
Raw Pong Ghmoa
c841aa102b
genesis: clarify that eth1 timestamp can be less than min genesis time
2020-04-26 10:09:22 +02:00
Paul Hauner
1a81c873af
Remove redundant check in fork choice
2020-04-26 16:24:16 +10:00
Aditya Asgaonkar
9acea51938
Simplified by re-using get_ancestor()
2020-04-25 14:17:28 -07:00
protolambda
0c67aaa68e
Include fork digest in example gossip topic name
2020-04-25 00:05:37 +02:00
Danny Ryan
fde9b410f0
Merge pull request #1752 from ethereum/dev
...
sync v0.11.2 to `v012x`
2020-04-24 11:36:17 -06:00
Dankrad Feist
ab2ee0e2c2
Restoring chunk challenges and testing
2020-04-24 17:06:27 +01:00
Paul Hauner
bf806b9efa
Require "seen" aggregates to be valid
2020-04-24 15:01:18 +10:00
Danny Ryan
7612667bbe
minor feedback and fixes on rewards/penalites proposal
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-04-23 11:13:09 -06:00
Danny Ryan
fe13bab338
rework rewards/penalties to be more granular
2020-04-23 10:26:34 -06:00
Danny Ryan
11d164748c
add 'valid' when de-deduplication of attestations on gossip subnets
2020-04-22 14:45:01 -06:00
Danny Ryan
d8662d49ea
Merge pull request #1730 from ethereum/bootnode-enr
...
add note about distributing bootnode ENRs prior to genesis
2020-04-22 14:38:38 -06:00
Danny Ryan
3d4122a2f6
add note about distributing bootnode ENRs prior to genesis
2020-04-22 14:33:57 -06:00
Aditya Asgaonkar
9bbac0d2cc
Added consistency check for FFG & LMD vote in validate_on_atttestation(), fixes #1636 , fixes #1456 , fixes #1408
2020-04-21 23:56:44 -07:00
Justin
5929aac799
Cosmetic changes from #1737
2020-04-22 11:40:10 +08:00
Danny Ryan
a6b2679cb0
Merge pull request #1739 from ethereum/JustinDrake-patch-4
...
Partial fix for #1701
2020-04-21 08:44:22 -06:00
Justin
3436021e72
Update beacon-chain.md
2020-04-21 15:34:55 +01:00
Danny Ryan
ebf888bcf7
Merge pull request #1736 from status-im/rannge-req
...
simplify block range request description
2020-04-21 08:21:57 -06:00
Justin
e2a320ef32
Partial fix for #1701
...
Clarify that state transitions with `uint64` overflows are invalid.
2020-04-21 08:59:53 +01:00
Justin
508811d641
Fix #1735—remove redundant check
...
As per #1735 the check `if not len(indices) <= MAX_VALIDATORS_PER_COMMITTEE: return False` is redundant. As such this PR should be purely cosmetic.
2020-04-21 08:50:42 +01:00
Jacek Sieka
4915014a19
simplify block range request description
...
There's room for ambiguity as to what `count` means - this clarifies
that it always relates to the slot, and not the number of blocks in the
response which allows clients to request ranges epoch by epoch (for
example) without worrying about overlaps caused by empty slots.
2020-04-20 20:03:15 +02:00
Hsiao-Wei Wang
6fdee75475
Fix phase0 types
2020-04-17 23:55:25 +08:00
Danny Ryan
e58cfedb68
clarify ssz_snappy for gossip
2020-04-16 11:12:24 -06:00
Danny Ryan
4a94200c0b
Merge pull request #1712 from ethereum/hwwhww/inactivity_penalty_quotient_bug
...
Fix `INACTIVITY_PENALTY_QUOTIENT`
2020-04-14 11:53:43 -06:00
Hsiao-Wei Wang
b2f6325db3
Fix `compute_committee`
2020-04-09 17:50:23 +08:00
Hsiao-Wei Wang
890c27d091
The input parameter `index` in `compute_shuffled_index` is the position of the given list, not `ValidatorIndex`
2020-04-09 17:33:14 +08:00
Hsiao-Wei Wang
c10e59bdf7
Fix `INACTIVITY_PENALTY_QUOTIENT`
...
The amount of inactivity penalty was adjusted to half since we were applying penalty for missing FFG target and source. But now we only apply it for missing target, so `INACTIVITY_PENALTY_QUOTIENT` should be `2**24`.
2020-04-08 10:32:16 +08:00
Danny Ryan
2a36f366ef
Merge pull request #1710 from paulhauner/patch-20
...
Tighten aggregate attn propogation condition
2020-04-07 18:56:04 -06:00
Danny Ryan
26492651b6
Merge pull request #1706 from paulhauner/patch-19
...
Redefine attestation propogation condition
2020-04-07 18:55:41 -06:00
Paul Hauner
c96a3366fa
Tighten aggregate attn propogation condition
2020-04-07 16:07:41 +10:00
Paul Hauner
616385a094
Fix spelling mistake
2020-04-07 07:45:15 +10:00
Paul Hauner
021cb98dbb
Use epoch for attestation subnet seen-ness.
2020-04-07 07:05:51 +10:00
Danny Ryan
bdf087d7f3
add notes about how to handle peer discovery and gossip topics prior to genesis
2020-04-06 09:57:23 -06:00
Paul Hauner
7d4b97240b
Redefine attestation propogation condition
2020-04-06 17:46:33 +10:00
Dankrad Feist
907c56dabd
Fix ToC
2020-04-05 15:47:59 +01:00
Dankrad Feist
c3c24b4fc4
Fix lint
2020-04-05 15:35:11 +01:00
Dankrad Feist
bf34fdf023
Fix ToC
2020-04-05 15:10:09 +01:00
Dankrad Feist
ca6af0c2e9
256-bit custody atoms for better alignment with rest of the spec and greater efficiency
2020-04-05 14:39:00 +01:00
Danny Ryan
f135eff021
add lookahed for shard subnets for beacon committee in validator guide
2020-04-03 13:23:38 -06:00
Danny Ryan
e86c5ef41d
final PR nitpicks
2020-04-03 10:29:35 -06:00
Danny Ryan
c3e5ddaabc
Merge branch 'dev' into phase1-tests
2020-04-03 09:54:34 -06:00
Danny Ryan
246b46771e
address @hwwhww feedback
2020-04-03 09:46:57 -06:00
Danny Ryan
f2c2da95ed
add compute_offset_slots
2020-04-03 09:19:56 -06:00
Danny Ryan
d61b2991a0
fix lint
2020-04-02 16:58:39 -06:00
Danny Ryan
6067c511c5
add light client to phase 1 validator
2020-04-02 16:48:02 -06:00
Danny Ryan
d789f3d32d
getting phase 1 val guide in place
2020-04-02 15:09:45 -06:00
Danny Ryan
613f368c00
fix call to get_beacon_committee in process_crosslink_for_shard
2020-04-01 12:20:32 -06:00
Danny Ryan
16208790a5
Merge pull request #1699 from ethereum/hwwhww/unpack_compact_validator
...
Add `unpack_compact_validator` back
2020-03-31 10:40:45 -06:00
Hsiao-Wei Wang
f82cdb7e68
beacon-chain.md: add `unpack_compact_validator` for `light-client-sync.md`
2020-03-31 22:13:48 +08:00
Hsiao-Wei Wang
071f6b5126
Gasprice rework: use `MIN_GASPRICE` as the initial gasprice and change `MIN_GASPRICE` to 8 gwei
2020-03-31 22:09:20 +08:00
Paul Hauner
2daa26442b
Tighten restriction on a "seen" attestation
...
Declares that only a verified block can stop an attestation from being propagated.
This achieves two things:
1. Ensures that clients don't need to scan invalid blocks for attestations and then modify their state based upon them.
1. Disallows "muting" attestations by sending around a junk block with that attestation in it.
2020-03-30 10:44:46 +11:00
Danny Ryan
073f78efa1
Merge branch 'dev' into phase1-tests
2020-03-29 17:04:25 -06:00
Danny Ryan
d07aa00307
Merge pull request #1692 from ethereum/master
...
Backport v0.11.1 to dev
2020-03-29 16:38:50 -06:00
Danny Ryan
d42e08a6e1
verify proposer sig before proposer shuffling in p2p block gossip conditions
2020-03-26 11:43:32 -06:00
Danny Ryan
c46fe86839
Merge branch 'v011x' into publish-vs-subscribe
2020-03-26 10:48:23 -06:00
Danny Ryan
a83e7a5ecc
proto PR feedback
2020-03-26 10:46:06 -06:00
Danny Ryan
050b42806d
Merge pull request #1684 from ethereum/enr-ping
...
MetaData and Ping
2020-03-26 10:40:46 -06:00
Danny Ryan
ee45cf77ef
proto feedback on MetaData
2020-03-26 07:47:20 -06:00
Danny Ryan
7af6a3afa4
do not require non-aggregating validators to subscribe to attestation subnet for beacon committee duties
2020-03-25 15:56:26 -06:00
Danny Ryan
d5a9af6469
update ping protocol to use MetaData
2020-03-25 12:08:27 -06:00
Danny Ryan
b8d25dc5b4
Merge pull request #1682 from ethereum/reward-acc-bug
...
Attestation reward bug
2020-03-24 19:36:23 -06:00
Paul Hauner
88fddf2379
Remove unneccessary clock disparity check
...
There is no need to mention clock disparity when comparing two static slot values (assuming the clock disparity is less than a slot, even then I don't think that's the intention).
2020-03-24 08:13:36 -06:00
Michael Sproul
1c49f99094
Fix bug in attestation reward calculation
2020-03-24 07:40:58 -06:00
Age Manning
f227e026fa
Draft PING and ENR rpc protocol
2020-03-24 15:10:47 +11:00
Age Manning
cf20a7ae3e
Shift some ENR fields to MAY
2020-03-24 15:07:43 +11:00
Danny Ryan
2978f21a39
minor edit to validator get_attestation_signature
2020-03-19 15:17:06 -06:00
Jacek Sieka
759af67345
Normalize attestation signature getter name
2020-03-19 15:13:59 -06:00
Danny Ryan
2b8c32a347
Merge pull request #1664 from ethereum/div-zero-total-balance
...
avoid div by zero in extreme balance case
2020-03-19 08:50:09 -06:00
Danny Ryan
0a9b306d60
PR feedback from @hwwhww
2020-03-18 09:55:09 -06:00
Danny Ryan
e6998a61cd
remove IK handshake from noise spec (removed in core libp2p specs)
2020-03-17 10:54:48 -06:00
Danny Ryan
e2ef4365e2
min total balance is now EFFECTIVE_BALANCE_INCREMENT. update testing
2020-03-16 11:19:21 -06:00
Danny Ryan
d299b06a1c
fix custody bit calculation format
2020-03-16 09:52:27 -06:00
Danny Ryan
5315f3db35
clarify proposer_index must be from expected shuffling when validating block gossip
2020-03-13 12:00:34 -06:00
Dankrad Feist
9b7e0ab2be
Fix error in custody bit computation
2020-03-13 17:15:25 +00:00
Danny Ryan
1293320675
Merge branch 'dev' into phase1-tests
2020-03-12 07:12:41 -06:00
Danny Ryan
c894f5ecec
fork choice error note
2020-03-11 16:41:27 -06:00
Danny Ryan
a612df1119
minor typos and clarifications in fork choice
2020-03-11 16:11:42 -06:00
Danny Ryan
47bbffa0d6
'get_checkpoint_store' -> 'get_forkchoice_store' typo
2020-03-11 15:03:14 -06:00
Danny Ryan
81dc71c312
Merge pull request #1652 from ethereum/gossip-topics-with-fork-digest
...
Gossip topics with fork digest
2020-03-11 13:32:25 -06:00
Danny Ryan
4bcdf91e8b
Apply suggestions from code review
...
PR feedback
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-03-11 13:24:30 -06:00
Danny Ryan
36e48fba99
enforce must match target to match head to avoid perverse incentive path
2020-03-11 12:51:05 -06:00
Danny Ryan
0881e21dc5
cleanup gossip topic fork digest based on PR feedback
2020-03-11 12:02:31 -06:00
Danny Ryan
baee673124
add note about preparing for subnet backbone for forks
2020-03-10 17:29:39 -06:00
Danny Ryan
e2918c6364
Merge pull request #1626 from ethereum/proposer-index
...
add proposer index to BeaconBlock
2020-03-10 15:10:07 -06:00
Danny Ryan
fccd3ab1ce
clarify hex-encoded bytes string representation for fork digest in gossip topic
...
Co-Authored-By: Diederik Loerakker <proto@protolambda.com>
2020-03-10 15:04:44 -06:00
Danny Ryan
415544bf03
modify gossip topics to use ForkDigest
2020-03-10 14:44:35 -06:00
Danny Ryan
b25ca8e32c
Merge branch 'gossip-topic' of https://github.com/status-im/eth2.0-specs into status-im-gossip-topic
2020-03-10 14:02:44 -06:00
Diederik Loerakker
ab24e7cab7
Merge pull request #1651 from ethereum/revert-forkchoice-header
...
revert fork choice store.blocks to BeaconBlock
2020-03-10 20:25:18 +01:00
Danny Ryan
3b7704a78f
Merge pull request #1649 from ethereum/eth1-voting-period-in-epochs
...
Eth1 voting period in epochs [updated for configs/phase1/tests compat.]
2020-03-10 13:24:03 -06:00
Danny Ryan
1c9ca3c168
Merge pull request #1635 from ethereum/rewards-overflow
...
handle rewards overflow
2020-03-10 13:23:21 -06:00
Danny Ryan
c91eee6bdf
revert fork choice store.blocks to store BeaconBlock
2020-03-10 13:20:57 -06:00
Danny Ryan
0d01299d17
Merge pull request #1648 from sgryphon/feature/clarify-store-signed-block
...
Put back in a requirement to store recent signed blocks
2020-03-10 13:13:33 -06:00
Danny Ryan
1579072e15
add note about total balance overflowing
2020-03-10 13:12:17 -06:00
Danny Ryan
d6eedd95c0
fix wording to be clear it is about serving blocks
...
Co-Authored-By: Diederik Loerakker <proto@protolambda.com>
2020-03-10 13:04:28 -06:00
Danny Ryan
bd5231a975
Merge pull request #1614 from ethereum/eth2-enr
...
add eth2 key/value ENR to phase 0 p2p
2020-03-10 13:02:32 -06:00
Danny Ryan
1818f349ad
add ForkDigest type, clarify how genesis_validators_root is mixed into domains for chain isolation in p2p faq
2020-03-10 11:59:34 -06:00
protolambda
55d436db51
simplify description of voting period time
2020-03-10 18:55:59 +01:00
protolambda
2d7a292d36
eth1 vote period constant in epochs: update configs, phase1, tests
2020-03-10 18:36:53 +01:00
Hsiao-Wei Wang
882b9ee035
Merge branch 'dev' into rewards-overflow
2020-03-11 00:41:17 +08:00
Sly Gryphon
da5720f9d1
Put back in a requirement to store recent signed blocks that was removed when SignedBeaconBlock was introduced (prior to that the signature was in BeaconBlock, which was recorded in Store).
2020-03-10 21:31:03 +10:00
Danny Ryan
92eef0e00b
fix light client sig verification in phase 1
2020-03-09 14:52:30 -06:00
Danny Ryan
6230a22976
Merge pull request #1606 from ethereum/rpc-snappy-lengths
...
RPC chunks with streaming SSZ decoding, snappy frames, and stricter DOS limits where possible.
2020-03-09 11:04:12 -06:00
Danny Ryan
7e04989e29
add genesis_validators_root to beaconstate and utilize in sig domain separation as well as fork separation
2020-03-05 09:21:32 -07:00
Danny Ryan
37b1fed8ff
update eth2 ENR field to use ENRForkID
2020-03-04 14:16:30 -07:00
Danny Ryan
5dae252f56
add eth2 key/value ENR to phase 0 p2p
2020-03-04 12:33:23 -07:00
Danny Ryan
f082aa6ca9
use EFFECTIVE_BALANCE_INCREMENT to normalize reward calculations
2020-03-03 15:34:02 -07:00
Danny Ryan
5e1fb79a8e
Merge pull request #1627 from ethereum/hysteris-fix
...
adjust hysteresis to avoid initial over-deposit incentive
2020-03-03 14:15:24 -07:00
Danny Ryan
33e7680836
make hysteresis calculations configurable
2020-03-03 10:58:47 -07:00
Danny Ryan
2d4ec7d52f
add REWARD_OVERFLOW_INCREMENT to avoid overflow in rewards calculation
2020-03-03 10:23:08 -07:00
Hsiao-Wei Wang
b4c7481b35
Fix the misc table
2020-03-03 01:28:58 +01:00
Danny Ryan
0122081d05
hysteresis to -0.25/+1.25
2020-03-02 15:55:01 -07:00
Jacek Sieka
38323d8186
Add faq
2020-03-01 17:17:29 +01:00
Danny Ryan
186d4258b6
fix shard offsets
2020-02-28 13:20:37 -06:00
protolambda
bb82a051ff
clean up, add invalid input handling
2020-02-27 19:39:34 +00:00
Danny Ryan
4d72dcf3ab
@hwwhww feedback
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2020-02-27 12:00:55 -06:00
Danny Ryan
9718d206a7
fix attester slahsing test
2020-02-26 11:20:19 -06:00
Danny Ryan
721f605a91
Merge branch 'dev' into phase1-tests
2020-02-22 12:10:35 -06:00
Danny Ryan
4c1fc9bffa
work through phase 1 tests
2020-02-22 12:06:31 -06:00
Danny Ryan
97fa3741af
working through test issues
2020-02-22 09:30:33 -06:00
Danny Ryan
ceb6633eb9
working through phase 1 attestation testing
2020-02-22 09:24:14 -06:00
Ben Edgington
934c037a8a
Correct the duration of HISTORICAL_ROOTS_LIMIT
...
The duration of HISTORICAL_ROOTS_LIMIT is:
SECONDS_PER_SLOT * SLOTS_PER_HISTORICAL_ROOT * HISTORICAL_ROOTS_LIMIT
which is
12s * 2^13 * 2^24 = 1.65e12s = 52,262 years
2020-02-22 09:22:52 -06:00
Danny Ryan
3bb8e0d962
cleanup attester slashing conditon code snippet
...
Co-Authored-By: Diederik Loerakker <proto@protolambda.com>
2020-02-22 09:22:52 -06:00
Danny Ryan
f671b86776
add DoS prevention validation conditions to voluntary_exit, proposer_slashing, and attester_slashing gossipsub channels
2020-02-22 09:22:52 -06:00
Danny Ryan
7329cc0933
pr feedback
...
Co-Authored-By: Diederik Loerakker <proto@protolambda.com>
2020-02-22 09:22:51 -06:00
Danny Ryan
3404f1e078
add lower bound condition on block gossip
2020-02-22 09:22:51 -06:00
Danny Ryan
581257e269
reorder gossip conditions to put cheap checks before signature verifications
2020-02-22 09:22:51 -06:00
Danny Ryan
f7181adece
reverse params in get_aggregate_and_proof to match ssz type
2020-02-22 09:22:51 -06:00
Danny Ryan
d2e08c0cdf
subnet validation PR feedback
2020-02-22 09:22:51 -06:00
Danny Ryan
dde69cb8e2
add explicit instrucutions for construction of signed_aggregate_and_proof. add DOMAIN_SELECTION_PROOF and DOMAIN_AGGREGATE_AND_PROOF
2020-02-22 09:22:51 -06:00
Danny Ryan
5ee1f9b545
fix up some p2p validation conditions based on PR feedback
2020-02-22 09:22:50 -06:00
Danny Ryan
fd633d2467
add clarifying note to signedaggregateandproof in vaidator guide and fix tocs
2020-02-22 09:22:50 -06:00
Danny Ryan
343168908c
prevent multiple beacon blocks from same proposer in a given slot
2020-02-22 09:22:50 -06:00
Danny Ryan
8da7a84eb7
create SignedAggregateAndProof to prevent DoS attacks
2020-02-22 09:22:50 -06:00
Danny Ryan
047936eb2d
Add no repeat attestation condition for committee_index_beacon_attestation gossip channel
2020-02-22 09:22:50 -06:00
Danny Ryan
0a849acdce
fix validator guide to show that block slashing is per slot rather than per epoch
2020-02-22 09:22:49 -06:00
Danny Ryan
d414aac933
rework process_attestation and work through tests
2020-02-22 09:22:49 -06:00
Jacek Sieka
61f661b3ec
Update specs/phase0/p2p-interface.md
...
Co-Authored-By: Danny Ryan <dannyjryan@gmail.com>
2020-02-20 08:23:09 +01:00
Danny Ryan
a02aac43c2
adjust hysteresis to avoid initial over-deposit incentive
2020-02-18 12:36:20 -06:00
Danny Ryan
757f5a31dd
add proposer index and add/modify tests
2020-02-18 11:38:17 -06:00
Anton Nashatyrev
cfcb7b2f01
Measure eth1 voting period in epochs instead of slots
2020-02-18 16:12:43 +03:00
Jacek Sieka
52b45ab9de
Add fork version to topic
...
Gossipsub peers are separate from the ETH2 RPC protocol, and thus cannot
rely on the application-level `Status` negotiation to establish if
they're on the same network.
Segregating gossipsub topics by fork version decouples RPC from gossip
further and allows peers to more easily listen only to the traffic of
the network they're interested in, without further negotiation.
2020-02-17 10:03:32 +01:00
Ben Edgington
8620adcdf1
Correct the duration of HISTORICAL_ROOTS_LIMIT
...
The duration of HISTORICAL_ROOTS_LIMIT is:
SECONDS_PER_SLOT * SLOTS_PER_HISTORICAL_ROOT * HISTORICAL_ROOTS_LIMIT
which is
12s * 2^13 * 2^24 = 1.65e12s = 52,262 years
2020-02-14 14:29:45 +00:00
Danny Ryan
40b4931f01
cleanup attester slashing conditon code snippet
...
Co-Authored-By: Diederik Loerakker <proto@protolambda.com>
2020-02-13 11:17:19 -07:00
Danny Ryan
a7ef70eb9b
add DoS prevention validation conditions to voluntary_exit, proposer_slashing, and attester_slashing gossipsub channels
2020-02-12 15:56:03 -07:00
Danny Ryan
f441fadfff
pr feedback
...
Co-Authored-By: Diederik Loerakker <proto@protolambda.com>
2020-02-12 15:50:22 -07:00
Danny Ryan
f8b72f5057
add lower bound condition on block gossip
2020-02-12 12:07:57 -07:00
Danny Ryan
a9fae27379
Merge pull request #1615 from ethereum/subnet-validations
...
Add subnet validations for DoS resistance
2020-02-12 12:02:28 -07:00
Danny Ryan
714a7de8a2
reorder gossip conditions to put cheap checks before signature verifications
2020-02-12 11:59:00 -07:00
Danny Ryan
90476388fe
reverse params in get_aggregate_and_proof to match ssz type
2020-02-11 15:54:18 -07:00
Danny Ryan
bf8252aeb6
subnet validation PR feedback
2020-02-11 15:46:30 -07:00
Danny Ryan
eec57f29b7
add explicit instrucutions for construction of signed_aggregate_and_proof. add DOMAIN_SELECTION_PROOF and DOMAIN_AGGREGATE_AND_PROOF
2020-02-11 15:45:51 -07:00
Danny Ryan
8d16d428e0
fix up some p2p validation conditions based on PR feedback
2020-02-10 21:35:39 -07:00
Danny Ryan
3d111f7bdd
Merge pull request #1612 from ethereum/v-guide-per-slot-slash
...
[validator guide] beacon block is per-slot slashing
2020-02-10 19:42:01 -07:00
Danny Ryan
8a2a689c80
add clarifying note to signedaggregateandproof in vaidator guide and fix tocs
2020-02-10 19:36:08 -07:00
Danny Ryan
1ca4e3538c
prevent multiple beacon blocks from same proposer in a given slot
2020-02-10 19:28:37 -07:00
Danny Ryan
118a755bbb
create SignedAggregateAndProof to prevent DoS attacks
2020-02-10 19:18:14 -07:00
Danny Ryan
c1a51a9358
Add no repeat attestation condition for committee_index_beacon_attestation gossip channel
2020-02-10 18:53:26 -07:00
Danny Ryan
129aa02cb3
support tests with SLOTS_PER_EPOCH * 256 vals
2020-02-10 17:56:05 -07:00
Danny Ryan
d5f1402d0d
Merge pull request #1604 from status-im/fewer-head-block-roots
...
drop `head_block_root` from BeaconBlocksByRange
2020-02-08 18:24:54 -06:00
Danny Ryan
43cacc3fe9
fix validator guide to show that block slashing is per slot rather than per epoch
2020-02-08 16:58:05 -07:00
Jacek Sieka
6188f350f6
it's just a number
2020-02-07 19:03:33 +01:00
Jacek Sieka
97d931b705
rephrase fork choice requirement
2020-02-07 19:03:09 +01:00
Alex Stokes
b398e42439
another typo in pubsub channel name
2020-02-06 16:41:53 -08:00
Alex Stokes
7aeeb372a7
[validator-guide] typo fix
2020-02-06 16:03:40 -08:00
Danny Ryan
03f53e9928
Merge pull request #1607 from AgeManning/noise-specification
...
Add libp2p-noise specification
2020-02-06 12:05:49 -06:00
Age Manning
9355a6ebca
Noise libp2p specification
2020-02-05 14:33:00 +11:00
protolambda
93249aadda
Proposal to focus on length-encoding SSZ contents, enable streaming of chunk contents, and put stricter DOS limits in place
2020-02-04 13:56:32 +01:00
Jim McDonald
74c75fd6f1
Remove extraneous word
2020-02-02 22:08:11 +00:00
Jacek Sieka
c943b5832e
drop `head_block_root` from BeaconBlocksByRange
...
This change simplifies the protocol and removes a race condition between
block request and response. In the case of honest server, this helps
serve the canonical / fork-chosen chain better while dishonest or broken
servers still need to be handled the same way.
Might as well get started on versions and upgrade it to 2, since the
change is backwards incompatible.
2020-01-31 22:04:48 +01:00
terence tsao
fe58c78da8
Fix table
2020-01-29 14:08:48 -08:00
Herman Junge
51f2974678
Update validator.md
...
Minor edit
2020-01-29 13:51:38 +00:00
vbuterin
52fb929978
Update specs/core/1_beacon-chain.md
2020-01-28 17:32:57 -07:00
vbuterin
2a91b43eaf
Remove shard block chunking
...
Only store a 32 byte root for every shard block
Rationale: originally, I added shard block chunking (store 4 chunks for every shard block instead of one root) to facilitate construction of data availability roots. However, it turns out that there is an easier technique. Set the width of the data availability rectangle's rows to be 1/4 the max size of a shard block, so each block would fill multiple rows. Then, non-full blocks will generally create lots of zero rows. For example if the block bodies are `31415926535` and `897932` with a max size of 24 bytes, the rows might look like this:
```
31415926
53500000
00000000
89793200
00000000
00000000
```
Zero rows would extend rightward to complete zero rows, and when extending downward we can count the number of zero rows, and reduce the number of extra rows that we make, so we only make a new row for every nonzero row in the original data. This way we get only a close-to-optimal ~4-5x blowup in the data even if the data has zero rows in the middle.
2020-01-28 17:31:51 -07:00
protolambda
d9f62f9303
Remerkleable - merkle tree based ssz for better and faster spec
2020-01-25 00:43:43 +01:00
Danny Ryan
67a4d5e659
Merge branch 'dev' into master-copy
2020-01-24 13:49:22 -07:00
Jim McDonald
d4ae00819a
Fix for increased seconds per slot
2020-01-23 13:08:52 -07:00
protolambda
86b699bfd1
Merge branch 'dev' into phase1rebase
2020-01-23 19:24:03 +01:00
Jim McDonald
de1bb7bde1
Update for renamed constant
2020-01-23 09:55:04 -07:00
Hsiao-Wei Wang
a13271af41
Fix BLS API description
2020-01-23 09:52:40 -07:00
Ben Edgington
f8250b6a1a
Correct typo in heading level
2020-01-23 09:51:58 -07:00
Chih Cheng Liang
14cfc66c33
Fix p2p interface indentation
2020-01-23 09:51:38 -07:00
Danny Ryan
eed3f6053d
Merge pull request #1580 from ethereum/fork-choice-fix-1574
...
Fork choice fix issue 1574
2020-01-22 16:56:00 -07:00
Danny Ryan
d672c47aba
Merge pull request #1579 from ethereum/epochs-in-fork-choice
...
Properly handle skip slots in fork choice
2020-01-22 16:55:15 -07:00
Diederik Loerakker
9f5f501e5b
Merge pull request #1586 from ethereum/fix-default-compute-domain
...
fix default value in compute_domain
2020-01-23 00:29:28 +01:00
Jim McDonald
ebac603745
Update for renamed constant
2020-01-22 22:23:36 +00:00
Danny Ryan
fe103394db
Merge pull request #1583 from sigp/kirk-baird-patch-02
...
Update BLS Link
2020-01-22 14:57:36 -07:00
Danny Ryan
b357e43aab
clarifying comment on call to get_ancestor in on_block
2020-01-22 14:31:23 -07:00
Danny Ryan
e821476c07
explicitly use Optiona type for fork_version in compute_domain
...
Co-Authored-By: Carl Beekhuizen <carl@ethereum.org>
2020-01-22 11:38:50 -07:00
Danny Ryan
cf18b040b4
fix default value in compute_domain
2020-01-22 07:24:15 -07:00
Kirk Baird
601701241c
Update link
...
Signed-off-by: Kirk Baird <baird.k@outlook.com>
2020-01-22 11:04:45 +11:00
Danny Ryan
2015433fa1
revert exit queue epoch issue introduced in v0.10.0. add test to catch subtlety
2020-01-20 20:03:38 -07:00
Danny Ryan
00d3fb4fe6
fix issue 1574 by ensuring that justified checkpoint in store updates when finalized updates if needbe
2020-01-20 18:50:50 -07:00
Danny Ryan
e98c1b4154
don't consider blocks with slots earlier than finalized in on_block fork choice (optimization)
2020-01-20 18:10:39 -07:00
Danny Ryan
f1697d03e7
fix corner case to properly handle skipped slots in get_ancestor
2020-01-20 17:49:09 -07:00
Danny Ryan
7a412534d9
remove test_shard_blocks (outdated) and reduce PERSISTENT_COMMITTEE_PERIOD in minimal config
2020-01-15 18:17:07 -07:00
Danny Ryan
c0b69e531f
cycle through committee indexes instead of through active shards when forming crosslinks
2020-01-15 17:43:11 -07:00
Danny Ryan
3c07b2c954
Make phase 0 fork choice more modular to more easily adopt for slight modifications in phase 1
2020-01-15 16:40:50 -07:00
Danny Ryan
08621a7973
Merge pull request #1567 from ethereum/fix_bls_api
...
[Minor] fix BLS API description
2020-01-15 14:21:15 -07:00
Danny Ryan
1756348e8d
Merge pull request #1569 from ChihChengLiang/minor-fix-indentation
...
[Minor] Fix p2p interface table level
2020-01-15 14:19:42 -07:00
protolambda
5785b4fc5b
custody bits temporary solution
2020-01-14 01:59:01 +01:00
protolambda
f04a686db7
doctoc
2020-01-14 01:42:19 +01:00
protolambda
f6f8bd5350
no custody bits fallback
2020-01-14 01:36:16 +01:00
protolambda
6c74468142
forkchoice store on top of any state now
2020-01-14 01:02:02 +01:00
protolambda
702b253361
update configs for phase1
2020-01-13 19:50:36 +01:00
protolambda
419b6a3250
config change, need more space for worst-case reveals
2020-01-13 19:00:24 +01:00
protolambda
507a9afbfb
apply custody bit fix suggestion from Dankrad
2020-01-13 18:57:56 +01:00
protolambda
4732c7beb1
merge in dev (v0.10) and fix reorg/lint issues
2020-01-13 18:55:21 +01:00
Chih Cheng Liang
065b4ef856
Fix p2p interface indentation
2020-01-13 20:42:23 +08:00
Ben Edgington
b001f250db
Correct typo in heading level
2020-01-13 09:34:34 +00:00
Hsiao-Wei Wang
efbea8c53c
Fix BLS API description
2020-01-13 12:49:03 +08:00
Danny Ryan
676e216beb
reorg specs by fork and move ssz out to own folder. make all of the build and link changes to support move
2020-01-10 11:55:13 -07:00
Danny Ryan
5e96c08f41
add MAXIMUM_GOSSIP_CLOCK_DISPARITY for gossip subnet validations
2020-01-10 07:28:14 -07:00
Danny Ryan
e0cd1090bd
fix voluntary exit to be wrt signed voluntary exit in p2p spec
2020-01-09 17:38:43 -07:00
Danny Ryan
af702d42fd
add slot validation condition for beacon block gossip sub channel
2020-01-09 17:14:00 -07:00
protolambda
68ff136b5d
warn about broken attestation validation, fix most attester slashings tests
2020-01-10 00:00:10 +01:00
Danny Ryan
b8d4ce4c39
fix default value when voting on eth1data
2020-01-09 14:54:07 -07:00
protolambda
140129ec51
Merge dev into phase1 refactor, update BLS phase1
2020-01-09 14:56:06 +01:00
Danny Ryan
f01254dd7f
Merge branch 'dev' into JustinDrake-patch-2
2020-01-08 13:54:16 -07:00
Danny Ryan
fff354d673
Merge branch 'dev' into carl_new_new_bls
2020-01-07 15:44:30 -07:00
Carl Beekhuizen
12ea891ce5
`py_ecc` 2.0.0 baby!
2020-01-07 20:52:20 +01:00
Carl Beekhuizen
8948393e76
Remove references to BLS messages
2020-01-07 20:28:16 +01:00
Hsiao-Wei Wang
fbfe024e7a
Rename vyper file from `.v.py` to `.vy`
2020-01-07 17:20:17 +08:00
Danny Ryan
c3f7f0bc2b
Merge pull request #1556 from ethereum/constant-genesis-slot
...
move GENESIS_SLOT/EPOCH to constants
2020-01-06 17:28:06 -07:00
Danny Ryan
b637b9ad72
fix mod bug for voting period
2020-01-06 17:19:31 -07:00
Danny Ryan
9ea03dce60
add compute_time_at_slot helper in validator doc
2020-01-06 12:16:47 -07:00
Diederik Loerakker
a295451f37
Merge pull request #1555 from ethereum/att-when-ready
...
add eager attestation broadcasting
2020-01-06 01:15:13 +01:00
protolambda
68d93f945c
online countdown fixes
2020-01-06 00:46:36 +01:00
protolambda
9c07e26a4d
length assert not applicable anymore
2020-01-06 00:25:18 +01:00
protolambda
6b872da3ec
light client bitfield is vector now, small size anyway, better separation of committee complexity from data init
2020-01-06 00:17:48 +01:00
protolambda
2f3919c176
bugfix: pass block body to sub processing functions
2020-01-05 23:51:24 +01:00
protolambda
2e6090fcd8
bugfixes for experimental phase0 -> phase1 fork py code
2020-01-05 23:37:42 +01:00
Danny Ryan
50c8727ae7
make genesis delay configurable
2020-01-05 15:29:23 -07:00
Danny Ryan
8515aec7aa
move GENESIS_SLOT/EPOCH to constants as they are not truly configurable
2020-01-05 15:07:41 -07:00
Danny Ryan
5ac0d12205
Merge pull request #1553 from ethereum/eth1-caching
...
`get_eth1_data` uses timestamp instead of block height
2020-01-05 14:44:47 -07:00
Danny Ryan
43d095214c
add note that validator should broadcast attestation immediately when receiving block from expected proposer
2020-01-05 14:10:06 -07:00
protolambda
a8276f683e
don't hardcode shard count, bad example, need upgradeability
2020-01-05 20:20:20 +01:00
protolambda
018927def0
generalize previous-slot function
2020-01-05 20:11:55 +01:00
protolambda
a5faabbf19
Merge branch 'version-pyspec-module' into phase1rebase
2020-01-04 18:28:34 +01:00
Danny Ryan
6dbc02031d
add GENESIS_FORK_VERSION and make associated modifications to support configuration of this variable
2020-01-03 17:48:03 -07:00
Danny Ryan
261b6c0d23
modify get_eth1_data to use timestamp instead of block height
2020-01-03 16:57:04 -07:00
Danny Ryan
7b1a609335
Merge pull request #1549 from status-im/empty-block-response
...
Allow empty lists in streamed responses
2020-01-03 08:14:51 -07:00
Danny Ryan
c9f52d0099
Merge branch 'dev' into phase1rebase
2020-01-03 07:49:23 -07:00
Danny Ryan
0a3cc8a84a
malefactor_key -> malefactor_secret
2020-01-03 07:29:23 -07:00
Carl Beekhuizen
8580ec33f2
'message' -> 'signing_root'
2020-01-03 08:18:34 +01:00
Carl Beekhuizen
51bcb29e28
'DomainWrapper' -> 'SigningRoot'
2020-01-03 07:46:27 +01:00
Carl Beekhuizen
a65d96da04
Merge in dev
2020-01-03 07:35:19 +01:00
Danny Ryan
defeb4e2fd
Merge pull request #1550 from terencechain/patch-94
...
`get_filtered_block_tree` typo
2019-12-31 12:39:52 -07:00
Carl Beekhuizen
e70863ca93
Bytes4 -> DomainType
2019-12-30 06:52:00 +01:00
Carl Beekhuizen
765176ec8c
PySpec SSZ Bytes instantiated from hex
2019-12-27 09:37:26 +01:00
terence tsao
662a986d04
Update 0_fork-choice.md
2019-12-25 09:51:29 -08:00
Jacek Sieka
850d45dae0
Allow empty lists in streamed responses
...
It's possible that block request responses end up not containing any
blocks, so we need a way to encode this.
2019-12-21 17:26:14 +01:00
Diederik Loerakker
b698eff2a7
Merge pull request #1546 from ethereum/master
...
Backport v0.9.4 to dev
2019-12-20 21:25:50 +01:00
Carl Beekhuizen
7af4429011
Make bls a module
2019-12-20 08:41:46 +02:00
Carl Beekhuizen
1e410a1290
Fix typo due to change of interface
...
Co-Authored-By: Danny Ryan <dannyjryan@gmail.com>
2019-12-20 08:12:43 +02:00
Danny Ryan
780dff76d4
Merge pull request #1540 from ChihChengLiang/note-on-requesting-status-again
...
Add a note on requesting STATUS again
2019-12-19 14:10:54 -07:00
Danny Ryan
e34d22e4f8
bad -> abnormal
2019-12-19 14:04:45 -07:00
Carl Beekhuizen
62cbd0e7da
Revert domain 6 -> 5 to prevent confusion
2019-12-19 15:49:10 +02:00
Carl Beekhuizen
42a3dd4ab1
Implement @djrtwo's review suggestions
2019-12-19 15:47:42 +02:00
Chih Cheng Liang
c4b23590d4
Add a note on requesting STATUS again
2019-12-19 18:50:49 +08:00
Danny Ryan
31d90ea799
add p2p faq on why message-id override
2019-12-18 14:46:35 -07:00
Age Manning
8a03e6d291
Add gossipsub message-id specification
2019-12-18 14:20:51 -07:00
Danny Ryan
caffe8d720
update ENR to use attesation subnets instead of shards
2019-12-17 16:27:13 -07:00
Danny Ryan
fa916323f0
add basics for ENR bitfield
2019-12-17 10:59:15 -07:00
Carl Beekhuizen
177ec939f0
Update ToC
2019-12-17 15:40:26 +02:00
Carl Beekhuizen
995c895b9c
New BLS in Phase 1
2019-12-17 15:33:37 +02:00
Carl Beekhuizen
c239ffb78c
Linting fixes
2019-12-17 12:30:46 +02:00
Carl Beekhuizen
80eb721895
Domains are bytes
2019-12-17 12:20:34 +02:00
Carl Beekhuizen
502ee29537
Phase 0 new BLS
2019-12-17 12:04:56 +02:00
Martin Lundfall
a4f8a77c02
Fix spelling errors found by codespell
2019-12-16 13:02:36 +01:00
Justin
412a06608c
Update 0_beacon-chain.md
2019-12-15 11:32:11 +00:00
Justin
48317d8ac0
Minor cosmetic cleanups
...
* remove `BLS_WITHDRAWAL_PREFIX` (it is not used in phase 1, not phase 0)
* avoid inline comment (# Validate state root)
* simplify header inequality check in `process_proposer_slashing` (using uniqueness of BLS signatures)
* add `block = signed_block.message` helper variable for readability
* (typo) clarify that the state transition function consumes a signed block (as opposed to a block)
* generally make comments more consistent
* consistent formatting of container instantiation for `DepositMessage`
* avoid using three lines for `rewards[index] += Gwei(max_attester_reward // attestation.inclusion_delay)`
* introduce `effective_balance` helper variable for readability, and to avoid multi-line statement
* consistent ordering of `MIN_EPOCHS_TO_INACTIVITY_PENALTY` in the time parameters table
* (typo) "Dequeued validators for activation up to churn limit" => Dequeue validators
* "Save current block as the new latest block" => "Cache current block" (for consistent with `process_slot`)
* (typo) "Verify the validator has not yet exited" => "Verify exit has not been initiated"
* Use Pythonic `default=` for `max()` call in `initiate_validator_exit`
2019-12-15 11:10:43 +00:00
Diederik Loerakker
88e954a9c7
Merge pull request #1522 from ethereum/master
...
backport v093 to dev
2019-12-13 18:56:31 +01:00
Danny Ryan
b09c45ffd2
remove last two references to signing root
2019-12-12 12:34:02 -07:00
Danny Ryan
47ecedb81d
update tocs
2019-12-12 09:48:53 -07:00
Danny Ryan
49a8264f5d
Merge branch 'v09x' into toc_ci
2019-12-12 09:47:20 -07:00
Danny Ryan
4a31503ec0
Merge pull request #1516 from ethereum/dup-indices-attest
...
Fixes #1486 : disallow duplicate indices in indexed attestation
2019-12-12 08:32:43 -07:00
Danny Ryan
52a6cf7ba3
Merge pull request #1514 from ethereum/queue-fix-on-finality
...
Fix queue rate and only activate upon finality
2019-12-12 07:44:57 -07:00
Danny Ryan
199933cb26
fix tocs
2019-12-12 06:57:11 -07:00
Danny Ryan
86fb3acd59
minor changes to finality in activation queue
2019-12-12 06:53:56 -07:00
Danny Ryan
19ec01e4e9
add comment about activation queue sort order
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-12 06:43:37 -07:00
ethers
3d48a3e9eb
Fix dead link to use Internet Archive
2019-12-11 18:17:20 -08:00
protolambda
2405060a7e
Fixes #1486 : disallow duplicate indices in indexed attestation
2019-12-12 01:45:59 +01:00
Danny Ryan
e117b58ae2
add queue eligibility helper
2019-12-11 16:10:18 -07:00
Danny Ryan
6610aeea2f
fix activation queue to finality
2019-12-11 16:00:46 -07:00
Danny Ryan
40025c96dd
Merge pull request #1509 from ethereum/match-slot-target
...
ensure that epoch of attestation slot matches the target epoch
2019-12-10 13:42:32 -07:00
Danny Ryan
66652d0ebd
Merge pull request #1508 from ethereum/better-best
...
ensure the best better-justification is stored in fork choice
2019-12-10 13:41:45 -07:00
Danny Ryan
4636b3e824
Merge pull request #1510 from ethereum/genesis-slot-time
...
explicit use of GENESIS_SLOT in fork choice
2019-12-10 13:41:13 -07:00
Danny Ryan
e4d710590a
add test for queue efficiency
2019-12-10 11:49:26 -07:00
Danny Ryan
d126162ca8
fix activation queue efficiency
2019-12-10 11:25:55 -07:00
Martin Lundfall
ca2b6a0e52
Use consistent header level for TOC generation
2019-12-10 18:29:50 +01:00
Martin Lundfall
12ff64ea1a
Update ToC of specs to consistent use of doctoc
2019-12-10 18:29:40 +01:00
Danny Ryan
2c5c9cb71a
feedback from mikhail
2019-12-10 10:14:49 -07:00
Danny Ryan
8861ca0282
minor typo
...
Co-Authored-By: MrChico <martin.lundfall@protonmail.com>
2019-12-10 10:05:19 -07:00
Danny Ryan
9989f3ea9d
ensure fork choice functions when GENESIS_SLOT != 0
2019-12-09 19:02:16 -07:00
Danny Ryan
432257659e
add asserts to ensure that attestation slot must match the target epoch
2019-12-09 17:31:43 -07:00
Danny Ryan
d4d17ecc4e
ensure the best better-justification is stored in fork choice
2019-12-09 16:47:43 -07:00
Danny Ryan
57aeed1473
Merge branch 'v09x' into filter-fc-justified
2019-12-08 12:17:28 -07:00
Danny Ryan
e53a6daecc
clarify fliter block tree through two line usage
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-08 11:53:45 -07:00
Danny Ryan
ce40666003
version pyspec module and test on one attesterslashing test
2019-12-05 15:06:32 -07:00
Diederik Loerakker
da17f4b3a8
Merge pull request #1505 from ethereum/v09x
...
backport V09x
2019-12-05 22:15:47 +01:00
Danny Ryan
e31f17f037
modify phase 1 to use new signature (no signing_root) pattern
2019-12-05 13:49:52 -07:00
Danny Ryan
a32b0100ff
rebase fixes
2019-12-05 13:31:42 -07:00
Danny Ryan
4bf5eb86c4
fix issues using indexed attestation and custody bit wrapper
2019-12-05 13:31:42 -07:00
Danny Ryan
f533fef167
add missing attestation validations; cleanup process_attestations and fix minor bugs
2019-12-05 13:31:41 -07:00
Danny Ryan
a1ac0d5a80
fix get_shard_committee
2019-12-05 13:31:41 -07:00
Danny Ryan
ddd7cd2964
divide new and old containers out in phase 1
2019-12-05 13:31:41 -07:00
protolambda
72a9dfc430
fix lint problems
2019-12-05 13:31:41 -07:00
protolambda
1623d40b6d
fix: check malefactor custody key
2019-12-05 13:31:41 -07:00
protolambda
41be2ed3ce
bugfix custody bit index lookup + lint fixes
2019-12-05 13:31:40 -07:00
protolambda
1a1c3773f9
implement custody game revamp for new shard proposal: simplifications and immediate processing, since custody data is bounded
2019-12-05 13:31:40 -07:00
protolambda
e73316c13f
change configs to be loaded in time; reload specs module to make new config presets effective. Also fix more lint and consistency problems.
2019-12-05 13:30:49 -07:00
Danny Ryan
d6bfe5d35c
lint phase 1 (2)
2019-12-05 13:29:52 -07:00
Danny Ryan
9f80a7f703
phase1 lint (1)
2019-12-05 13:29:51 -07:00
Danny Ryan
82c9adce8b
fix phase 1 make build (not lint or tests)
2019-12-05 13:29:51 -07:00
Danny Ryan
79be0345d6
fix call to process_attestation
2019-12-05 13:29:51 -07:00
protolambda
03e956f9c9
validator init adjustments
2019-12-05 13:29:51 -07:00
protolambda
36503f98e4
placeholder: rudimentary phase 0 to phase 1 fork process
2019-12-05 13:29:51 -07:00
protolambda
cc0aac3aae
typo
2019-12-05 13:29:50 -07:00
protolambda
74d6021507
PR comment fixes
2019-12-05 13:29:50 -07:00
protolambda
589d5a4f9a
Add notes on custody game spec funcs
2019-12-05 13:29:50 -07:00
protolambda
465f6cb7f0
update readme spec links
2019-12-05 13:29:50 -07:00
protolambda
edef2fd8ae
more refactoring: more immediate custody game, general phase1 beacon chain changes
2019-12-05 13:29:50 -07:00
protolambda
7d2341b40d
Note: is_valid_indexed_attestation is overriden
2019-12-05 13:29:49 -07:00
protolambda
a33e01dab2
Start making phase1 work in pyspec again
2019-12-05 13:29:49 -07:00
Vitalik Buterin
ef936b94fe
Added get_shard_proposer_index
2019-12-05 13:29:49 -07:00
Vitalik Buterin
4d6dcd15ba
Some fixes
2019-12-05 13:29:49 -07:00
Vitalik Buterin
7b4a6e8307
Simplified gasprice update
2019-12-05 13:29:49 -07:00
Vitalik Buterin
8f34a0788d
Some initial changes
2019-12-05 13:29:49 -07:00
vbuterin
b6680d28bb
Update specs/core/1_new_shards.md
...
Co-Authored-By: Danny Ryan <dannyjryan@gmail.com>
2019-12-05 13:29:48 -07:00
vbuterin
e66b4e06ef
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:48 -07:00
vbuterin
8cb404d926
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:48 -07:00
vbuterin
ff3bd725a3
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:48 -07:00
vbuterin
2ea8eb9cc3
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:48 -07:00
vbuterin
c9cc110ab1
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:47 -07:00
vbuterin
a749dd9a77
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:47 -07:00
vbuterin
822ceade58
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:47 -07:00
vbuterin
0ddc0ba527
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:47 -07:00
vbuterin
bf13757722
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:47 -07:00
vbuterin
793c8616cd
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:47 -07:00
vbuterin
41be60ee6e
Update specs/core/1_new_shards.md
2019-12-05 13:29:46 -07:00
vbuterin
8a6bd201f9
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:46 -07:00
vbuterin
4d1e9e15c6
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:46 -07:00
vbuterin
9810a3d260
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:46 -07:00
vbuterin
9d3a230974
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:46 -07:00
vbuterin
bcd06d88ef
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:46 -07:00
vbuterin
d59e87f876
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:45 -07:00
vbuterin
d3f9bfe68d
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:45 -07:00
vbuterin
213032e51f
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:45 -07:00
vbuterin
462d05d6d8
Update specs/core/1_new_shards.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-12-05 13:29:45 -07:00
Hsiao-Wei Wang
1fdd0332cc
Update ToC
2019-12-05 13:29:45 -07:00
Vitalik Buterin
03ab1d5785
A few cleanups
2019-12-05 13:29:45 -07:00
Vitalik Buterin
d723431616
Fixed pending attestation handling and added empty transition check
2019-12-05 13:29:44 -07:00
Vitalik Buterin
393436992d
Restructured shard blocks
2019-12-05 13:29:44 -07:00
Vitalik Buterin
6b1bc1e02f
Reformed attestations
2019-12-05 13:29:44 -07:00
Vitalik Buterin
b36820a26c
Changes to make Danny happy
2019-12-05 13:29:44 -07:00
Vitalik Buterin
bf886d698b
Small edits
2019-12-05 13:29:44 -07:00
Vitalik Buterin
bf0a2b7df9
Renaming
2019-12-05 13:29:43 -07:00
Vitalik Buterin
08fc024fbd
Changed fraud proof details
2019-12-05 13:29:43 -07:00
Hsiao-Wei Wang
0ff5985c01
Fix markdown and ToC
2019-12-05 13:29:43 -07:00
Vitalik Buterin
539c681921
Updates to add new proposals
2019-12-05 13:29:43 -07:00
Vitalik Buterin
bb2835ee1b
Shard slots to 128 bytes
2019-12-05 13:29:43 -07:00
Vitalik Buterin
7fc2830730
Some updates
2019-12-05 13:29:43 -07:00
Vitalik Buterin
e5544d055b
Made trace a commitment separate from state roots
2019-12-05 13:29:42 -07:00
Vitalik Buterin
9abfc6276a
Cleaned up state transition and honest committee member
2019-12-05 13:29:42 -07:00
Vitalik Buterin
b792fe696a
formatting
2019-12-05 13:29:42 -07:00
Vitalik Buterin
fe60b4deba
Variable max attestation length
2019-12-05 13:29:42 -07:00
Vitalik Buterin
26df98bf61
MAX_CATCHUP -> MAX_CATCHUP_RATIO
2019-12-05 13:29:42 -07:00
Vitalik Buterin
25db268bfb
Added a few more things
2019-12-05 13:29:42 -07:00
Vitalik Buterin
f6be6b2b8a
Added a few things
2019-12-05 13:29:41 -07:00
Vitalik Buterin
88aeba09f6
Added new shards
2019-12-05 13:29:41 -07:00
Danny Ryan
b4b5cc9115
Merge branch 'v09x' into dev
2019-12-05 13:29:04 -07:00
Danny Ryan
7af6945f53
Merge pull request #1491 from ethereum/rm-signing-root
...
rm signing root (fixes #1487 )
2019-12-05 13:16:39 -07:00
Danny Ryan
dfcd6f6402
add tests for block filter in get_head
2019-12-04 16:53:55 -07:00
Danny Ryan
e9dc2a1f03
Merge pull request #1492 from terencechain/patch-91
...
Remove duplicated attestation target root check
2019-12-04 11:49:08 -07:00
protolambda
afb9a1d7c0
move signed envelopes
2019-12-03 21:34:48 +01:00
protolambda
103a66b2af
remove signing_root: see issue #1487
2019-12-03 21:10:19 +01:00
terence tsao
0f4faf11ab
Update 0_fork-choice.md
2019-12-03 17:25:56 +08:00
terence tsao
1113953a59
Update p2p-interface.md
2019-12-03 17:17:17 +08:00
Danny Ryan
2275cdfeb8
fix child filter in get_head
2019-11-27 13:26:44 -07:00
Danny Ryan
5aa9f96558
Update specs/core/0_fork-choice.md
...
Co-Authored-By: Diederik Loerakker <proto@protolambda.com>
2019-11-27 13:11:30 -07:00
Danny Ryan
8021f34c06
fix existing fork choce tests with new filter
2019-11-25 15:44:22 -07:00
Danny Ryan
9004bcf1a5
WIP filter block tree
2019-11-25 15:06:33 -07:00
Danny Ryan
23abc11093
handle v0.9.2-dev conflict
2019-11-21 15:18:17 -07:00
Danny Ryan
3e96b43894
Merge pull request #1467 from ethereum/reduce-genesis-count
...
reduce genesis validator count for mainnet config
2019-11-18 13:30:04 -07:00
Danny Ryan
6ef79ac2a8
Merge pull request #1480 from ethereum/ssz-bytes-naming
...
Rename BytesN to ByteVector, rename Bytes to ByteList
2019-11-18 13:28:32 -07:00
Hsiao-Wei Wang
8fed220736
Update `AggregateAndProof` and rename `slot_signature` to `get_slot_signature`
...
1. Reorder the fields to fit the container name
2. Rename `AggregateAndProof.index: ValidatorIndex` to `AggregateAndProof.aggregator_index: ValidatorIndex`
- Since we also have similar naming style like
`ProposerSlashing.proposer_index` or `VoluntaryExit.validator_index`
2019-11-18 21:35:12 +08:00
Diederik Loerakker
b15669b7a5
Backport master (v0.9.1) to dev ( #1482 )
...
* p2p-interface: clarify that signing_root is used for block requests
* hash cleanups
* one more hash tree root gone for blocks - block hashes are always
signing roots!
* use simple serialize data types consistently
* Describe which finalized root/epoch to use
* remove custody_bits from attestation
* remove AttestationDataAndCustodyBit
* Specify inclusive range for genesis deposits
* add initial fork choice bounce prevention and tests
* PR feedback
* further test bounce attack
* wipe queued justified after epoch transition
* remove extra var
* minor fmt
* only allow attestatiosn to be considered from current and previous epoch
* use best_justified_checkpoint instead of queued_justified_checkpoints
* use helper for slots since epoch start
* be explicit about use of genesis epoch for previous epoch in fork choice on_block
* pr feedback
* add note aboutgenesis attestations
* cleanup get_eth1_vote
* make eth1_follow_distance clearer
* Update the expected proposer period
Since `SECONDS_PER_SLOT` is now `12`
* minor fix to comment in mainnet config
* Update 0_beacon-chain.md
2019-11-15 16:27:04 -05:00
protolambda
2c32274870
rename BytesN to ByteVector, rename Bytes to ByteList
2019-11-15 16:56:52 +01:00
Danny Ryan
89fa914e73
Merge pull request #1478 from ethereum/hash-type-fix
...
Avoid Hash <> hash() type and func confusion
2019-11-12 16:41:21 -07:00
Danny Ryan
1aad31df59
Merge pull request #1477 from ethereum/forkchoice-future-blocks
...
Forkchoice mods
2019-11-12 16:40:32 -07:00
Danny Ryan
117fb12888
add scheduling note to on_attestation
2019-11-12 16:24:33 -07:00
protolambda
c061abdd75
Avoid Hash <> hash() type and func confusion, intro Root and change to non-roots to Bytes32
2019-11-12 21:29:58 +01:00
Danny Ryan
e3a67fe52c
ensure not all validators switch at once
2019-11-12 12:00:30 -07:00
Danny Ryan
74253bdbaf
attestations for future blocks not valid in fork choice
2019-11-12 11:29:46 -07:00
Danny Ryan
29b073bcca
add random subnet subscriptions for phase 0 stability
2019-11-11 14:46:30 -07:00
Danny Ryan
32e6623915
clarify topic subscriptions for attestations
2019-11-11 14:27:46 -07:00
terence tsao
931ad45c53
Update 0_beacon-chain.md
2019-11-08 11:45:11 -07:00
Hsiao-Wei Wang
a029db3410
Update the expected proposer period
...
Since `SECONDS_PER_SLOT` is now `12`
2019-11-08 19:05:14 +08:00
Diederik Loerakker
f0999573f7
Merge pull request #1469 from ethereum/fix-eth1-distance
...
Clarify `previous_eth1_distance`
2019-11-07 20:37:36 +01:00
Danny Ryan
c84dce7b32
make eth1_follow_distance clearer
2019-11-07 12:32:02 -07:00
Danny Ryan
5159c69632
cleanup get_eth1_vote
2019-11-07 12:15:56 -07:00
Danny Ryan
e7f71886b0
Merge pull request #1466 from ethereum/decoy-flip-flop
...
Decoy flip flop resistance
2019-11-08 03:10:41 +08:00
Danny Ryan
9b21c0db93
add note aboutgenesis attestations
2019-11-07 12:06:23 -07:00
Danny Ryan
f331b55b9e
Merge pull request #1465 from ethereum/bounce-attack
...
Bounce attack resistance
2019-11-08 02:56:46 +08:00
Danny Ryan
bf78a71152
pr feedback
2019-11-07 11:51:53 -07:00
Danny Ryan
9ddae15e2e
reduce genesis validator count for mainnet config
2019-11-06 20:32:25 -07:00
Danny Ryan
a28c027943
be explicit about use of genesis epoch for previous epoch in fork choice on_block
2019-11-06 17:26:06 -07:00
Danny Ryan
e1d2823810
Merge branch 'bounce-attack' into decoy-flip-flop
2019-11-06 17:20:59 -07:00
Danny Ryan
09fd49ce89
use helper for slots since epoch start
2019-11-06 17:20:21 -07:00
Danny Ryan
fc40bff2a8
use best_justified_checkpoint instead of queued_justified_checkpoints
2019-11-06 17:10:32 -07:00
Danny Ryan
4f42f63e4e
only allow attestatiosn to be considered from current and previous epoch
2019-11-05 13:01:58 -07:00
Danny Ryan
2616210637
minor fmt
2019-11-05 12:51:47 -07:00
Danny Ryan
ba6637b4d9
remove extra var
2019-11-05 11:42:40 -07:00
Danny Ryan
79911a93b4
Merge pull request #1462 from ethereum/remove-custody
...
Remove custody_bits and AttestationDataAndCustodyBit
2019-11-06 02:03:50 +08:00
Danny Ryan
e20e11e0b5
wipe queued justified after epoch transition
2019-11-05 11:02:58 -07:00
Danny Ryan
97d7cf5190
further test bounce attack
2019-11-05 10:58:45 -07:00
Danny Ryan
40a21dc3ad
PR feedback
2019-11-05 09:08:37 -07:00
Danny Ryan
405e218598
add initial fork choice bounce prevention and tests
2019-11-05 08:55:34 -07:00
Paul Hauner
1c99ab2c96
Specify inclusive range for genesis deposits
2019-11-04 10:55:14 +11:00
Danny Ryan
600265a311
remove AttestationDataAndCustodyBit
2019-11-01 21:12:32 -06:00
Danny Ryan
65b615a4d4
remove custody_bits from attestation
2019-11-01 21:02:53 -06:00
Jacek Sieka
af5238ad9a
Describe which finalized root/epoch to use
2019-11-01 08:42:10 +01:00
terence tsao
2159df2d12
Update 0_beacon-chain.md
2019-10-31 21:31:08 -07:00
Jacek Sieka
1dc09e8567
hash cleanups
...
* one more hash tree root gone for blocks - block hashes are always
signing roots!
* use simple serialize data types consistently
2019-10-31 17:32:08 +01:00
Nathaniel Jensen
5dd0015912
Update link to current bls standard draft.
2019-10-30 10:29:42 +11:00
Jacek Sieka
351dcd4bb8
p2p-interface: clarify that signing_root is used for block requests
2019-10-29 08:49:03 +01:00
Danny Ryan
60a469b9c7
Merge pull request #1440 from ethereum/naive-aggregation
...
Naive aggregation strategy
2019-10-28 17:42:13 +08:00
Danny Ryan
09de5957d2
Merge pull request #1454 from ethereum/forkchoice-tests-fixed
...
Forkchoice tests fixed
2019-10-28 17:21:15 +08:00
Danny Ryan
04c20aeb28
add expicit ranges for valid attesation propogation range
2019-10-28 18:19:17 +09:00
Danny Ryan
3bb6aec3ab
Clarify committee_index subnets by defining and using "subnet" var
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-10-28 17:10:48 +08:00
Danny Ryan
43132a3082
[reopen] Eth2 shorthand standardized ( #1452 )
...
* Update README.md
* Update README.md
* Update p2p-interface.md
* Update simple-serialize.md
* Update README.md
* Update initialization.md
* Update README.md
* Update 0_beacon-chain-validator.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
2019-10-28 15:53:10 +08:00
terence tsao
34ba645f7e
Update specs/core/0_fork-choice.md
...
Co-Authored-By: Danny Ryan <dannyjryan@gmail.com>
2019-10-28 08:48:22 +01:00
terence tsao
bb5a721707
Update 0_fork-choice.md
2019-10-28 08:48:15 +01:00
Diederik Loerakker
a6cecaf212
Merge pull request #1401 from ethereum/conversion-comments
...
add explicit comments for int_to_bytes and bytes_to_int
2019-10-28 08:33:34 +01:00
Diederik Loerakker
257fcd9c79
typo
2019-10-28 08:29:01 +01:00
Danny Ryan
913a231a16
Merge pull request #1410 from wemeetagain/patch-3
...
sync protocol: clarify committee type
2019-10-28 15:26:31 +08:00
Danny Ryan
6fc1feaa2a
rearrange some of the gossip info in response to hwwhww review
2019-10-28 16:15:26 +09:00
Danny Ryan
e8fc84eadc
Update specs/networking/p2p-interface.md
...
Co-Authored-By: Hsiao-Wei Wang <hwwang156@gmail.com>
2019-10-28 15:00:55 +08:00
Danny Ryan
795105a1f4
Merge branch 'dev' into naive-aggregation
2019-10-28 15:58:49 +09:00
Danny Ryan
6570340e04
Merge branch 'master' into master-to-dev
2019-10-28 15:27:41 +09:00
Danny Ryan
c547c5291d
Merge pull request #1447 from ethereum/early-committee-bias
...
Implement solution for #1446 , based on suggested use of eth1 hash
2019-10-28 14:10:50 +08:00
Danny Ryan
810266fbf4
Merge pull request #1443 from ethereum/remove-transfers
...
Remove transfers from phase 0
2019-10-28 14:10:26 +08:00
Danny Ryan
364781b934
Merge pull request #1428 from ethereum/phase0-simplify
...
Remove Shards/Crosslinks from Phase 0
2019-10-28 14:07:39 +08:00
Hsiao-Wei Wang
2d59ca6d57
Update ToC
2019-10-28 12:43:29 +08:00
Justin
09339f2f17
Update 0_beacon-chain.md
2019-10-27 18:18:48 +00:00