Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
brunoffranca committed Dec 17, 2024
1 parent b974be2 commit 0f6a184
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions core/lib/protobuf_config/src/consensus.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use zksync_config::configs::consensus::{
AttesterPublicKey, ConsensusConfig, GenesisSpec, Host, NodePublicKey, ProtocolVersion,
RpcConfig, ValidatorPublicKey, WeightedAttester, WeightedValidator,
};
use zksync_protobuf::{kB, read_optional, repr::ProtoRepr, required, ProtoFmt};
use zksync_protobuf::{kB, read_optional, read_required, repr::ProtoRepr, required, ProtoFmt};

use crate::{parse_h160, proto::consensus as proto, read_optional_repr};

Expand Down Expand Up @@ -154,7 +154,7 @@ impl ProtoRepr for proto::Config {
.context("server_addr")?,
public_addr: Host(required(&self.public_addr).context("public_addr")?.clone()),
max_payload_size,
view_timeout: required(&self.view_timeout).context("view_timeout")?,
view_timeout: read_required(&self.view_timeout).context("view_timeout")?,
max_batch_size,
gossip_dynamic_inbound_limit: required(&self.gossip_dynamic_inbound_limit)
.and_then(|x| Ok((*x).try_into()?))
Expand Down
2 changes: 1 addition & 1 deletion core/node/consensus/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use std::collections::{BTreeMap, HashMap};

use anyhow::Context as _;
use secrecy::{ExposeSecret as _, Secret};
use zksync_concurrency::{limiter, net, time};
use zksync_concurrency::net;
use zksync_config::{
configs,
configs::consensus::{ConsensusConfig, ConsensusSecrets, Host, NodePublicKey},
Expand Down
2 changes: 1 addition & 1 deletion core/node/consensus/src/testonly.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ fn make_config(
public_addr: config::Host(cfg.public_addr.0.clone()),
max_payload_size: usize::MAX,
max_batch_size: usize::MAX,
view_timeout: usize::MAX,
view_timeout: time::Duration::milliseconds(10000),
gossip_dynamic_inbound_limit: cfg.gossip.dynamic_inbound_limit,
gossip_static_inbound: cfg
.gossip
Expand Down

0 comments on commit 0f6a184

Please sign in to comment.