message: Make ConsensusMessage debug string a bit less verbose.
diff: @@ -18,6 +18,10 @@ use std::{
  };
  use datasize::DataSize;
  +use derive_more::From;
  +use hex_fmt::HexFmt;
  +use serde::{Deserialize, Serialize};
  +use tracing::error;
  use casper_execution_engine::core::engine_state::era_validators::GetEraValidatorsError;
  use casper_types::auction::ValidatorWeights;
  @@ -39,15 +43,11 @@ use crate::{
  pub use config::Config;
  pub(crate) use consensus_protocol::{BlockContext, EraEnd};
  -use derive_more::From;
  pub(crate) use era_supervisor::{EraId, EraSupervisor};
  -use hex_fmt::HexFmt;
  pub(crate) use protocols::highway::HighwayProtocol;
  -use serde::{Deserialize, Serialize};
  -use tracing::error;
  use traits::NodeIdT;
  -#[derive(Debug, DataSize, Clone, Serialize, Deserialize)]
  +#[derive(DataSize, Clone, Serialize, Deserialize)]
  pub enum ConsensusMessage {
  /// A protocol message, to be handled by the instance in the specified era.
  Protocol { era_id: EraId, payload: Vec<u8> },
  @@ -56,6 +56,23 @@ pub enum ConsensusMessage {
  EvidenceRequest { era_id: EraId, pub_key: PublicKey },
  }
  +impl Debug for ConsensusMessage {
  + fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
  + match self {
  + ConsensusMessage::Protocol { era_id, payload } => f
  + .debug_struct("Protocol")
  + .field("era_id.0", &era_id.0)
  + .field("payload", &HexFmt(payload))
  + .finish(),
  + ConsensusMessage::EvidenceRequest { era_id, pub_key } => f
  + .debug_struct("EvidenceRequest")
  + .field("era_id.0", &era_id.0)
  + .field("pub_key", pub_key)
  + .finish(),
  + }
  + }
  +}
  +
  /// Consensus component event.
  #[derive(DataSize, Debug, From)]
  pub enum Event<I> {
  