Fix lint & CI
This commit is contained in:
parent
4fbe162655
commit
7f31c80b8f
|
@ -32,6 +32,7 @@
|
|||
- [`on_tick`](#on_tick)
|
||||
- [`on_block`](#on_block)
|
||||
- [`on_attestation`](#on_attestation)
|
||||
- [`on_attester_slashing`](#on_attester_slashing)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- /TOC -->
|
||||
|
@ -181,7 +182,7 @@ def get_latest_attesting_balance(store: Store, root: Root) -> Gwei:
|
|||
attestation_score = Gwei(sum(
|
||||
state.validators[i].effective_balance for i in active_indices
|
||||
if (i in store.latest_messages
|
||||
and not i in store.has_equivocated
|
||||
and i not in store.has_equivocated
|
||||
and get_ancestor(store, store.latest_messages[i].root, store.blocks[root].slot) == root)
|
||||
))
|
||||
if store.proposer_boost_root == Root():
|
||||
|
@ -469,7 +470,8 @@ def on_attestation(store: Store, attestation: Attestation, is_from_block: bool=F
|
|||
```python
|
||||
def on_attester_slashing(store: Store, attester_slashing: AttesterSlashing) -> None:
|
||||
"""
|
||||
Run ``on_attester_slashing`` upon receiving a new ``AttesterSlashing`` from either within a block or directly on the wire.
|
||||
Run ``on_attester_slashing`` upon receiving a new ``AttesterSlashing`` from either within a block or directly
|
||||
on the wire.
|
||||
"""
|
||||
attestation_1 = attester_slashing.attestation_1
|
||||
attestation_2 = attester_slashing.attestation_2
|
||||
|
|
|
@ -368,7 +368,7 @@ def test_discard_equivocations(spec, state):
|
|||
|
||||
# Build equivocating attestations to feed to store
|
||||
state_eqv = state_1.copy()
|
||||
block_eqv = apply_empty_block(spec, state_eqv, state_eqv.slot+1)
|
||||
block_eqv = apply_empty_block(spec, state_eqv, state_eqv.slot + 1)
|
||||
attestation_eqv = get_valid_attestation(spec, state_eqv, slot=block_eqv.slot, signed=True)
|
||||
|
||||
next_slots(spec, state_1, 1)
|
||||
|
@ -420,4 +420,4 @@ def test_discard_equivocations(spec, state):
|
|||
}
|
||||
})
|
||||
|
||||
yield 'steps', test_steps
|
||||
yield 'steps', test_steps
|
||||
|
|
Loading…
Reference in New Issue