Skip to content

Commit

Permalink
trying scroll sepolia
Browse files Browse the repository at this point in the history
  • Loading branch information
signorecello committed May 15, 2024
1 parent 550e9da commit 66149b8
Show file tree
Hide file tree
Showing 6 changed files with 95 additions and 25 deletions.
4 changes: 2 additions & 2 deletions vite-hardhat/.env.example
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# hardhat acct #0 key, please update
SEPOLIA_DEPLOYER_PRIVATE_KEY="0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80"
SEPOLIA_ALCHEMY_KEY=""
SEPOLIA_SCROLL_DEPLOYER_PRIVATE_KEY="0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80"
SEPOLIA_SCROLL_ETHERSCAN_KEY=""
23 changes: 19 additions & 4 deletions vite-hardhat/hardhat.config.cts
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,25 @@ const config: HardhatUserConfig = {
},
};

if (process.env.SEPOLIA_ALCHEMY_KEY && config.networks) {
config.networks.sepolia = {
url: `https://eth-sepolia.g.alchemy.com/v2/${process.env.SEPOLIA_ALCHEMY_KEY}`,
accounts: [process.env.SEPOLIA_DEPLOYER_PRIVATE_KEY as string],
if (process.env.SEPOLIA_SCROLL_ETHERSCAN_KEY && config.networks) {
config.networks.scrollSepolia = {
url: 'https://sepolia-rpc.scroll.io',
accounts: [process.env.SEPOLIA_SCROLL_DEPLOYER_PRIVATE_KEY as string],
};
config.etherscan = {
apiKey: {
scrollSepolia: process.env.SEPOLIA_SCROLL_ETHERSCAN_KEY,
},
customChains: [
{
network: 'sccrollSepolia',
chainId: 534352,
urls: {
apiURL: 'https://api-sepolia.scrollscan.com/api',
browserURL: 'https://sepolia.scrollscan.com/',
},
},
],
};
}

Expand Down
2 changes: 1 addition & 1 deletion vite-hardhat/hooks/useOnChainVerification.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ProofData } from '@noir-lang/types';
import { useAccount, useConnect, useContractRead } from 'wagmi';
import { contractCallConfig } from '../utils/wagmi.jsx';
import { config, contractCallConfig } from '../utils/wagmi.jsx';
import { bytesToHex } from 'viem';
import { useEffect, useState } from 'react';
import { Id, toast } from 'react-toastify';
Expand Down
16 changes: 10 additions & 6 deletions vite-hardhat/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,16 @@
"@noir-lang/noir_js": "^0.25.0",
"@noir-lang/noir_wasm": "^0.25.0",
"@noir-lang/types": "^0.25.0",
"@nomicfoundation/hardhat-network-helpers": "^1.0.0",
"@nomicfoundation/hardhat-toolbox-viem": "1.0.0",
"@nomicfoundation/hardhat-viem": "1.0.0",
"dotenv": "^16.0.3",
"hardhat": "^2.19.2",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-toastify": "^9.1.1",
"typechain": "^8.1.0",
"viem": "1.16.6"
"viem": "2.*",
"wagmi": "^2.8.7",
"@tanstack/query-sync-storage-persister": "5.0.5",
"@tanstack/react-query": ">=5.35.1",
"@tanstack/react-query-persist-client": "5.0.5"
},
"devDependencies": {
"@nomicfoundation/hardhat-chai-matchers": "^2.0.2",
Expand All @@ -41,7 +41,11 @@
"ts-node": "^10.9.1",
"typescript": "^4.9.3",
"vite": "^5.0.6",
"wagmi": "^2.8.7"
"@nomicfoundation/hardhat-network-helpers": "^1.0.0",
"@nomicfoundation/hardhat-toolbox-viem": "1.0.0",
"@nomicfoundation/hardhat-viem": "1.0.0",
"typechain": "^8.1.0",
"@tanstack/react-query-devtools": "5.0.5"
},
"engines": {
"node": "^20.10.0"
Expand Down
2 changes: 1 addition & 1 deletion vite-hardhat/utils/addresses.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"chainId":31337,"verifier":"0xcf7ed3acca5a467e9e704c703e8d87f634fb0fc9"}
{"chainId":534351,"verifier":"0xe13d6439b73f75cb6672cafe8a8bd814bb8318b3"}
73 changes: 62 additions & 11 deletions vite-hardhat/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@
resolved "https://registry.yarnpkg.com/@adraffy/ens-normalize/-/ens-normalize-1.10.0.tgz#d2a39395c587e092d77cbbc80acf956a54f38bf7"
integrity sha512-nA9XHtlAkYfJxY7bce8DcN7eKxWWCWkU+1GR9d+U6MbNpfwQp8TI7vqOsBsMcHoT4mBu2kypKoSKnghEzOOq5Q==

