diff --git a/crates/consensus/src/lib.rs b/crates/consensus/src/lib.rs index 43251abcb8f..96fed1e586a 100644 --- a/crates/consensus/src/lib.rs +++ b/crates/consensus/src/lib.rs @@ -54,6 +54,12 @@ mod signed; pub use signed::Signed; /// Bincode-compatible serde implementations for consensus types. +/// +/// `bincode` crate doesn't work well with optionally serializable serde fields, but some of the +/// consensus types require optional serialization for RPC compatibility. This module makes so that +/// all fields are serialized. +/// +/// Read more: #[cfg(all(feature = "serde", feature = "serde-bincode-compat"))] pub mod serde_bincode_compat { pub use super::{