Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: multiple typos #6776

Open
wants to merge 4 commits into
base: unstable
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion beacon_chain/consensus_object_pools/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ After "gossip validation" the consensus objects can be rebroadcasted as they are
For blocks, this means verifying state transition and all contained cryptographic signatures (instead of just the proposer signature).
For other consensus objects, it is possible that gossip validation is a superset of consensus verification (TODO).

The pools presenet in this folder are:
The pools present in this folder are:
- block_pools:
- block_quarantine: for seemingly valid blocks that are on a fork unknown to us.
- block_clearance: to verify (state_transition + cryptography) candidate blocks.
Expand Down
8 changes: 4 additions & 4 deletions beacon_chain/consensus_object_pools/attestation_pool.nim
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ type
proc(data: electra.Attestation) {.gcsafe, raises: [].}

Validation[CVBType] = object
## Validations collect a set of signatures for a distict attestation - in
## Validations collect a set of signatures for a distinct attestation - in
## eth2, a single bit is used to keep track of which signatures have been
## added to the aggregate meaning that only non-overlapping aggregates may
## be further combined.
Expand Down Expand Up @@ -696,7 +696,7 @@ func score(
doAssert aggregation_bits.len() == xxx[].len(),
"check_attestation ensures committee length"

# How many votes were in the attestation minues the votes that are the same
# How many votes were in the attestation minus the votes that are the same
return bitsScore - aggregation_bits.countOverlap(xxx[])

# Not found in cache - fresh vote meaning all attestations count
Expand Down Expand Up @@ -958,7 +958,7 @@ proc getElectraAttestationsForBlock*(

#TODO: Merge candidates per block structure with the candidates one
# and score possible on-chain attestations while collecting candidates
# (previous loop) and reavaluate cache key definition
# (previous loop) and reevaluate cache key definition
let
entry2 = block:
var e2 = entry.data
Expand Down Expand Up @@ -1197,7 +1197,7 @@ proc selectOptimisticHead*(
proc prune*(pool: var AttestationPool) =
if (let v = pool.forkChoice.prune(); v.isErr):
# If pruning fails, it's likely the result of a bug - this shouldn't happen
# but we'll keep running hoping that the fork chocie will recover eventually
# but we'll keep running hoping that the fork choice will recover eventually
error "Couldn't prune fork choice, bug?", err = v.error()

func validatorSeenAtEpoch*(pool: AttestationPool, epoch: Epoch,
Expand Down
2 changes: 1 addition & 1 deletion beacon_chain/consensus_object_pools/block_clearance.nim
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ proc addHeadBlockWithParent*(
var cache = StateCache()

# We've verified that the slot of the new block is newer than that of the
# parent, so we should now be able to create an approriate clearance state
# parent, so we should now be able to create an appropriate clearance state
# onto which we can apply the new block
let clearanceBlock = BlockSlotId.init(parent.bid, signedBlock.message.slot)
if not updateState(
Expand Down
2 changes: 1 addition & 1 deletion beacon_chain/consensus_object_pools/block_pools_types.nim
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ type
## instantiated: sync from genesis or checkpoint, and therefore, what
## features we can offer in terms of historical replay.
##
## Beacuse the state transition is forwards-only, checkpoint sync generally
## Because the state transition is forwards-only, checkpoint sync generally
## allows replaying states from that point onwards - anything earlier
## would require a backfill of blocks and a subsequent replay from genesis.
##
Expand Down
Loading