8000 Upgrading HardHat verify to support Sourcify by brickpop · Pull Request #655 · aragon/osx · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Upgrading HardHat verify to support Sourcify #655

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) {
await verifyContract(element.address, element.args || [], element.contract);

// Etherscan Max rate limit is 1/5s,
// use 6s just to be safe.
// use 5.1s just to be safe.
console.log(
`Delaying 6s, so we dont reach Etherscan's Max rate limit of 1/5s.`
`Delaying 5 seconds, to prevent hitting the block explorer's rate limit.`
);
await delay(6000);
await delay(5100);
}
};
export default func;
Expand Down
6 changes: 6 additions & 0 deletions packages/contracts/hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ const config: HardhatUserConfig = {
currency: 'USD',
},
etherscan: {
enabled: true,
apiKey: {
mainnet: process.env.ETHERSCAN_KEY || '',
sepolia: process.env.ETHERSCAN_KEY || '',
Expand Down Expand Up @@ -248,6 +249,11 @@ const config: HardhatUserConfig = {
},
],
},
sourcify: {
enabled: false,
apiUrl: 'https://sourcify-api-monad.blockvision.org',
browserUrl: 'https://testnet.monadexplorer.com',
},
namedAccounts: {
deployer: 0,
},
Expand Down
3 changes: 3 additions & 0 deletions packages/contracts/networks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ export const networkExtensions: {[index: string]: NetworkExtension} = {
peaq: {
deploy: ['./deploy/new', './deploy/verification'],
},
monadTestnet: {
deploy: ['./deploy/new', './deploy/verification'],
},
localhost: {
deploy: ['./deploy/new'],
},
Expand Down
8 changes: 4 additions & 4 deletions packages/contracts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,14 @@
"@aragon/osx-v1.3.0": "npm:@aragon/osx@1.3.0",
"@defi-wonderland/smock": "^2.3.4",
"@matterlabs/hardhat-zksync-deploy": "0.8",
"@matterlabs/hardhat-zksync-ethers": "0.0.1-beta.2",
"@matterlabs/hardhat-zksync-node": "0.2.0",
"@matterlabs/hardhat-zksync-solc": "1.2.5",
"@matterlabs/hardhat-zksync-upgradable": "0.4.0",
"@matterlabs/hardhat-zksync-verify": "0.7.0",
"@matterlabs/hardhat-zksync-ethers": "0.0.1-beta.2",
"zksync-ethers": "5.7.0",
"@nomicfoundation/hardhat-chai-matchers": "^1.0.5",
"@nomicfoundation/hardhat-network-helpers": "^1.0.8",
"@nomicfoundation/hardhat-verify": "^1.0.4",
"@nomicfoundation/hardhat-verify": "^2.0.13",
"@nomiclabs/hardhat-ethers": "^2.2.1",
"@openzeppelin/hardhat-upgrades": "^1.23.1",
"@typechain/ethers-v5": "7.2.0",
Expand All @@ -82,13 +81,14 @@
"hardhat-deploy": "0.12.4",
"hardhat-gas-reporter": "^1.0.4",
"ipfs-http-client": "51.0.0",
"lodash.startcase": "^4.4.0",
"solhint": "^3.3.6",
"solidity-coverage": "^0.8.2",
"solidity-docgen": "^0.6.0-beta.35",
"tmp-promise": "^3.0.3",
"ts-node": "^8.1.0",
"typechain": "^5.2.0",
"typescript": "^4.4.4",
"lodash.startcase": "^4.4.0"
"zksync-ethers": "5.7.0"
}
}
41 changes: 8 additions & 33 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1134,17 +1134,17 @@
dependencies:
ethereumjs-util "^7.1.4"

