Skip to content

Commit 4afe398

Browse files
authored
Merge pull request #3621 from ethereum/dev
Release v1.4.0
2 parents 2c0fcee + fa5edb7 commit 4afe398

File tree

5 files changed

+5
-40
lines changed

5 files changed

+5
-40
lines changed

specs/bellatrix/p2p-interface.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ Similar to the discussion about the maximum gossip size increase, the
168168
`ExecutionPayload` type can cause `BeaconBlock`s to exceed the 1 MiB bounds put
169169
in place during Phase 0.
170170

171-
As with the gossip limit, 10 MiB is selected because this is firmly below any
171+
As with the gossip limit, 10 MiB is selected because this is firmly above any
172172
valid block sizes in the range of gas limits expected in the medium term.
173173

174174
As with both gossip and req/rsp maximum values, type-specific limits should

specs/deneb/p2p-interface.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ The following validations MUST pass before forwarding the `blob_sidecar` on the
183183
- _[REJECT]_ The current finalized_checkpoint is an ancestor of the sidecar's block -- i.e. `get_checkpoint_block(store, block_header.parent_root, store.finalized_checkpoint.epoch) == store.finalized_checkpoint.root`.
184184
- _[REJECT]_ The sidecar's inclusion proof is valid as verified by `verify_blob_sidecar_inclusion_proof(blob_sidecar)`.
185185
- _[REJECT]_ The sidecar's blob is valid as verified by `verify_blob_kzg_proof(blob_sidecar.blob, blob_sidecar.kzg_commitment, blob_sidecar.kzg_proof)`.
186-
- _[IGNORE]_ The sidecar is the first sidecar for the tuple (block_header.slot, block_header.proposer_index, blob_sidecar.index) with valid header signature, sidecar inclusion proof, and kzg proof.
186+
- _[IGNORE]_ The sidecar is the first sidecar for the tuple `(block_header.slot, block_header.proposer_index, blob_sidecar.index)` with valid header signature, sidecar inclusion proof, and kzg proof.
187187
- _[REJECT]_ The sidecar is proposed by the expected `proposer_index` for the block's slot in the context of the current shuffling (defined by `block_header.parent_root`/`block_header.slot`).
188188
If the `proposer_index` cannot immediately be verified against the expected shuffling, the sidecar MAY be queued for later processing while proposers for the block's branch are calculated -- in such a case _do not_ `REJECT`, instead `IGNORE` this message.
189189

specs/phase0/beacon-chain.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,7 @@ The following values are (non-configurable) constants used throughout the specif
179179
| Name | Value |
180180
| - | - |
181181
| `UINT64_MAX` | `uint64(2**64 - 1)` |
182+
| `UINT64_MAX_SQRT` | `uint64(4294967295)` |
182183
| `GENESIS_SLOT` | `Slot(0)` |
183184
| `GENESIS_EPOCH` | `Epoch(0)` |
184185
| `FAR_FUTURE_EPOCH` | `Epoch(2**64 - 1)` |
@@ -601,7 +602,7 @@ def integer_squareroot(n: uint64) -> uint64:
601602
Return the largest integer ``x`` such that ``x**2 <= n``.
602603
"""
603604
if n == UINT64_MAX:
604-
return uint64(4294967295)
605+
return UINT64_MAX_SQRT
605606
x = n
606607
y = (x + 1) // 2
607608
while y < x:
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.4.0-beta.7
1+
1.4.0

tests/core/pyspec/eth2spec/test/deneb/transition/test_transition.py

Lines changed: 0 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -74,39 +74,3 @@ def test_higher_churn_limit_to_lower(state, fork_epoch, spec, post_spec, pre_tag
7474
churn_limit_1 = post_spec.get_validator_activation_churn_limit(state)
7575
assert churn_limit_1 == post_spec.config.MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT
7676
assert churn_limit_1 < churn_limit_0
77-
78-
79-
@with_fork_metas([ForkMeta(pre_fork_name=pre, post_fork_name=post, fork_epoch=2)
80-
for pre, post in AFTER_DENEB_PRE_POST_FORKS])
81-
@with_presets([MINIMAL], reason="churn limit update needs enough validators")
82-
def test_higher_churn_limit_to_lower__without_block(state, fork_epoch, spec, post_spec, pre_tag, post_tag):
83-
"""
84-
Test if churn limit goes from high to low due to EIP-7514.
85-
"""
86-
# Create high churn limit
87-
mock_activations = post_spec.config.MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT * spec.config.CHURN_LIMIT_QUOTIENT
88-
mock_activated_validators(spec, state, mock_activations)
89-
90-
transition_until_fork(spec, state, fork_epoch)
91-
92-
churn_limit_0 = spec.get_validator_churn_limit(state)
93-
assert churn_limit_0 > post_spec.config.MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT
94-
95-
# check pre state
96-
assert spec.get_current_epoch(state) < fork_epoch
97-
98-
yield "pre", state
99-
100-
# irregular state transition to handle fork
101-
# set with_block=False here
102-
state, _ = do_fork(state, spec, post_spec, fork_epoch, with_block=False)
103-
104-
# check post state
105-
assert spec.get_current_epoch(state) == fork_epoch
106-
107-
yield "blocks", []
108-
yield "post", state
109-
110-
churn_limit_1 = post_spec.get_validator_activation_churn_limit(state)
111-
assert churn_limit_1 == post_spec.config.MAX_PER_EPOCH_ACTIVATION_CHURN_LIMIT
112-
assert churn_limit_1 < churn_limit_0

0 commit comments

Comments
 (0)