Missing typehint for `convert_to_indexed`
And some minor cleanups
This commit is contained in:
parent
afdfb2a5de
commit
76893cafaa
|
@ -1160,9 +1160,9 @@ def verify_bitfield(bitfield: bytes, committee_size: int) -> bool:
|
|||
### `convert_to_indexed`
|
||||
|
||||
```python
|
||||
def convert_to_indexed(state: BeaconState, attestation: Attestation):
|
||||
def convert_to_indexed(state: BeaconState, attestation: Attestation) -> IndexedAttestation:
|
||||
"""
|
||||
Convert an attestation to (almost) indexed-verifiable form
|
||||
Convert an ``attestation`` to (almost) indexed-verifiable form.
|
||||
"""
|
||||
attesting_indices = get_attestation_participants(state, attestation.data, attestation.aggregation_bitfield)
|
||||
custody_bit_1_indices = get_attestation_participants(state, attestation.data, attestation.custody_bitfield)
|
||||
|
@ -1172,7 +1172,7 @@ def convert_to_indexed(state: BeaconState, attestation: Attestation):
|
|||
custody_bit_0_indices=custody_bit_0_indices,
|
||||
custody_bit_1_indices=custody_bit_1_indices,
|
||||
data=attestation.data,
|
||||
aggregate_signature=attestation.aggregate_signature
|
||||
aggregate_signature=attestation.aggregate_signature,
|
||||
)
|
||||
```
|
||||
|
||||
|
|
Loading…
Reference in New Issue