Skip to content

Commit 3c96d41

Browse files
authored
Merge pull request #3730 from ethereum/misc-fix
Misc fix for `v1.5.0-alpha.1`
2 parents 53357e3 + a4e04eb commit 3c96d41

File tree

6 files changed

+22
-17
lines changed

6 files changed

+22
-17
lines changed

configs/mainnet.yaml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,14 +52,13 @@ DENEB_FORK_VERSION: 0x04000000
5252
DENEB_FORK_EPOCH: 269568 # March 13, 2024, 01:55:35pm UTC
5353
# Electra
5454
ELECTRA_FORK_VERSION: 0x05000000
55-
ELECTRA_FORK_EPOCH: 18446744073709551615
55+
ELECTRA_FORK_EPOCH: 18446744073709551615 # temporary stub
56+
# EIP7594
57+
EIP7594_FORK_VERSION: 0x06000000 # temporary stub
58+
EIP7594_FORK_EPOCH: 18446744073709551615
5659
# WHISK
5760
WHISK_FORK_VERSION: 0x08000000 # temporary stub
5861
WHISK_FORK_EPOCH: 18446744073709551615
59-
# EIP7594
60-
EIP7594_FORK_VERSION: 0x06000001
61-
EIP7594_FORK_EPOCH: 18446744073709551615
62-
6362

6463
# Time parameters
6564
# ---------------------------------------------------------------

configs/minimal.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,12 +52,12 @@ DENEB_FORK_EPOCH: 18446744073709551615
5252
# Electra
5353
ELECTRA_FORK_VERSION: 0x05000001
5454
ELECTRA_FORK_EPOCH: 18446744073709551615
55-
# WHISK
56-
WHISK_FORK_VERSION: 0x08000001
57-
WHISK_FORK_EPOCH: 18446744073709551615
5855
# EIP7594
5956
EIP7594_FORK_VERSION: 0x06000001
6057
EIP7594_FORK_EPOCH: 18446744073709551615
58+
# WHISK
59+
WHISK_FORK_VERSION: 0x08000001
60+
WHISK_FORK_EPOCH: 18446744073709551615
6161

6262
# Time parameters
6363
# ---------------------------------------------------------------

specs/_features/eip7594/fork.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Warning: this configuration is not definitive.
2828

2929
| Name | Value |
3030
| - | - |
31-
| `EIP7594_FORK_VERSION` | `Version('0x05000000')` |
31+
| `EIP7594_FORK_VERSION` | `Version('0x06000000')` |
3232
| `EIP7594_FORK_EPOCH` | `Epoch(18446744073709551615)` **TBD** |
3333

3434
## Helper functions

tests/core/pyspec/eth2spec/test/bellatrix/block_processing/test_process_execution_payload.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -338,26 +338,30 @@ def run_randomized_non_validated_execution_fields_test(spec, state, execution_va
338338
@with_bellatrix_and_later
339339
@spec_state_test
340340
def test_randomized_non_validated_execution_fields_first_payload__execution_valid(spec, state):
341+
rng = Random(1111)
341342
state = build_state_with_incomplete_transition(spec, state)
342-
yield from run_randomized_non_validated_execution_fields_test(spec, state)
343+
yield from run_randomized_non_validated_execution_fields_test(spec, state, rng=rng)
343344

344345

345346
@with_bellatrix_and_later
346347
@spec_state_test
347348
def test_randomized_non_validated_execution_fields_regular_payload__execution_valid(spec, state):
349+
rng = Random(2222)
348350
state = build_state_with_complete_transition(spec, state)
349-
yield from run_randomized_non_validated_execution_fields_test(spec, state)
351+
yield from run_randomized_non_validated_execution_fields_test(spec, state, rng=rng)
350352

351353

352354
@with_bellatrix_and_later
353355
@spec_state_test
354356
def test_invalid_randomized_non_validated_execution_fields_first_payload__execution_invalid(spec, state):
357+
rng = Random(3333)
355358
state = build_state_with_incomplete_transition(spec, state)
356-
yield from run_randomized_non_validated_execution_fields_test(spec, state, execution_valid=False)
359+
yield from run_randomized_non_validated_execution_fields_test(spec, state, execution_valid=False, rng=rng)
357360

358361

359362
@with_bellatrix_and_later
360363
@spec_state_test
361364
def test_invalid_randomized_non_validated_execution_fields_regular_payload__execution_invalid(spec, state):
365+
rng = Random(4444)
362366
state = build_state_with_complete_transition(spec, state)
363-
yield from run_randomized_non_validated_execution_fields_test(spec, state, execution_valid=False)
367+
yield from run_randomized_non_validated_execution_fields_test(spec, state, execution_valid=False, rng=rng)

tests/core/pyspec/eth2spec/test/electra/epoch_processing/test_process_effective_balance_updates.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@
77
@with_electra_and_later
88
@spec_state_test
99
def test_effective_balance_hysteresis_with_compounding_credentials(spec, state):
10-
run_test_effective_balance_hysteresis(
10+
yield from run_test_effective_balance_hysteresis(
1111
spec, state, with_compounding_credentials=True
1212
)

tests/core/pyspec/eth2spec/utils/bls.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111
pairing as py_ecc_pairing,
1212
final_exponentiate as py_ecc_final_exponentiate,
1313
FQ12 as py_ecc_GT,
14+
FQ,
15+
FQ2,
1416
)
1517
from py_ecc.bls.g2_primitives import ( # noqa: F401
1618
curve_order as BLS_MODULUS,
@@ -252,14 +254,14 @@ def multi_exp(points, integers):
252254
raise Exception("Invalid point type")
253255

254256
result = None
255-
if isinstance(points[0], py_ecc_G1):
257+
if isinstance(points[0][0], FQ):
256258
result = Z1()
257-
elif isinstance(points[0], py_ecc_G2):
259+
elif isinstance(points[0][0], FQ2):
258260
result = Z2()
259261
else:
260262
raise Exception("Invalid point type")
261263

262-
for point, scalar in points.zip(integers):
264+
for point, scalar in zip(points, integers):
263265
result = add(result, multiply(point, scalar))
264266
return result
265267

0 commit comments

Comments
 (0)