Skip to content

Commit

Permalink
feat: add scroll to gas price oracle (#687)
Browse files Browse the repository at this point in the history
  • Loading branch information
dohaki committed Jul 18, 2024
1 parent 52c59a0 commit 1efd544
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion e2e/oracle.e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,14 +51,15 @@ const networks: { [chainId: number]: string } = {
324: "https://mainnet.era.zksync.io",
8453: "https://mainnet.base.org",
42161: "https://rpc.ankr.com/arbitrum",
534352: "https://rpc.scroll.io",
};

const stdGasPrice = ethersUtils.parseUnits("10", 9);
const stdMaxPriorityFeePerGas = ethersUtils.parseUnits("1.5", 9); // EIP-1559 chains only
const stdLastBaseFeePerGas = stdGasPrice.sub(stdMaxPriorityFeePerGas);
const stdMaxFeePerGas = stdGasPrice;
const eip1559Chains = [1, 10, 137, 8453, 42161];
const legacyChains = [288, 324];
const legacyChains = [288, 324, 534352];

let providerInstances: { [chainId: number]: MockedProvider } = {};

Expand Down
1 change: 1 addition & 0 deletions src/gasPriceOracle/oracle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ export async function getGasPriceEstimate(
[CHAIN_IDs.OPTIMISM]: ethereum.eip1559,
[CHAIN_IDs.POLYGON]: polygon.gasStation,
[CHAIN_IDs.ZK_SYNC]: ethereum.legacy,
[CHAIN_IDs.SCROLL]: ethereum.legacy,
};

let gasPriceFeed = gasPriceFeeds[chainId];
Expand Down

0 comments on commit 1efd544

Please sign in to comment.