mirror of
https://github.com/status-im/eth2.0-specs.git
synced 2025-01-22 16:39:30 +00:00
Set execution params to presets and add builder checks.
This commit is contained in:
parent
77fe450f21
commit
3ba3915396
5
setup.py
5
setup.py
@ -634,6 +634,10 @@ def objects_to_spec(preset_name: str,
|
|||||||
ssz_dep_constants = '\n'.join(map(lambda x: '%s = %s' % (x, builder.hardcoded_ssz_dep_constants()[x]), builder.hardcoded_ssz_dep_constants()))
|
ssz_dep_constants = '\n'.join(map(lambda x: '%s = %s' % (x, builder.hardcoded_ssz_dep_constants()[x]), builder.hardcoded_ssz_dep_constants()))
|
||||||
ssz_dep_constants_verification = '\n'.join(map(lambda x: 'assert %s == %s' % (x, spec_object.ssz_dep_constants[x]), builder.hardcoded_ssz_dep_constants()))
|
ssz_dep_constants_verification = '\n'.join(map(lambda x: 'assert %s == %s' % (x, spec_object.ssz_dep_constants[x]), builder.hardcoded_ssz_dep_constants()))
|
||||||
custom_type_dep_constants = '\n'.join(map(lambda x: '%s = %s' % (x, builder.hardcoded_custom_type_dep_constants()[x]), builder.hardcoded_custom_type_dep_constants()))
|
custom_type_dep_constants = '\n'.join(map(lambda x: '%s = %s' % (x, builder.hardcoded_custom_type_dep_constants()[x]), builder.hardcoded_custom_type_dep_constants()))
|
||||||
|
custom_type_dep_constants_verification = '\n'.join(map(
|
||||||
|
lambda x: 'assert %s == %s' % (x, f'{spec_object.preset_vars[x].type_name}({spec_object.preset_vars[x].value})'),
|
||||||
|
builder.hardcoded_custom_type_dep_constants(),
|
||||||
|
))
|
||||||
spec = (
|
spec = (
|
||||||
builder.imports(preset_name)
|
builder.imports(preset_name)
|
||||||
+ builder.preparations()
|
+ builder.preparations()
|
||||||
@ -654,6 +658,7 @@ def objects_to_spec(preset_name: str,
|
|||||||
# Since some constants are hardcoded in setup.py, the following assertions verify that the hardcoded constants are
|
# Since some constants are hardcoded in setup.py, the following assertions verify that the hardcoded constants are
|
||||||
# as same as the spec definition.
|
# as same as the spec definition.
|
||||||
+ ('\n\n\n' + ssz_dep_constants_verification if ssz_dep_constants_verification != '' else '')
|
+ ('\n\n\n' + ssz_dep_constants_verification if ssz_dep_constants_verification != '' else '')
|
||||||
|
+ ('\n\n\n' + custom_type_dep_constants_verification if custom_type_dep_constants_verification != '' else '')
|
||||||
+ '\n'
|
+ '\n'
|
||||||
)
|
)
|
||||||
return spec
|
return spec
|
||||||
|
@ -10,9 +10,8 @@
|
|||||||
|
|
||||||
- [Introduction](#introduction)
|
- [Introduction](#introduction)
|
||||||
- [Custom types](#custom-types)
|
- [Custom types](#custom-types)
|
||||||
- [Constants](#constants)
|
|
||||||
- [Execution](#execution)
|
|
||||||
- [Preset](#preset)
|
- [Preset](#preset)
|
||||||
|
- [Execution](#execution)
|
||||||
- [Updated penalty values](#updated-penalty-values)
|
- [Updated penalty values](#updated-penalty-values)
|
||||||
- [Configuration](#configuration)
|
- [Configuration](#configuration)
|
||||||
- [Transition settings](#transition-settings)
|
- [Transition settings](#transition-settings)
|
||||||
@ -64,7 +63,7 @@ Additionally, this upgrade introduces the following minor changes:
|
|||||||
| `Transaction` | `ByteList[MAX_BYTES_PER_TRANSACTION]` | either a [typed transaction envelope](https://eips.ethereum.org/EIPS/eip-2718#opaque-byte-array-rather-than-an-rlp-array) or a legacy transaction|
|
| `Transaction` | `ByteList[MAX_BYTES_PER_TRANSACTION]` | either a [typed transaction envelope](https://eips.ethereum.org/EIPS/eip-2718#opaque-byte-array-rather-than-an-rlp-array) or a legacy transaction|
|
||||||
| `ExecutionAddress` | `Bytes20` | Address of account on the execution layer |
|
| `ExecutionAddress` | `Bytes20` | Address of account on the execution layer |
|
||||||
|
|
||||||
## Constants
|
## Preset
|
||||||
|
|
||||||
### Execution
|
### Execution
|
||||||
|
|
||||||
@ -77,8 +76,6 @@ Additionally, this upgrade introduces the following minor changes:
|
|||||||
| `MIN_GAS_LIMIT` | `uint64(5000)` (= 5,000) |
|
| `MIN_GAS_LIMIT` | `uint64(5000)` (= 5,000) |
|
||||||
| `MAX_EXTRA_DATA_BYTES` | `2**5` (= 32) |
|
| `MAX_EXTRA_DATA_BYTES` | `2**5` (= 32) |
|
||||||
|
|
||||||
## Preset
|
|
||||||
|
|
||||||
### Updated penalty values
|
### Updated penalty values
|
||||||
|
|
||||||
The Merge updates a few configuration values to move penalty parameters to their final, maximum security values.
|
The Merge updates a few configuration values to move penalty parameters to their final, maximum security values.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user