diff --git a/.changelog/unreleased/bug-fixes/1558-fix-slash-logging.md b/.changelog/unreleased/bug-fixes/1558-fix-slash-logging.md new file mode 100644 index 0000000000..3b3df8cce3 --- /dev/null +++ b/.changelog/unreleased/bug-fixes/1558-fix-slash-logging.md @@ -0,0 +1,3 @@ +- Fixes the slash rate output in the query_slashes client + command and some redundancy in misbehavior reporting logs. + ([#1558](https://github.com/anoma/namada/pull/1558)) \ No newline at end of file diff --git a/apps/src/lib/client/rpc.rs b/apps/src/lib/client/rpc.rs index 04b3cb131d..4661af0ece 100644 --- a/apps/src/lib/client/rpc.rs +++ b/apps/src/lib/client/rpc.rs @@ -1512,9 +1512,7 @@ pub async fn query_slashes( writeln!( w, "Slash epoch {}, type {}, rate {}", - slash.epoch, - slash.r#type, - slash.r#type.get_slash_rate(¶ms) + slash.epoch, slash.r#type, slash.rate ) .unwrap(); } diff --git a/apps/src/lib/node/ledger/shell/mod.rs b/apps/src/lib/node/ledger/shell/mod.rs index ad2eb1b501..457d988e93 100644 --- a/apps/src/lib/node/ledger/shell/mod.rs +++ b/apps/src/lib/node/ledger/shell/mod.rs @@ -593,11 +593,13 @@ where } }; tracing::info!( - "Slashing {} for {} in epoch {}, block height {}", + "Slashing {} for {} in epoch {}, block height {} (current \ + epoch = {})", validator, slash_type, evidence_epoch, - evidence_height + evidence_height, + current_epoch ); if let Err(err) = slash( &mut self.wl_storage, diff --git a/proof_of_stake/src/lib.rs b/proof_of_stake/src/lib.rs index b1fdb82bc0..02bce6de19 100644 --- a/proof_of_stake/src/lib.rs +++ b/proof_of_stake/src/lib.rs @@ -3003,13 +3003,6 @@ pub fn slash( where S: StorageRead + StorageWrite, { - tracing::info!( - "Slashing validator {} on new evidence from epoch {} (current epoch = \ - {})", - validator, - evidence_epoch, - current_epoch - ); let evidence_block_height: u64 = evidence_block_height.into(); let slash = Slash { epoch: evidence_epoch,