all: fix some typos (#25551)

* Fix some typos

* Fix some mistakes

* Revert 4byte.json

* Fix an incorrect fix

* Change files to fails
This commit is contained in:
Justin Traglia
2022-08-19 09:00:21 +03:00
committed by GitHub
parent a1b8892384
commit 2c5648d891
94 changed files with 200 additions and 200 deletions
+1 -1
View File
@@ -525,7 +525,7 @@ func (t *UDPv4) readLoop(unhandled chan<- ReadPacket) {
t.log.Debug("Temporary UDP read error", "err", err)
continue
} else if err != nil {
// Shut down the loop for permament errors.
// Shut down the loop for permanent errors.
if !errors.Is(err, io.EOF) {
t.log.Debug("UDP read error", "err", err)
}
+1 -1
View File
@@ -625,7 +625,7 @@ func (t *UDPv5) readLoop() {
t.log.Debug("Temporary UDP read error", "err", err)
continue
} else if err != nil {
// Shut down the loop for permament errors.
// Shut down the loop for permanent errors.
if !errors.Is(err, io.EOF) {
t.log.Debug("UDP read error", "err", err)
}
+3 -3
View File
@@ -111,7 +111,7 @@ const tuningImpact = 0.25
// local link is saturated. In that case, the live measurements will force us
// to reduce request sizes until the throughput gets stable.
//
// Lastly, message rate measurements allows us to detect if a peer is unsuaully
// Lastly, message rate measurements allows us to detect if a peer is unusually
// slow compared to other peers, in which case we can decide to keep it around
// or free up the slot so someone closer.
//
@@ -127,7 +127,7 @@ type Tracker struct {
// in their sizes.
//
// Callers of course are free to use the item counter as a byte counter if
// or when their protocol of choise if capped by bytes instead of items.
// or when their protocol of choice if capped by bytes instead of items.
// (eg. eth.getHeaders vs snap.getAccountRange).
capacity map[uint64]float64
@@ -157,7 +157,7 @@ func NewTracker(caps map[uint64]float64, rtt time.Duration) *Tracker {
}
// Capacity calculates the number of items the peer is estimated to be able to
// retrieve within the alloted time slot. The method will round up any division
// retrieve within the allotted time slot. The method will round up any division
// errors and will add an additional overestimation ratio on top. The reason for
// overshooting the capacity is because certain message types might not increase
// the load proportionally to the requested items, so fetching a bit more might
+1 -1
View File
@@ -121,7 +121,7 @@ func (t *Tracker) Track(peer string, version uint, reqCode uint64, resCode uint6
}
// clean is called automatically when a preset time passes without a response
// being dleivered for the first network request.
// being delivered for the first network request.
func (t *Tracker) clean() {
t.lock.Lock()
defer t.lock.Unlock()