"@adraffy/[email protected]":
version "1.9.4"
resolved "https://registry.yarnpkg.com/@adraffy/ens-normalize/-/ens-normalize-1.9.4.tgz#aae21cb858bbb0411949d5b7b3051f4209043f62"
integrity sha512-UK0bHA7hh9cR39V+4gl2/NnBBjoXIxkuWAPCaY4X7fbH4L/azIi7ilWOCjMUYfpJgraLUAqkRi2BqrjME8Rynw==

"@aztec/[email protected]":
version "0.26.3"
resolved "https://registry.yarnpkg.com/@aztec/bb.js/-/bb.js-0.26.3.tgz#a148c3c8b35d78a92568f2f7ce9c05a8de4ead22"
Expand Down Expand Up @@ -1782,6 +1777,57 @@
resolved "https://registry.yarnpkg.com/@swc/types/-/types-0.1.5.tgz#043b731d4f56a79b4897a3de1af35e75d56bc63a"
integrity sha512-myfUej5naTBWnqOCc/MdVOLVjXUXtIA+NpDrDBKJtLLg2shUjBu3cZmB/85RyitKc55+lUUyl7oRfLOvkr2hsw==

"@tanstack/[email protected]":
version "5.0.5"
resolved "https://registry.yarnpkg.com/@tanstack/query-core/-/query-core-5.0.5.tgz#db02d648398f75a04cc536dacd640265f3614b14"
integrity sha512-MThCETMkHDHTnFZHp71L+SqTtD5d6XHftFCVR1xRJdWM3qGrlQ2VCXaj0SKVcyJej2e1Opa2c7iknu1llxCDNQ==

"@tanstack/[email protected]":
version "5.36.0"
resolved "https://registry.yarnpkg.com/@tanstack/query-core/-/query-core-5.36.0.tgz#905bd05b6a73e58d70d95912d84e979ed865ab6a"
integrity sha512-B5BD3pg/mztDR36i77hGcyySKKeYrbM5mnogOROTBi1SUml5ByRK7PGUUl16vvubvQC+mSnqziFG/VIy/DE3FQ==

"@tanstack/[email protected]":
version "5.0.5"
resolved "https://registry.yarnpkg.com/@tanstack/query-devtools/-/query-devtools-5.0.5.tgz#4547bf772fde5ff233b050a82e18caa8e1f68a3f"
integrity sha512-xjuOhOrrO50sPoJ4WG9yPe3imQ0Ds/nutnmwdTqjM2ZTIkflh//p7q2iB6IxFBY9sB106h+PULlma8sgTuOKAQ==

"@tanstack/[email protected]":
version "5.0.5"
resolved "https://registry.yarnpkg.com/@tanstack/query-persist-client-core/-/query-persist-client-core-5.0.5.tgz#df8af493e30e6fd9f39118daae711e8552ec039c"
integrity sha512-xdxDiSN/gBG1QJBiyNZPv2y1DOBMrILvhrEd9PgtOzE1AswmgVUh96KENiD7QiABKCVVIihDtSDvJGj0ukbudg==
dependencies:
"@tanstack/query-core" "5.0.5"

"@tanstack/[email protected]":
version "5.0.5"
resolved "https://registry.yarnpkg.com/@tanstack/query-sync-storage-persister/-/query-sync-storage-persister-5.0.5.tgz#e583c800ad7177fb6300d3548cc2ca0fa14af46e"
integrity sha512-uk2/mcNf+YYVza3XaU61RSPCcIi/p+0DfsZWMyIim1yCxF7hzZ17zWheM/2v3zZbeTY/C6m1NIO9KIRiPAM9Mg==
dependencies:
"@tanstack/query-core" "5.0.5"
"@tanstack/query-persist-client-core" "5.0.5"