"@nomicfoundation/hardhat-verify@^1.0.4":
version "1.1.1"
resolved "https://registry.yarnpkg.com/@nomicfoundation/hardhat-verify/-/hardhat-verify-1.1.1.tgz#6a433d777ce0172d1f0edf7f2d3e1df14b3ecfc1"
integrity sha512-9QsTYD7pcZaQFEA3tBb/D/oCStYDiEVDN7Dxeo/4SCyHRSm86APypxxdOMEPlGmXsAvd+p1j/dTODcpxb8aztA==
"@nomicfoundation/hardhat-verify@^2.0.13":
version "2.0.13"
resolved "https://registry.yarnpkg.com/@nomicfoundation/hardhat-verify/-/hardhat-verify-2.0.13.tgz#41691adc32e01dc5cf6b725615f64958fba2100b"
integrity sha512-i57GX1sC0kYGyRVnbQrjjyBTpWTKgrvKC+jH8CMKV6gHp959Upb8lKaZ58WRHIU0espkulTxLnacYeUDirwJ2g==
dependencies:
"@ethersproject/abi" "^5.1.2"
"@ethersproject/address" "^5.0.2"
cbor "^8.1.0"
chalk "^2.4.2"
debug "^4.1.1"
lodash.clonedeep "^4.5.0"
picocolors "^1.1.0"
semver "^6.3.0"
table "^6.8.0"
undici "^5.14.0"
Expand Down Expand Up @@ -8513,7 +8513,7 @@ string-format@^2.0.0:
resolved "https://registry.yarnpkg.com/string-format/-/string-format-2.0.0.tgz#f2df2e7097440d3b65de31b6d40d54c96eaffb9b"
integrity sha512-bbEs3scLeYNXLecRRuk6uJxdXUSj6le/8rNPHChIJTn2V79aXVTR1EH2OH5zLKKoz0V0 ED48 2fOUKZZcw01pLUShZA==

"string-width-cjs@npm:string-width@^4.2.0":
"string-width-cjs@npm:string-width@^4.2.0", string-width@^4.0.0, string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.2, string-width@^4.2.3:
version "4.2.3"
resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010"
integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==
Expand All @@ -8539,15 +8539,6 @@ string-width@^2.1.1:
is-fullwidth-code-point "^2.0.0"
strip-ansi "^4.0.0"

string-width@^4.0.0, string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.2, string-width@^4.2.3:
version "4.2.3"
resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010"
integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==
dependencies:
emoji-regex "^8.0.0"
is-fullwidth-code-point "^3.0.0"
strip-ansi "^6.0.1"

string-width@^5.0.1, string-width@^5.1.2:
version "5.1.2"
resolved "https://registry.yarnpkg.com/string-width/-/string-width-5.1.2.tgz#14f8daec6d81e7221d2a357e668cab73bdbca794"
Expand Down Expand Up @@ -8608,7 +8599,7 @@ string_decoder@~1.1.1:
dependencies:
safe-buffer "~5.1.0"

"strip-ansi-cjs@npm:strip-ansi@^6.0.1":
"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.0, strip-ansi@^6.0.1:
version "6.0.1"
resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9"
integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==
Expand All @@ -8629,13 +8620,6 @@ strip-ansi@^4.0.0:
dependencies:
ansi-regex "^3.0.0"

strip-ansi@^6.0.0, strip-ansi@^6.0.1:
version "6.0.1"
resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9"
integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==
dependencies:
ansi-regex "^5.0.1"

strip-ansi@^7.0.1:
version "7.1.0"
resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-7.1.0.tgz#d5b6568ca689d8561370b0707685d22434faff45"
Expand Down Expand Up @@ -10003,7 +9987,7 @@ workerpool@^6.5.1:
resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.5.1.tgz#060f73b39d0caf97c6db64da004cd01b4c099544"
integrity sha512-Fs4dNYcsdpYSAfVxhnl1L5zTksjvOJxtC5hzMNl+1t9B8hTJTdKDyZ5ju7ztgPy+ft9tBFXoOlDNiOT9WUXZlA==

"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0":
"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0:
version "7.0.0"
resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43"
integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==
Expand All @@ -10020,15 +10004,6 @@ wrap-ansi@^2.0.0:
string-width "^1.0.1"
strip-ansi "^3.0.1"

wrap-ansi@^7.0.0:
version "7.0.0"
resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43"
integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==
dependencies:
ansi-styles "^4.0.0"
string-width "^4.1.0"
strip-ansi "^6.0.0"

wrap-ansi@^8.1.0:
version "8.1.0"
resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-8.1.0.tgz#56dc22368ee570face1b49819975d9b9a5ead214"
Expand Down
0