Skip to content

Commit 07a1c57

Browse files
committed
[v1.4.1] Merge branch 'testing' into stable
2 parents 44f652f + 6f44119 commit 07a1c57

File tree

6 files changed

+35
-6
lines changed

6 files changed

+35
-6
lines changed

CHANGELOG.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,27 @@
1+
2021-07-10 v1.4.1
2+
=================
3+
4+
Nimbus v1.4.1 - "Every attestation counts"
5+
6+
This release is marked as `low-urgency`
7+
8+
## Notable changes
9+
10+
Nimbus `v1.4.0` users might have noticed that they are missing a small number of (seemingly random) attestations since the update. Our investigation into the matter has showed that, due to `v1.4.0`'s significant performance improvements, Nimbus validators occasionally send their first attestation for a new epoch before some peers are ready. These "slow" peers end up dropping early attestations because they're busy with the epoch transition.
11+
12+
It's a rare occurrence, since it requires a validator to be scheduled to attest in the first slot of an epoch *and* for the beacon node to only be connected to "slow" peers for the respective libp2p topic. If both these conditions are true, a premature attestation may be lost in time, like tears in the rain.
13+
14+
As a fix, we are using a larger send delay: [#2705](https://github.com/status-im/nimbus-eth2/pull/2705).
15+
16+
Fo those Nimbus `v1.4.0` users who are concerned about reaching optimal attestation effectiveness, we encourage you to upgrade as soon as possible.
17+
18+
Other changes include log flushing and metrics fixes.
19+
20+
Full list:
21+
- increase attestation wait time ([#2705](https://github.com/status-im/nimbus-eth2/pull/2705))
22+
- ensure logs are printed without delays ([#2669](https://github.com/status-im/nimbus-eth2/pull/2669))
23+
- fix metrics on Windows ([#2707](https://github.com/status-im/nimbus-eth2/pull/2707))
24+
125
2021-06-21 v1.4.0
226
=================
327

beacon_chain/nimbus_binary_common.nim

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ proc setupStdoutLogging*(logLevel: string) =
3131
proc (logLevel: LogLevel, msg: LogOutputStr) {.gcsafe, raises: [Defect].} =
3232
try:
3333
stdout.write(msg)
34+
stdout.flushFile()
3435
except IOError as err:
3536
logLoggingFailure(cstring(msg), err)
3637

beacon_chain/validators/validator_duties.nim

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -688,14 +688,18 @@ proc handleValidatorDuties*(node: BeaconNode, lastSlot, slot: Slot) {.async.} =
688688
# An opposite case is that we received (or produced) a block that has
689689
# not yet reached our neighbours. To protect against our attestations
690690
# being dropped (because the others have not yet seen the block), we'll
691-
# impose a minimum delay of 250ms. The delay is enforced only when we're
691+
# impose a minimum delay of 1000ms. The delay is enforced only when we're
692692
# not hitting the "normal" cutoff time for sending out attestations.
693+
# An earlier delay of 250ms has proven to be not enough, increasing the
694+
# risk of losing attestations.
695+
# Regardless, because we "just" received the block, we'll impose the
696+
# delay.
693697

694-
const afterBlockDelay = 250
698+
const afterBlockDelay = 1000
695699
let
696700
afterBlockTime = node.beaconClock.now() + millis(afterBlockDelay)
697701
afterBlockCutoff = node.beaconClock.fromNow(
698-
min(afterBlockTime, attestationCutoffTime))
702+
min(afterBlockTime, attestationCutoffTime + millis(afterBlockDelay)))
699703

700704
if afterBlockCutoff.inFuture:
701705
debug "Got block, waiting to send attestations",

beacon_chain/version.nim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ when not defined(nimscript):
1616
const
1717
versionMajor* = 1
1818
versionMinor* = 4
19-
versionBuild* = 0
19+
versionBuild* = 1
2020

2121
versionBlob* = "stateofus" # Single word - ends up in the default graffitti
2222

0 commit comments

Comments
 (0)