diff --git a/pallets/moonbeam-foreign-assets/src/evm.rs b/pallets/moonbeam-foreign-assets/src/evm.rs index aae1b1bf14..2511c7f553 100644 --- a/pallets/moonbeam-foreign-assets/src/evm.rs +++ b/pallets/moonbeam-foreign-assets/src/evm.rs @@ -26,6 +26,7 @@ use precompile_utils::solidity::Codec; use precompile_utils_macro::keccak256; use sp_runtime::traits::ConstU32; use sp_runtime::DispatchError; +use sp_std::if_std; use sp_std::vec::Vec; use xcm::latest::Error as XcmError; @@ -36,9 +37,9 @@ const ERC20_CREATE_MAX_CALLDATA_SIZE: usize = 16 * 1024; // 16Ko const ERC20_CREATE_GAS_LIMIT: u64 = 3_367_000; // highest failure: 3_366_000 pub(crate) const ERC20_BURN_FROM_GAS_LIMIT: u64 = 155_000; // highest failure: 154_000 pub(crate) const ERC20_MINT_INTO_GAS_LIMIT: u64 = 155_000; // highest failure: 154_000 -const ERC20_PAUSE_GAS_LIMIT: u64 = 150_000; // highest failure: 149_500 +const ERC20_PAUSE_GAS_LIMIT: u64 = 150_500; // highest failure: 150_500 pub(crate) const ERC20_TRANSFER_GAS_LIMIT: u64 = 155_000; // highest failure: 154_000 -const ERC20_UNPAUSE_GAS_LIMIT: u64 = 150_000; // highest failure: 149_500 +const ERC20_UNPAUSE_GAS_LIMIT: u64 = 151_000; // highest failure: 150_200 pub enum EvmError { BurnFromFail, @@ -318,6 +319,11 @@ impl EvmCaller { ) .map_err(|_| Error::::EvmInternalError)?; + if_std! { + println!("EVM call result: {:?}", exec_info.exit_reason); + println!("EVM exec_info: {:?}", exec_info); + } + ensure!( matches!( exec_info.exit_reason,