diff --git a/programs/vote_api/src/vote_state.rs b/programs/vote_api/src/vote_state.rs index 549eccef904ea6..64855afb2445a2 100644 --- a/programs/vote_api/src/vote_state.rs +++ b/programs/vote_api/src/vote_state.rs @@ -145,10 +145,22 @@ impl VoteState { .iter() .any(|(slot, hash)| vote.slot == *slot && vote.hash == *hash) { - warn!( - "dropping vote {:?}, no matching slot/hash combination", - vote - ); + if log_enabled!(log::Level::Warn) { + for (slot, hash) in slot_hashes { + if vote.slot == *slot { + warn!( + "dropped vote {:?} matched slot {}, but not hash {:?}", + vote, *slot, *hash + ); + } + if vote.hash == *hash { + warn!( + "dropped vote {:?} matched hash {:?}, but not slot {}", + vote, *hash, *slot, + ); + } + } + } return; }