Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
rouzwelt committed Nov 20, 2024
1 parent 011b767 commit 172aa0c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
10 changes: 9 additions & 1 deletion src/modes/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Contract } from "ethers";
import { BigNumber, Contract } from "ethers";
import { PublicClient } from "viem";
import { DataFetcher } from "sushi";
import { Token } from "sushi/currency";
Expand Down Expand Up @@ -43,6 +43,14 @@ export async function findOpp({
toToken: Token;
fromToken: Token;
}): Promise<DryrunResult> {
try {
gasPrice = BigNumber.from(await viemClient.getGasPrice())
.mul(config.gasPriceMultiplier)
.div("100")
.toBigInt();
} catch {
/**/
}
const promises = [
findRpOpp({
orderPairObject,
Expand Down
2 changes: 0 additions & 2 deletions src/processOrders.ts
Original file line number Diff line number Diff line change
Expand Up @@ -333,8 +333,6 @@ export const processOrders = async (
}
if (e.spanAttributes["txNoneNodeError"]) {
span.setAttribute("severity", ErrorSeverity.HIGH);
} else {
span.setAttribute("severity", ErrorSeverity.LOW);
}
span.setStatus({ code: SpanStatusCode.ERROR, message });
span.setAttribute("unsuccessfulClear", true);
Expand Down

0 comments on commit 172aa0c

Please sign in to comment.