69 Commits

Author SHA1 Message Date
Aditya Asgaonkar
a0b5a809d5 Apply HWW code's review - fix is_before_attesting_interval 2021-11-23 07:02:04 -08:00
Aditya Asgaonkar
1d835c5198 Apply Danny's code review & suggestions 2021-11-22 14:44:52 -08:00
Danny Ryan
cebe6ba7e7
minor formatting cleanups 2021-11-22 11:31:17 -07:00
Aditya Asgaonkar
88c76abd7f
Apply Danny's code review 2021-11-22 11:12:25 -07:00
Aditya Asgaonkar
859bbf4358
This reverts commit 4c726cdff39a10c5d096b294fb562cfc99c1f068. 2021-11-22 11:12:24 -07:00
Aditya Asgaonkar
3b20e3ea02
Apply suggestions from code review
Co-authored-by: Danny Ryan <dannyjryan@gmail.com>
2021-11-22 11:12:24 -07:00
Aditya Asgaonkar
2d161b4244
Add proposer score boosting & related tests 2021-11-22 11:12:24 -07:00
Danny Ryan
97e6d5c6d6
Merge branch 'fc-dev-validate_target_epoch_scope-patch' into dev 2021-11-22 08:32:32 -07:00
Danny Ryan
dc14b79a52
Merge pull request #2720 from paulhauner/patch-34
Remove `difficulty` from `PowBlock`
2021-11-18 15:49:27 -07:00
Mikhail Kalinin
58968f9286 Rename coinbase to fee_recipient 2021-11-18 19:23:52 +06:00
Danny Ryan
3d4ece44df
port phase0 forkchocie changes to merge 2021-11-17 18:37:45 -07:00
Paul Hauner
16aaf74cfc
Remove difficulty from PowBlock 2021-11-16 10:28:04 +11:00
Danny Ryan
116017d4cb
Merge pull request #2710 from terencechain/patch-129
`validate_merge_block ` uses correct block hash
2021-11-04 11:24:46 -06:00
terence tsao
0ae9a10123
Proper return after second assertion 2021-11-04 06:59:13 -07:00
Mikhail Kalinin
a3380db597 Fix toc 2021-11-04 16:30:23 +06:00
Mikhail Kalinin
0ad344bf72 Make notify_forkchoice_updated return payload id value 2021-11-04 15:58:48 +06:00
terence tsao
c144844279
Lint fails, it should be assert? 2021-11-03 20:31:31 -07:00
terence tsao
c9d7b8533c
Use correct payload block hash 2021-11-03 20:13:18 -07:00
Mikhail Kalinin
948d476fd1 Polish TBH handling functionality 2021-11-02 20:20:40 +06:00
Hsiao-Wei Wang
8ecbffa821
Minor comment fix 2021-10-28 16:06:58 +08:00
Hsiao-Wei Wang
60163475d7
PR feedback from @mkalinin 2021-10-28 16:00:01 +08:00
Hsiao-Wei Wang
71d315950f
Fix typo
Co-authored-by: Mikhail Kalinin <noblesse.knight@gmail.com>
2021-10-26 21:38:22 +08:00
Hsiao-Wei Wang
5b9652bf93
Merge branch 'dev' into get_pow_block-not-found 2021-10-26 21:37:08 +08:00
Danny Ryan
e787da3954
Apply suggestions from code review
Co-authored-by: Hsiao-Wei Wang <hsiaowei.eth@gmail.com>
2021-10-19 14:35:30 -06:00
Danny Ryan
4bf88ba89e
Merge pull request #2683 from ethereum/remove-prepare-payload
remove prepare_payload
2021-10-19 09:41:44 -06:00
Danny Ryan
def46dd16c
Merge pull request #2682 from ethereum/TBH-epoch
add TBH_ACTIVATION_EPOCH
2021-10-19 09:36:33 -06:00
Danny Ryan
294b60a48b
pr feedback 2021-10-19 09:24:07 -06:00
Hsiao-Wei Wang
ba582b3e3a
Fix setup.py parser and rename TBH_ACTIVATION_EPOCH -> TERMINAL_BLOCK_HASH_ACTIVATION_EPOCH 2021-10-19 11:26:53 +08:00
Danny Ryan
d5be6b5d68
remove prepare_payload in favor of a unification with notify_forkchoice_updated 2021-10-18 18:12:11 -06:00
Danny Ryan
3bfdc917e1
ad TBH_ACTIVATION_EPOCH 2021-10-18 13:38:08 -06:00
Danny Ryan
190ef9fb50
call notify_forkchoice_updated with finalized_block_hash == 0x00..00 if not yet finalized 2021-10-18 12:07:33 -06:00
Hsiao-Wei Wang
cd5cf60deb
Clarify get_pow_block block-not-found case 2021-10-18 14:05:40 +08:00
Danny Ryan
757ad7851a
Merge branch 'dev' into terminal_blockhash_override_2 2021-09-27 11:24:48 -06:00
Danny Ryan
d34b79f4de
Merge pull request #2630 from ethereum/tests/merge-clean-up
#2598 + cleanups
2021-09-27 11:23:30 -06:00
Danny Ryan
08ea4348c5
Merge branch 'dev' into terminal_blockhash_override_2 2021-09-27 11:01:10 -06:00
Mikhail Kalinin
11840ce51f Map EE calls on the PoS events defined in EIP-3675 2021-09-24 16:31:09 +06:00
Dmitrii Shmatko
b1aa227983 Added on_merge_block client tests 2021-09-23 22:22:34 +03:00
Mikhail Kalinin
7ef938da77 Add notify_ prefix to EE functions sending notifications 2021-09-23 13:37:52 +06:00
lsankar4033
df6a834889 Add TERMINAL_BLOCK_HASH override 2021-09-22 11:18:41 -07:00
Mikhail Kalinin
06107ce7d8 Polish the description of execution engine functions 2021-09-22 18:29:58 +06:00
Mikhail Kalinin
18bfe3555f
Apply suggestions from code review
Co-authored-by: Danny Ryan <dannyjryan@gmail.com>
2021-09-22 17:45:26 +06:00
Mikhail Kalinin
b530e01761 Update calls to execution_engine 2021-09-20 20:57:45 +06:00
Mikhail Kalinin
d0889b9001 Hardcode terminal total difficulty 2021-09-17 16:20:25 +06:00
Mikhail Kalinin
960a49afc9 Verify terminal PoW block after call to state_transition 2021-09-10 16:07:26 +06:00
Mikhail Kalinin
5a84224d1a Change transition_td to terminal_td in the merge spec 2021-08-30 18:23:25 +06:00
ericsson
96c05adcf8 Fix typing problem: is_merge_block accepts BeaconBlockBody as a second argument, while BeaconBlock is provided 2021-08-23 18:52:09 +03:00
Danny Ryan
4c1156d504
rename eth1 and eth2 throughout specs and readme where reasonable 2021-08-18 17:13:24 -06:00
Mikhail Kalinin
a4a050e97a Enforce terminal PoW block to be on the cusp 2021-07-16 19:16:32 +06:00
Justin
878b15df6a
polish merge/beacon-chain.md (#2472)
Polish `merge/beacon-chain.md` with mostly non-substantive changes.

**Non-substantive changes**

* rename `MAX_EXECUTION_TRANSACTIONS` to `MAX_TRANSACTIONS_PER_PAYLOAD`
	- rename "execution transaction" to just "transaction" as per discussion with Danny
* rename `compute_time_at_slot` to `compute_timestamp_at_slot`
	- the function returns a Unix timestamp
	- "timestamp" matches `execution_payload.timestamp`
* be explicit about `ExecutionEngine.execution_state` for clarity
* rename `ExecutionPayload.number` to `ExecutionPayload.block_number`
	- more specific ("number" is pretty vague)
	- consistent with `ExecutionPayload.block_hash`
* rename `new_block` to `on_payload`
	- the `on_` prefix is consistent with other event handlers (e.g. see `on_tick`, `on_block`, `on_attestation` [here](https://github.com/ethereum/eth2.0-specs/blob/dev/specs/phase0/fork-choice.md#handlers))
	- the `_payload` suffix is more to the point given the function accepts an `execution_payload`
	- avoids conflict with `on_block` which is already used in the fork choice
* rework the table of contents for consistency
* order `is_execution_enabled` after `is_transition_completed` and `is_transition_block`
	- `is_execution_enabled` refers to `is_transition_completed` and `is_transition_block`
* rename "transition" to "merge"
	- "transition" is a bit vague—we will have other transitions at future hard forks
	- there is no need for two words to refer to the same concept
* add a bunch of inline comments, e.g. in `process_execution_payload`
* make the `process_execution_payload` signature consistent with the other `process_` functions in `process_block` which take as arguments `state` and `block.body`
* remove `TRANSITION_TOTAL_DIFFICULTY`
	- to be put in `merge/fork-choice.md` where it is used 
* various misc cleanups

**Substantive changes**

* reorder `ExecutionPayload` fields
	- for consistency with yellow paper and Eth1
	- same for `ExecutionPayloadHeader`
	- added comments separating out the execution block header fields from the extra fields (cosmetic)
2021-06-18 11:09:30 +01:00
Mikhail Kalinin
6350e27366 Add difficulty field to PowBlock 2021-06-08 17:56:07 +06:00