From 4e7c82ccc6ebed0c01bc0efed9bf0114cd04b4dd Mon Sep 17 00:00:00 2001 From: dapplion <35266934+dapplion@users.noreply.github.com> Date: Sat, 23 Mar 2024 00:04:29 +0900 Subject: [PATCH] Remove is_aggregator changes --- specs/_features/eip7251/validator.md | 40 ---------------------------- 1 file changed, 40 deletions(-) delete mode 100644 specs/_features/eip7251/validator.md diff --git a/specs/_features/eip7251/validator.md b/specs/_features/eip7251/validator.md deleted file mode 100644 index efa519f77..000000000 --- a/specs/_features/eip7251/validator.md +++ /dev/null @@ -1,40 +0,0 @@ -# Phase 0 -- Honest Validator - -This is an accompanying document to [Phase 0 -- The Beacon Chain](./beacon-chain.md), which describes the expected actions of a "validator" participating in the Ethereum proof-of-stake protocol. - -## Table of contents - - - - - -- [Introduction](#introduction) -- [Beacon chain responsibilities](#beacon-chain-responsibilities) - - [Attestation aggregation](#attestation-aggregation) - - [Aggregation selection](#aggregation-selection) - - - - -## Introduction - -This document represents the changes to be made in the code of an "honest validator" to implement Deneb. - -## Beacon chain responsibilities - -### Attestation aggregation - -#### Aggregation selection - -Aggregator selection is now balance based. `state` is the `BeaconState` at the previous epoch of `slot` to allow lookahead. - -```python -def is_aggregator(state: BeaconState, slot: Slot, index: CommitteeIndex, - slot_signature: BLSSignature, validator: ValidatorIndex) -> bool: - committee = get_beacon_committee(state, slot, index) - committee_balance = get_total_balance(state, set(committee)) - balance = state.balances[validator] - modulo = max(1, committee_balance // balance // TARGET_AGGREGATORS_PER_COMMITTEE) - return bytes_to_uint64(hash(slot_signature)[0:8]) % modulo == 0 -``` -