From 307909dd92341a5c2d580634679ad8cf21733367 Mon Sep 17 00:00:00 2001 From: Federico Franzoni <8609060+fed-franz@users.noreply.github.com> Date: Fri, 20 Dec 2024 11:06:16 +0100 Subject: [PATCH] rusk: update vm logs --- rusk/src/lib/http/chain.rs | 7 ++++++- rusk/src/lib/node/vm.rs | 4 ++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/rusk/src/lib/http/chain.rs b/rusk/src/lib/http/chain.rs index 1054ab96b..f477194ab 100644 --- a/rusk/src/lib/http/chain.rs +++ b/rusk/src/lib/http/chain.rs @@ -182,7 +182,12 @@ impl RuskNode { .map_err(|e| anyhow::anyhow!("Invalid Data {e:?}"))?; let db = self.inner().database(); let vm = self.inner().vm_handler(); - MempoolSrv::check_tx(&db, &vm, &tx.into(), true, usize::MAX).await?; + MempoolSrv::check_tx(&db, &vm, &tx.into(), true, usize::MAX) + .await + .map_err(|e| { + error!("Tx {} not accepted: {e}", hex::encode(tx.id())); + e + })?; Ok(ResponseData::new(DataType::None)) } diff --git a/rusk/src/lib/node/vm.rs b/rusk/src/lib/node/vm.rs index e33a06239..fd16d30ff 100644 --- a/rusk/src/lib/node/vm.rs +++ b/rusk/src/lib/node/vm.rs @@ -90,7 +90,7 @@ impl VMExecution for Rusk { VerificationOutput, Vec, )> { - info!("Received accept request"); + debug!("Received accept request"); let generator = blk.header().generator_bls_pubkey; let generator = BlsPublicKey::from_slice(&generator.0) .map_err(|e| anyhow::anyhow!("Error in from_slice {e:?}"))?; @@ -129,7 +129,7 @@ impl VMExecution for Rusk { commit: [u8; 32], to_merge: Vec<[u8; 32]>, ) -> anyhow::Result<()> { - info!("Received finalize request"); + debug!("Received finalize request"); self.finalize_state(commit, to_merge) .map_err(|e| anyhow::anyhow!("Cannot finalize state: {e}")) }