diff --git a/src/eth/executor.rs b/src/eth/executor.rs index 077550890..7529df1eb 100644 --- a/src/eth/executor.rs +++ b/src/eth/executor.rs @@ -118,6 +118,7 @@ impl EthExecutor { Ok((mut execution, execution_metrics)) => { // apply execution costs that were not consided when re-executing the transaction execution.apply_execution_costs(&receipt)?; + execution.gas = receipt.gas_used.unwrap_or_default().try_into()?; // ensure it matches receipt before saving if let Err(e) = execution.compare_with_receipt(&receipt) { diff --git a/src/eth/storage/csv/csv_exporter.rs b/src/eth/storage/csv/csv_exporter.rs index 449169d83..43bad4cdc 100644 --- a/src/eth/storage/csv/csv_exporter.rs +++ b/src/eth/storage/csv/csv_exporter.rs @@ -300,7 +300,7 @@ impl CsvExporter { tx.input.to.map(to_bytea).unwrap_or_default(), // address_to to_bytea(tx.input.input), // input to_bytea(tx.execution.output), // output - tx.input.gas_limit.to_string(), // gas + tx.execution.gas.to_string(), // gas tx.input.gas_price.to_string(), // gas_price tx.transaction_index.to_string(), // idx_in_block tx.block_number.to_string(), // block_number