From d29f587cc99a2ea52e84b80e4bfe0cb82589e115 Mon Sep 17 00:00:00 2001 From: 0xfoobar <83792390+0xfoobar@users.noreply.github.com> Date: Mon, 23 Oct 2023 23:31:09 -0400 Subject: [PATCH] Add Scroll mainnet to chain.rs --- ethers-core/src/types/chain.rs | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/ethers-core/src/types/chain.rs b/ethers-core/src/types/chain.rs index b4b085385..a0916caaa 100644 --- a/ethers-core/src/types/chain.rs +++ b/ethers-core/src/types/chain.rs @@ -88,6 +88,7 @@ pub enum Chain { Poa = 99, Sokol = 77, + Scroll = 534352, ScrollAlphaTestnet = 534353, Metis = 1088, @@ -303,7 +304,7 @@ impl Chain { Dev | AnvilHardhat => 200, Celo | CeloAlfajores | CeloBaklava => 5_000, FilecoinCalibrationTestnet | FilecoinMainnet => 30_000, - ScrollAlphaTestnet => 3_000, + Scroll | ScrollAlphaTestnet => 3_000, Gnosis | Chiado => 5_000, // Explicitly exhaustive. See NB above. Morden | Ropsten | Rinkeby | Goerli | Kovan | Sepolia | Holesky | Moonbase | @@ -349,7 +350,8 @@ impl Chain { Mantle | MantleTestnet | PolygonZkEvm | - PolygonZkEvmTestnet => true, + PolygonZkEvmTestnet | + Scroll => true, // Known EIP-1559 chains Mainnet | @@ -480,6 +482,7 @@ impl Chain { Gnosis => ("https://api.gnosisscan.io/api", "https://gnosisscan.io"), + Scroll => ("https://scrollscan.com/api", "https://scrollscan.com"), ScrollAlphaTestnet => { ("https://blockscout.scroll.io/api", "https://blockscout.scroll.io/") } @@ -609,7 +612,8 @@ impl Chain { Mantle | MantleTestnet | BaseGoerli | - Gnosis => "ETHERSCAN_API_KEY", + Gnosis | + Scroll => "ETHERSCAN_API_KEY", Avalanche | AvalancheFuji => "SNOWTRACE_API_KEY",