From b3e45fd6b7b672007aa906b2e8743220005102e0 Mon Sep 17 00:00:00 2001 From: carllin Date: Thu, 16 May 2019 14:59:22 -0700 Subject: [PATCH] Add erroring tx to unexpected validator error logging (#4314) * Add tx logging to error * Add tx logging to unexpected validator errors --- core/src/blocktree_processor.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/src/blocktree_processor.rs b/core/src/blocktree_processor.rs index 70d0803db1..562831925e 100644 --- a/core/src/blocktree_processor.rs +++ b/core/src/blocktree_processor.rs @@ -36,16 +36,16 @@ fn par_execute_entries( MAX_RECENT_BLOCKHASHES, ); let mut first_err = None; - for r in results { + for (r, tx) in results.iter().zip(e.transactions.iter()) { if let Err(ref e) = r { if first_err.is_none() { first_err = Some(r.clone()); } if !Bank::can_commit(&r) { - warn!("Unexpected validator error: {:?}", e); + warn!("Unexpected validator error: {:?}, tx: {:?}", e, tx); datapoint!( "validator_process_entry_error", - ("error", format!("{:?}", e), String) + ("error", format!("error: {:?}, tx: {:?}", e, tx), String) ); } }