Skip to content

Commit

Permalink
Set gas usage in txn
Browse files Browse the repository at this point in the history
  • Loading branch information
zhongeric committed Aug 19, 2024
1 parent 50b1498 commit 546a2f8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/executors/public_1559_executor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ where
}
action.execution.tx.as_eip1559_mut().unwrap().max_fee_per_gas = Some(base_fee);
action.execution.tx.as_eip1559_mut().unwrap().max_priority_fee_per_gas = bid_priority_fee;
action.execution.tx.set_gas(U256::from(1_000_000));
action.execution.tx.set_gas(gas_usage_result);
info!("Executing tx {:?}", action.execution.tx);
self.sender_client.send_transaction(action.execution.tx, None).await?;
Ok(())
Expand Down
8 changes: 4 additions & 4 deletions src/strategies/priority_strategy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -230,10 +230,10 @@ impl<M: Middleware + 'static> UniswapXPriorityFill<M> {
self.update_open_orders();
self.prune_done_orders();

// self.batch_sender
// .send(self.get_order_batches())
// .await
// .ok()?;
self.batch_sender
.send(self.get_order_batches())
.await
.ok()?;

None
}
Expand Down

0 comments on commit 546a2f8

Please sign in to comment.