You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Accept a replacement tenure-start block when the previous proposal in the tenure was only pre-committed (never signed), instead of rejecting it with `DuplicateBlockFound`. This prevents a stall that occasionally shows up on mainnet.
2
-
Refuse to sign a block at the pre-commit threshold if a different block at the same or higher height in the tenure has already been signed.
2
+
Refuse to sign a block at the pre-commit threshold if a different block at the same or higher height in the tenure has been signed within `tenure_last_block_proposal_timeout`. After that timeout, the conflicting signed block is considered to have failed to reach consensus and the replacement may be signed.
"{self}: Reached the pre-commit threshold for a block, but we have already signed a different block at the same or higher height in this tenure. Refusing to sign.";
1177
+
// Only refuse while our signature on the conflicting block is fresh. If
1178
+
// `tenure_last_block_proposal_timeout` has passed without that block reaching
1179
+
// consensus, proposal evaluation already allows blocks that do not confirm it,
1180
+
// so allow signing the replacement too -- otherwise the tenure stalls until the
1181
+
// next sortition.
1182
+
let signature_is_fresh = last_signed.signed_self.is_some_and(|signed_time| {
1183
+
signed_time.saturating_add(
1184
+
self.proposal_config
1185
+
.tenure_last_block_proposal_timeout
1186
+
.as_secs(),
1187
+
) > get_epoch_time_secs()
1188
+
});
1189
+
if signature_is_fresh {
1190
+
warn!(
1191
+
"{self}: Reached the pre-commit threshold for a block, but we have already signed a different block at the same or higher height in this tenure. Refusing to sign.";
"{self}: Reached the pre-commit threshold for a block that conflicts with a previously signed block, but that block has timed out without reaching consensus. Signing the replacement.";
0 commit comments