MCPcopy Create free account
hub / github.com/consensus-shipyard/ipc / to_check_tx

Function to_check_tx

fendermint/app/src/tmconv.rs:123–140  ·  view source on GitHub ↗
(ret: CheckResponse)

Source from the content-addressed store, hash-verified

121}
122
123pub fn to_check_tx(ret: CheckResponse) -> response::CheckTx {
124 // Putting the message `log` because only `log` appears in the `tx_sync` JSON-RPC response.
125 let message = ret
126 .info
127 .filter(|s| !s.is_empty())
128 .unwrap_or_else(|| to_error_msg(ret.exit_code).to_owned());
129
130 response::CheckTx {
131 code: to_code(ret.exit_code),
132 log: message.clone(),
133 info: Default::default(),
134 data: Default::default(),
135 gas_wanted: ret.gas_limit.try_into().unwrap_or(i64::MAX),
136 sender: ret.sender.to_string(),
137 priority: ret.priority,
138 ..Default::default()
139 }
140}
141
142/// Map the return values from cron operations.
143pub fn to_begin_block(ret: AppliedMessage) -> response::BeginBlock {

Callers 1

check_txMethod · 0.85

Calls 5

to_error_msgFunction · 0.85
to_codeFunction · 0.85
try_intoMethod · 0.80
to_stringMethod · 0.80
is_emptyMethod · 0.45

Tested by

no test coverage detected