"@tanstack/[email protected]":
version "5.0.5"
resolved "https://registry.yarnpkg.com/@tanstack/react-query-devtools/-/react-query-devtools-5.0.5.tgz#93fa8526aa71d3c945f9e85df8e4a9e5543626c1"
integrity sha512-vJyS7HXx2zw43TQjm3m4uyaNUgGizOpK2SZL9Lc+DZSuhFbuZ55UEYJTz8yudCbHdLXlkuVZwo6TWWOhXWJFeA==
dependencies:
"@tanstack/query-devtools" "5.0.5"

"@tanstack/[email protected]":
version "5.0.5"
resolved "https://registry.yarnpkg.com/@tanstack/react-query-persist-client/-/react-query-persist-client-5.0.5.tgz#846e231fef61ec3e383d831c78b5757126507ca0"
integrity sha512-V/jIKdiw0WyJYpnzwnKS+O19jgJPWSBDzvx9qFaXAm98Jnt+lGWFBZdUR0MgY2ufM1fbeejXTjcorgwqjc3kaA==
dependencies:
"@tanstack/query-persist-client-core" "5.0.5"

"@tanstack/react-query@>=5.35.1":
version "5.36.0"
resolved "https://registry.yarnpkg.com/@tanstack/react-query/-/react-query-5.36.0.tgz#680cb1490d8b823ec7185e1a97065241cda2ea67"
integrity sha512-BATvtM0rohwg7pRHUnxgeDiwLWRGZ8OM/4y8LImHVpecQWoH6Uhytu3Z8YV6V7hQ1sMQBFcUrGE1/e4MxR6YiA==
dependencies:
"@tanstack/query-core" "5.36.0"

"@tsconfig/node10@^1.0.7":
version "1.0.9"
resolved "https://registry.yarnpkg.com/@tsconfig/node10/-/node10-1.0.9.tgz#df4907fc07a886922637b15e02d4cebc4c0021b2"
Expand Down Expand Up @@ -2446,6 +2492,11 @@ [email protected]:
resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.9.8.tgz#1f120b6b717459deafd213dfbf3a3dd1bf10ae8c"
integrity sha512-puLifILdm+8sjyss4S+fsUN09obiT1g2YW6CtcQF+QDzxR0euzgEB29MZujC6zMk2a6SVmtttq1fc6+YFA7WYQ==

[email protected]:
version "1.0.0"
resolved "https://registry.yarnpkg.com/abitype/-/abitype-1.0.0.tgz#237176dace81d90d018bebf3a45cb42f2a2d9e97"
integrity sha512-NMeMah//6bJ56H5XRj8QCV4AwuW6hB6zqz2LnhhLdcWVQOsXki6/Pn3APeqxCma62nXIcmZWdu1DlHWS74umVQ==

abitype@^0.9.8:
version "0.9.10"
resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.9.10.tgz#fa6fa30a6465da98736f98b6c601a02ed49f6eec"
Expand Down Expand Up @@ -6969,17 +7020,17 @@ [email protected]:
proxy-compare "2.5.1"
use-sync-external-store "1.2.0"

viem@1.16.6:
version "1.16.6"
resolved "https://registry.yarnpkg.com/viem/-/viem-1.16.6.tgz#78118c9269506a59e2bc4deab13f1646e113d3fc"
integrity sha512-jcWcFQ+xzIfDwexwPJRvCuCRJKEkK9iHTStG7mpU5MmuSBpACs4nATBDyXNFtUiyYTFzLlVEwWkt68K0nCSImg==
viem@2.*:
version "2.10.5"
resolved "https://registry.yarnpkg.com/viem/-/viem-2.10.5.tgz#97e53421e20886b34e4e5e03d01f8b6e320d216f"
integrity sha512-rzU2y6poYgXu7axcQmwddaJ/nGP3tjtslXdUCu+PvryeXACuuqoyP3chjTEHciG84a663gYbrVGbxNUFA3aURQ==
dependencies:
"@adraffy/ens-normalize" "1.9.4"
"@adraffy/ens-normalize" "1.10.0"
"@noble/curves" "1.2.0"
"@noble/hashes" "1.3.2"
"@scure/bip32" "1.3.2"
"@scure/bip39" "1.2.1"
abitype "0.9.8"
abitype "1.0.0"
isows "1.0.3"
ws "8.13.0"

Expand Down

0 comments on commit 66149b8

Please sign in to comment.