diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index b0e9582..0da7d2f 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -14,7 +14,7 @@ jobs: os: - ubuntu-latest node_version: - - 18 + - 20 steps: - name: Checkout diff --git a/.github/workflows/test-contracts.yml b/.github/workflows/test-contracts.yml index 508de95..286a9a1 100644 --- a/.github/workflows/test-contracts.yml +++ b/.github/workflows/test-contracts.yml @@ -17,7 +17,7 @@ jobs: os: - ubuntu-latest node_version: - - 18 + - 20 steps: - name: Checkout @@ -92,7 +92,7 @@ jobs: os: - ubuntu-latest node_version: - - 18 + - 20 steps: - name: Checkout diff --git a/README.md b/README.md index 85865bf..90254d3 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ ## Installation -It is recommended to install [`pnpm`](https://pnpm.io) through the `npm` package manager, which comes bundled with [Node.js](https://nodejs.org/en) when you install it on your system. It is recommended to use a Node.js version `>= 18.0.0`. +It is recommended to install [`pnpm`](https://pnpm.io) through the `npm` package manager, which comes bundled with [Node.js](https://nodejs.org/en) when you install it on your system. It is recommended to use a Node.js version `>= 20.0.0`. Once you have `npm` installed, you can run the following both to install and upgrade `pnpm`: diff --git a/contracts/lib/forge-std b/contracts/lib/forge-std index 80a8f6e..155d547 160000 --- a/contracts/lib/forge-std +++ b/contracts/lib/forge-std @@ -1 +1 @@ -Subproject commit 80a8f6ea9362849b2a8f2dc28df40c77a64f9c16 +Subproject commit 155d547c449afa8715f538d69454b83944117811 diff --git a/deploy/deploy-zksync.ts b/deploy/deploy-zksync.ts index 6a43c77..2e14251 100644 --- a/deploy/deploy-zksync.ts +++ b/deploy/deploy-zksync.ts @@ -3,6 +3,10 @@ import { HardhatRuntimeEnvironment } from "hardhat/types"; import { Wallet } from "zksync-ethers"; import { Deployer } from "@matterlabs/hardhat-zksync-deploy"; +// Colour codes for terminal prints +const RESET = "\x1b[0m"; +const GREEN = "\x1b[32m"; + function delay(ms: number) { return new Promise((resolve) => setTimeout(resolve, ms)); } @@ -33,8 +37,11 @@ export default async function main(hre: HardhatRuntimeEnvironment) { await contract.waitForDeployment(); const contractAddress = await contract.getAddress(); - console.log("Greeter deployed to:", contractAddress); + console.log("Greeter deployed to: " + `${GREEN}${contractAddress}${RESET}\n`); + console.log( + "Waiting 30 seconds before beginning the contract verification to allow the block explorer to index the contract...\n", + ); await delay(30000); // Wait for 30 seconds before verifying the contract await hre.run("verify:verify", { diff --git a/package.json b/package.json index 0bcfcc3..2825d6a 100644 --- a/package.json +++ b/package.json @@ -117,9 +117,9 @@ "lint:fix": "pnpm prettier:fix && pnpm solhint:fix && npx eslint **/*.{js,ts} --fix" }, "devDependencies": { - "@matterlabs/hardhat-zksync-deploy": "^1.1.0", + "@matterlabs/hardhat-zksync-deploy": "^1.1.1", "@matterlabs/hardhat-zksync-ethers": "0.0.1-beta.1", - "@matterlabs/hardhat-zksync-solc": "^1.0.3", + "@matterlabs/hardhat-zksync-solc": "^1.0.5", "@matterlabs/hardhat-zksync-verify": "^1.2.1", "@nomicfoundation/hardhat-chai-matchers": "^2.0.2", "@nomicfoundation/hardhat-ethers": "^3.0.5", @@ -135,11 +135,11 @@ "@typechain/hardhat": "^9.1.0", "@types/chai": "^4.3.11", "@types/mocha": "^10.0.6", - "@types/node": "^20.10.4", + "@types/node": "^20.10.5", "@typescript-eslint/eslint-plugin": "^6.14.0", "@typescript-eslint/parser": "^6.14.0", "chai": "^4.3.10", - "eslint": "^8.55.0", + "eslint": "^8.56.0", "eslint-config-prettier": "^9.1.0", "ethers": "^6.9.0", "hardhat": "^2.19.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 6f87b28..c9f8995 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -6,14 +6,14 @@ settings: devDependencies: "@matterlabs/hardhat-zksync-deploy": - specifier: ^1.1.0 - version: 1.1.0(ethers@6.9.0)(hardhat@2.19.2)(zksync-ethers@6.0.0) + specifier: ^1.1.1 + version: 1.1.1(ethers@6.9.0)(hardhat@2.19.2)(zksync-ethers@6.0.0) "@matterlabs/hardhat-zksync-ethers": specifier: 0.0.1-beta.1 version: 0.0.1-beta.1(ethers@6.9.0)(zksync-ethers@6.0.0) "@matterlabs/hardhat-zksync-solc": - specifier: ^1.0.3 - version: 1.0.3(hardhat@2.19.2) + specifier: ^1.0.5 + version: 1.0.5(hardhat@2.19.2) "@matterlabs/hardhat-zksync-verify": specifier: ^1.2.1 version: 1.2.1(@nomicfoundation/hardhat-verify@2.0.2)(ethers@6.9.0)(hardhat@2.19.2) @@ -34,7 +34,7 @@ devDependencies: version: 1.0.10(hardhat@2.19.2) "@nomicfoundation/hardhat-toolbox": specifier: ^4.0.0 - version: 4.0.0(@nomicfoundation/hardhat-chai-matchers@2.0.2)(@nomicfoundation/hardhat-ethers@3.0.5)(@nomicfoundation/hardhat-network-helpers@1.0.10)(@nomicfoundation/hardhat-verify@2.0.2)(@typechain/ethers-v6@0.5.1)(@typechain/hardhat@9.1.0)(@types/chai@4.3.11)(@types/mocha@10.0.6)(@types/node@20.10.4)(chai@4.3.10)(ethers@6.9.0)(hardhat-gas-reporter@1.0.9)(hardhat@2.19.2)(solidity-coverage@0.8.5)(ts-node@10.9.2)(typechain@8.3.2)(typescript@5.3.3) + version: 4.0.0(@nomicfoundation/hardhat-chai-matchers@2.0.2)(@nomicfoundation/hardhat-ethers@3.0.5)(@nomicfoundation/hardhat-network-helpers@1.0.10)(@nomicfoundation/hardhat-verify@2.0.2)(@typechain/ethers-v6@0.5.1)(@typechain/hardhat@9.1.0)(@types/chai@4.3.11)(@types/mocha@10.0.6)(@types/node@20.10.5)(chai@4.3.10)(ethers@6.9.0)(hardhat-gas-reporter@1.0.9)(hardhat@2.19.2)(solidity-coverage@0.8.5)(ts-node@10.9.2)(typechain@8.3.2)(typescript@5.3.3) "@nomicfoundation/hardhat-verify": specifier: ^2.0.2 version: 2.0.2(hardhat@2.19.2) @@ -43,7 +43,7 @@ devDependencies: version: 5.0.1 "@tenderly/hardhat-tenderly": specifier: ^2.0.1 - version: 2.0.1(@types/node@20.10.4)(ethers@6.9.0)(hardhat@2.19.2) + version: 2.0.1(@types/node@20.10.5)(ethers@6.9.0)(hardhat@2.19.2) "@truffle/dashboard-hardhat-plugin": specifier: ^0.2.15 version: 0.2.15(hardhat@2.19.2) @@ -60,23 +60,23 @@ devDependencies: specifier: ^10.0.6 version: 10.0.6 "@types/node": - specifier: ^20.10.4 - version: 20.10.4 + specifier: ^20.10.5 + version: 20.10.5 "@typescript-eslint/eslint-plugin": specifier: ^6.14.0 - version: 6.14.0(@typescript-eslint/parser@6.14.0)(eslint@8.55.0)(typescript@5.3.3) + version: 6.14.0(@typescript-eslint/parser@6.14.0)(eslint@8.56.0)(typescript@5.3.3) "@typescript-eslint/parser": specifier: ^6.14.0 - version: 6.14.0(eslint@8.55.0)(typescript@5.3.3) + version: 6.14.0(eslint@8.56.0)(typescript@5.3.3) chai: specifier: ^4.3.10 version: 4.3.10 eslint: - specifier: ^8.55.0 - version: 8.55.0 + specifier: ^8.56.0 + version: 8.56.0 eslint-config-prettier: specifier: ^9.1.0 - version: 9.1.0(eslint@8.55.0) + version: 9.1.0(eslint@8.56.0) ethers: specifier: ^6.9.0 version: 6.9.0 @@ -106,7 +106,7 @@ devDependencies: version: 0.8.5(hardhat@2.19.2) ts-node: specifier: ^10.9.2 - version: 10.9.2(@types/node@20.10.4)(typescript@5.3.3) + version: 10.9.2(@types/node@20.10.5)(typescript@5.3.3) typechain: specifier: ^8.3.2 version: 8.3.2(typescript@5.3.3) @@ -174,7 +174,7 @@ packages: } engines: { node: ">=6.9.0" } dependencies: - regenerator-runtime: 0.14.0 + regenerator-runtime: 0.14.1 dev: true /@balena/dockerignore@1.0.2: @@ -250,7 +250,7 @@ packages: "@jridgewell/trace-mapping": 0.3.9 dev: true - /@eslint-community/eslint-utils@4.4.0(eslint@8.55.0): + /@eslint-community/eslint-utils@4.4.0(eslint@8.56.0): resolution: { integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==, @@ -259,7 +259,7 @@ packages: peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 dependencies: - eslint: 8.55.0 + eslint: 8.56.0 eslint-visitor-keys: 3.4.3 dev: true @@ -291,10 +291,10 @@ packages: - supports-color dev: true - /@eslint/js@8.55.0: + /@eslint/js@8.56.0: resolution: { - integrity: sha512-qQfo2mxH5yVom1kacMtZZJFVdW+E70mqHMJvVg6WTLo+VBuQJ4TojZlfWBjK0ve5BdEeNAVxOsl/nvNMpJOaJA==, + integrity: sha512-gMsVel9D7f2HLkBma9VbtzZRehRogVRfbr++f06nL2vnCGCNlzOD+/MUov/F4p8myyAHspEhVobgjpX64q5m6A==, } engines: { node: ^12.22.0 || ^14.17.0 || >=16.0.0 } dev: true @@ -816,27 +816,27 @@ packages: invariant: 2.2.4 dev: true - /@ledgerhq/devices@8.1.0: + /@ledgerhq/devices@8.2.0: resolution: { - integrity: sha512-Vsdv84Nwzee0qhObdwVzhkxW1+h2cFoD1AWuU8N1V/2OJKiVS35A1qloSCF0oHapg+KTJvim8tr5rRvlkCYyzQ==, + integrity: sha512-XROTW2gTmmuy+YPPDjdtKKTQ3mfxrPtKtV+a9QFbj8f5MnjVMV0Zpy1BIB4CyIMsVVi4z6+nI67auT7IlsM3SQ==, } dependencies: - "@ledgerhq/errors": 6.16.0 + "@ledgerhq/errors": 6.16.1 "@ledgerhq/logs": 6.12.0 rxjs: 7.8.1 semver: 7.5.4 dev: true - /@ledgerhq/domain-service@1.1.15(debug@4.3.4): + /@ledgerhq/domain-service@1.1.16(debug@4.3.4): resolution: { - integrity: sha512-1X4MvNhVDTXCfOQckaUHsq/Qzn8xhFMcHjnLKOuCR5zNB8hYuTyg9e7JXURZ8W7/Qcn41rvIPxXBHwvMjWQBMA==, + integrity: sha512-ovdYTrostrbQl5SnKoUw4BeYfLRfBSe7S0zEV9MHo3MlSHI0H4sfcpfM7g8CXybwOg/xHaP9uKm4Mlbg7JNxrg==, } dependencies: - "@ledgerhq/errors": 6.16.0 + "@ledgerhq/errors": 6.16.1 "@ledgerhq/logs": 6.12.0 - "@ledgerhq/types-live": 6.43.0 + "@ledgerhq/types-live": 6.43.1 axios: 1.6.2(debug@4.3.4) eip55: 2.1.1 react: 18.2.0 @@ -845,10 +845,10 @@ packages: - debug dev: true - /@ledgerhq/errors@6.16.0: + /@ledgerhq/errors@6.16.1: resolution: { - integrity: sha512-vnew6lf4jN6E+WI0DFhD4WY0uM8LYL8HCumtUr86hNwvmEfebi7LxxpJGmYfVQD5TgEC7NibYnQ+2q9XWAc02A==, + integrity: sha512-4D4wKecGzQpIu7sx03Sg4uE1e8g1oZUndWgw9gw776H8h9ov9c5TxPaldTn2j6orPECAERViLf7LTO4L5pE2Cw==, } dev: true @@ -861,10 +861,10 @@ packages: "@ethersproject/abi": 5.7.0 "@ethersproject/rlp": 5.7.0 "@ledgerhq/cryptoassets": 9.13.0 - "@ledgerhq/domain-service": 1.1.15(debug@4.3.4) - "@ledgerhq/errors": 6.16.0 - "@ledgerhq/hw-transport": 6.30.0 - "@ledgerhq/hw-transport-mocker": 6.28.0 + "@ledgerhq/domain-service": 1.1.16(debug@4.3.4) + "@ledgerhq/errors": 6.16.1 + "@ledgerhq/hw-transport": 6.30.1 + "@ledgerhq/hw-transport-mocker": 6.28.1 "@ledgerhq/logs": 6.12.0 axios: 1.6.2(debug@4.3.4) bignumber.js: 9.1.2 @@ -873,54 +873,54 @@ packages: - debug dev: true - /@ledgerhq/hw-transport-mocker@6.28.0: + /@ledgerhq/hw-transport-mocker@6.28.1: resolution: { - integrity: sha512-svUgIRdoc69b49MHncKikoRgWIqn7ZR3IHP+nq4TCTYn2nm5LILJYyf8osnCg8brsXdEY68z++fr++GyF9vUIw==, + integrity: sha512-o2psew3qYp1O7Bh3qCdktGxm5HqVl3RHFl1zzxUOSr4i3nxvLhGvm0Ku/5tFLRjaxVwmSo6f7pBN9o+rOpcrNg==, } dependencies: - "@ledgerhq/hw-transport": 6.30.0 + "@ledgerhq/hw-transport": 6.30.1 "@ledgerhq/logs": 6.12.0 rxjs: 7.8.1 dev: true - /@ledgerhq/hw-transport-node-hid-noevents@6.29.0: + /@ledgerhq/hw-transport-node-hid-noevents@6.29.1: resolution: { - integrity: sha512-JJM0NGOmFxCJ0IvbGlCo3KHYhkckn7QPNgBlGTrV/UDoMZdtDfp3R971jGUVInUmqYmHRDCGXRpjwgZRI7MJhg==, + integrity: sha512-eJms10MVMlWQHLrseyThZ5rrVSVRr/fRmqiHsbldprK2Xh3hl9BFp7gCJ7W8BJe8WxrndkztgRvf2ZLknb8+/Q==, } dependencies: - "@ledgerhq/devices": 8.1.0 - "@ledgerhq/errors": 6.16.0 - "@ledgerhq/hw-transport": 6.30.0 + "@ledgerhq/devices": 8.2.0 + "@ledgerhq/errors": 6.16.1 + "@ledgerhq/hw-transport": 6.30.1 "@ledgerhq/logs": 6.12.0 node-hid: 2.2.0 dev: true - /@ledgerhq/hw-transport-node-hid@6.28.0: + /@ledgerhq/hw-transport-node-hid@6.28.1: resolution: { - integrity: sha512-kRGsT9YkudP8TbiaBWOtpgMje3gp7CbNHgAA4gdGM5Xri5Li0foEoIFqYZfWCS44NrPbDrsalWqj03HmQ2LDpg==, + integrity: sha512-9aM9qVXMq/GLjYg3qm+LuzIdgbdihFhyrKb7mVDXyuUlu2f4JeGGrCnF+DfSXTMuGIMRJ8W6I/2yrO1CcB3sIA==, } dependencies: - "@ledgerhq/devices": 8.1.0 - "@ledgerhq/errors": 6.16.0 - "@ledgerhq/hw-transport": 6.30.0 - "@ledgerhq/hw-transport-node-hid-noevents": 6.29.0 + "@ledgerhq/devices": 8.2.0 + "@ledgerhq/errors": 6.16.1 + "@ledgerhq/hw-transport": 6.30.1 + "@ledgerhq/hw-transport-node-hid-noevents": 6.29.1 "@ledgerhq/logs": 6.12.0 lodash: 4.17.21 node-hid: 2.2.0 usb: 2.9.0 dev: true - /@ledgerhq/hw-transport@6.30.0: + /@ledgerhq/hw-transport@6.30.1: resolution: { - integrity: sha512-wrAwn/wCAaGP2Yuy78cLyqmQNzbuDvUv4gJYF/UO4djvUz0jjvD2w5kxRWxF/W93vyKT+/RplRtFk3CJzD3e3A==, + integrity: sha512-Xeeo4nt33g5Fsp3CdsPvcc2Uk7dwYeKRSlSFLWcYAAKprf/PmxgNekhke1eaNU/wLoeLOWhY2Cki8F8w9nLMdQ==, } dependencies: - "@ledgerhq/devices": 8.1.0 - "@ledgerhq/errors": 6.16.0 + "@ledgerhq/devices": 8.2.0 + "@ledgerhq/errors": 6.16.1 "@ledgerhq/logs": 6.12.0 events: 3.3.0 dev: true @@ -932,27 +932,27 @@ packages: } dev: true - /@ledgerhq/types-live@6.43.0: + /@ledgerhq/types-live@6.43.1: resolution: { - integrity: sha512-NvSWPefZ54BLTTMdljO2eS3j1Jbj4O+j/2OWZfyt6T1qMrU1OwORkIn7weuyqR0Y01mTos0sjST7r10MqtauJg==, + integrity: sha512-XaDACXAULFmY95scTmZNOaQMxiqmdj3kEhPRA3aDcB8VA8jzjK0+nrNx6qWNZbH3tgo1xj8gwz7bdmPoOgrqfg==, } dependencies: bignumber.js: 9.1.2 rxjs: 7.8.1 dev: true - /@matterlabs/hardhat-zksync-deploy@1.1.0(ethers@6.9.0)(hardhat@2.19.2)(zksync-ethers@6.0.0): + /@matterlabs/hardhat-zksync-deploy@1.1.1(ethers@6.9.0)(hardhat@2.19.2)(zksync-ethers@6.0.0): resolution: { - integrity: sha512-pmIjmSXpoue24FsI0xhMR1H4b0nStayVOQA209tw9x9c6X5Q/1Dj+o00U2To70glVfPQ1B1hP9ay30x8pxzJ7A==, + integrity: sha512-THPXZ08ejcvr0NzqnmNARxk0VaLnQaxA6qzfh9re2pVWe1Ch6YH7kDpHYvVNafp2HINtOE9bVzzd7OOp73/wvw==, } peerDependencies: ethers: ^6.7.1 hardhat: ^2.18.1 zksync-ethers: ^6.0.0 dependencies: - "@matterlabs/hardhat-zksync-solc": 1.0.3(hardhat@2.19.2) + "@matterlabs/hardhat-zksync-solc": 1.0.5(hardhat@2.19.2) chalk: 4.1.2 ethers: 6.9.0 hardhat: 2.19.2(ts-node@10.9.2)(typescript@5.3.3) @@ -977,10 +977,10 @@ packages: zksync-ethers: 6.0.0(ethers@6.9.0) dev: true - /@matterlabs/hardhat-zksync-solc@1.0.3(hardhat@2.19.2): + /@matterlabs/hardhat-zksync-solc@1.0.5(hardhat@2.19.2): resolution: { - integrity: sha512-+cyCAL3YmuKpli75evFXMK1eals9rQKVaU+4B74HMOnkMJFt8nH2Oh2KZYlqf8yVCRTPI//xn9VOD93z7REu3w==, + integrity: sha512-IBWvbGJSISNtWIz/4VBfV1NweVYK7xHmy787o6fDjntxP5P4XEklTJU3/pNBQdL5fZbIrQqMmXFMOwUXnuEY6Q==, } peerDependencies: hardhat: ^2.18.1 @@ -1005,7 +1005,7 @@ packages: peerDependencies: "@nomicfoundation/hardhat-verify": ^2.0.0 dependencies: - "@matterlabs/hardhat-zksync-solc": 1.0.3(hardhat@2.19.2) + "@matterlabs/hardhat-zksync-solc": 1.0.5(hardhat@2.19.2) "@nomicfoundation/hardhat-verify": 2.0.2(hardhat@2.19.2) axios: 1.6.2(debug@4.3.4) chalk: 4.1.2 @@ -1380,10 +1380,10 @@ packages: peerDependencies: hardhat: ^2.16.0 dependencies: - "@ledgerhq/errors": 6.16.0 + "@ledgerhq/errors": 6.16.1 "@ledgerhq/hw-app-eth": 6.33.6(debug@4.3.4) - "@ledgerhq/hw-transport": 6.30.0 - "@ledgerhq/hw-transport-node-hid": 6.28.0 + "@ledgerhq/hw-transport": 6.30.1 + "@ledgerhq/hw-transport-node-hid": 6.28.1 "@nomicfoundation/ethereumjs-util": 9.0.1 chalk: 2.4.2 debug: 4.3.4(supports-color@8.1.1) @@ -1411,7 +1411,7 @@ packages: hardhat: 2.19.2(ts-node@10.9.2)(typescript@5.3.3) dev: true - /@nomicfoundation/hardhat-toolbox@4.0.0(@nomicfoundation/hardhat-chai-matchers@2.0.2)(@nomicfoundation/hardhat-ethers@3.0.5)(@nomicfoundation/hardhat-network-helpers@1.0.10)(@nomicfoundation/hardhat-verify@2.0.2)(@typechain/ethers-v6@0.5.1)(@typechain/hardhat@9.1.0)(@types/chai@4.3.11)(@types/mocha@10.0.6)(@types/node@20.10.4)(chai@4.3.10)(ethers@6.9.0)(hardhat-gas-reporter@1.0.9)(hardhat@2.19.2)(solidity-coverage@0.8.5)(ts-node@10.9.2)(typechain@8.3.2)(typescript@5.3.3): + /@nomicfoundation/hardhat-toolbox@4.0.0(@nomicfoundation/hardhat-chai-matchers@2.0.2)(@nomicfoundation/hardhat-ethers@3.0.5)(@nomicfoundation/hardhat-network-helpers@1.0.10)(@nomicfoundation/hardhat-verify@2.0.2)(@typechain/ethers-v6@0.5.1)(@typechain/hardhat@9.1.0)(@types/chai@4.3.11)(@types/mocha@10.0.6)(@types/node@20.10.5)(chai@4.3.10)(ethers@6.9.0)(hardhat-gas-reporter@1.0.9)(hardhat@2.19.2)(solidity-coverage@0.8.5)(ts-node@10.9.2)(typechain@8.3.2)(typescript@5.3.3): resolution: { integrity: sha512-jhcWHp0aHaL0aDYj8IJl80v4SZXWMS1A2XxXa1CA6pBiFfJKuZinCkO6wb+POAt0LIfXB3gA3AgdcOccrcwBwA==, @@ -1443,13 +1443,13 @@ packages: "@typechain/hardhat": 9.1.0(@typechain/ethers-v6@0.5.1)(ethers@6.9.0)(hardhat@2.19.2)(typechain@8.3.2) "@types/chai": 4.3.11 "@types/mocha": 10.0.6 - "@types/node": 20.10.4 + "@types/node": 20.10.5 chai: 4.3.10 ethers: 6.9.0 hardhat: 2.19.2(ts-node@10.9.2)(typescript@5.3.3) hardhat-gas-reporter: 1.0.9(hardhat@2.19.2) solidity-coverage: 0.8.5(hardhat@2.19.2) - ts-node: 10.9.2(@types/node@20.10.4)(typescript@5.3.3) + ts-node: 10.9.2(@types/node@20.10.5)(typescript@5.3.3) typechain: 8.3.2(typescript@5.3.3) typescript: 5.3.3 dev: true @@ -1666,10 +1666,10 @@ packages: config-chain: 1.1.13 dev: true - /@scure/base@1.1.4: + /@scure/base@1.1.5: resolution: { - integrity: sha512-wznebWtt+ejH8el87yuD4i9xLSbYZXf1Pe4DY0o/zq/eg5I0VQVXVbFs6XIM0pNVCJ/uE3t5wI9kh90mdLUxtw==, + integrity: sha512-Brj9FiG2W1MRQSTB212YVPRrcbjkv48FoZi/u4l/zds/ieRrqsh7aUf6CLwkAq61oKXr/ZlTzlY66gLIj3TFTQ==, } dev: true @@ -1681,7 +1681,7 @@ packages: dependencies: "@noble/hashes": 1.2.0 "@noble/secp256k1": 1.7.1 - "@scure/base": 1.1.4 + "@scure/base": 1.1.5 dev: true /@scure/bip32@1.3.1: @@ -1692,7 +1692,7 @@ packages: dependencies: "@noble/curves": 1.1.0 "@noble/hashes": 1.3.1 - "@scure/base": 1.1.4 + "@scure/base": 1.1.5 dev: true /@scure/bip39@1.1.1: @@ -1702,7 +1702,7 @@ packages: } dependencies: "@noble/hashes": 1.2.0 - "@scure/base": 1.1.4 + "@scure/base": 1.1.5 dev: true /@scure/bip39@1.2.1: @@ -1712,7 +1712,7 @@ packages: } dependencies: "@noble/hashes": 1.3.1 - "@scure/base": 1.1.4 + "@scure/base": 1.1.5 dev: true /@sentry/core@5.30.0: @@ -1860,7 +1860,7 @@ packages: defer-to-connect: 2.0.1 dev: true - /@tenderly/hardhat-tenderly@2.0.1(@types/node@20.10.4)(ethers@6.9.0)(hardhat@2.19.2): + /@tenderly/hardhat-tenderly@2.0.1(@types/node@20.10.5)(ethers@6.9.0)(hardhat@2.19.2): resolution: { integrity: sha512-MaVq7UuWvsyqstya5wVwDc5ml5xo1pAS9PRQQZWhg/f6ats3KFboi9BP18Yhypjh4bPw2NPZOBip9u1lV0oaGw==, @@ -1875,9 +1875,9 @@ packages: ethers: 6.9.0 fs-extra: 10.1.0 hardhat: 2.19.2(ts-node@10.9.2)(typescript@5.3.3) - hardhat-deploy: 0.11.44 + hardhat-deploy: 0.11.45 tenderly: 0.7.0(ts-node@10.9.2)(typescript@5.3.3) - ts-node: 10.9.2(@types/node@20.10.4)(typescript@5.3.3) + ts-node: 10.9.2(@types/node@20.10.5)(typescript@5.3.3) tslog: 4.9.2 typescript: 5.3.3 transitivePeerDependencies: @@ -2229,7 +2229,7 @@ packages: integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==, } dependencies: - "@types/node": 20.10.4 + "@types/node": 20.10.5 dev: true /@types/bn.js@5.1.5: @@ -2238,7 +2238,7 @@ packages: integrity: sha512-V46N0zwKRF5Q00AZ6hWtN0T8gGmDUaUzLWQvHFo5yThtVwK/VCenFY3wXVbOvNfajEpsTfQM4IN9k/d6gUVX3A==, } dependencies: - "@types/node": 20.10.4 + "@types/node": 20.10.5 dev: true /@types/cacheable-request@6.0.3: @@ -2249,7 +2249,7 @@ packages: dependencies: "@types/http-cache-semantics": 4.0.4 "@types/keyv": 3.1.4 - "@types/node": 20.10.4 + "@types/node": 20.10.5 "@types/responselike": 1.0.3 dev: true @@ -2275,7 +2275,7 @@ packages: integrity: sha512-eHE4cQPoj6ngxBZMvVf6Hw7Mh4jMW4U9lpGmS5GBPB9RYxlFg+CHaVN7ErNY4W9XfLIEn20b4VDYaIrbq0q4uA==, } dependencies: - "@types/node": 20.10.4 + "@types/node": 20.10.5 dev: true /@types/form-data@0.0.33: @@ -2284,7 +2284,7 @@ packages: integrity: sha512-8BSvG1kGm83cyJITQMZSulnl6QV8jqAGreJsc5tPu1Jq0vTSOiY/k24Wx82JRpWwZSqrala6sd5rWi6aNXvqcw==, } dependencies: - "@types/node": 20.10.4 + "@types/node": 20.10.5 dev: true /@types/glob@7.2.0: @@ -2294,7 +2294,7 @@ packages: } dependencies: "@types/minimatch": 5.1.2 - "@types/node": 20.10.4 + "@types/node": 20.10.5 dev: true /@types/http-cache-semantics@4.0.4: @@ -2317,7 +2317,7 @@ packages: integrity: sha512-BQ5aZNSCpj7D6K2ksrRCTmKRLEpnPvWDiLPfoGyhZ++8YtiK9d/3DBKPJgry359X/P1PfruyYwvnvwFjuEiEIg==, } dependencies: - "@types/node": 20.10.4 + "@types/node": 20.10.5 dev: true /@types/lru-cache@5.1.1: @@ -2362,10 +2362,10 @@ packages: } dev: true - /@types/node@20.10.4: + /@types/node@20.10.5: resolution: { - integrity: sha512-D08YG6rr8X90YB56tSIuBaddy/UXAA9RKJoFvrsnogAum/0pmjkgi4+2nx96A330FmioegBWmEYQ+syqCFaveg==, + integrity: sha512-nNPsNE65wjMxEKI93yOP+NPGGBJz/PoN3kZsVLee0XMiJolxSekEVD8wRwBUBqkwc7UWop0edW50yrCQW4CyRw==, } dependencies: undici-types: 5.26.5 @@ -2384,7 +2384,7 @@ packages: integrity: sha512-uRwJqmiXmh9++aSu1VNEn3iIxWOhd8AHXNSdlaLfdAAdSTY9jYVeGWnzejM3dvrkbqE3/hyQkQQ29IFATEGlew==, } dependencies: - "@types/node": 20.10.4 + "@types/node": 20.10.5 dev: true /@types/prettier@2.7.3: @@ -2407,7 +2407,7 @@ packages: integrity: sha512-oM5JSKQCcICF1wvGgmecmHldZ48OZamtMxcGGVICOJA8o8cahXC1zEVAif8iwoc5j8etxFaRFnf095+CDsuoFQ==, } dependencies: - "@types/node": 20.10.4 + "@types/node": 20.10.5 safe-buffer: 5.1.2 dev: true @@ -2417,7 +2417,7 @@ packages: integrity: sha512-H/+L+UkTV33uf49PH5pCAUBVPNj2nDBXTN+qS1dOwyyg24l3CcicicCA7ca+HMvJBZcFgl5r8e+RR6elsb4Lyw==, } dependencies: - "@types/node": 20.10.4 + "@types/node": 20.10.5 dev: true /@types/secp256k1@4.0.6: @@ -2426,7 +2426,7 @@ packages: integrity: sha512-hHxJU6PAEUn0TP4S/ZOzuTUvJWuZ6eIKeNKb5RBpODvSl6hp1Wrw4s7ATY50rklRCScUDpHzVA/DQdSjJ3UoYQ==, } dependencies: - "@types/node": 20.10.4 + "@types/node": 20.10.5 dev: true /@types/semver@7.5.6: @@ -2443,7 +2443,7 @@ packages: } dev: true - /@typescript-eslint/eslint-plugin@6.14.0(@typescript-eslint/parser@6.14.0)(eslint@8.55.0)(typescript@5.3.3): + /@typescript-eslint/eslint-plugin@6.14.0(@typescript-eslint/parser@6.14.0)(eslint@8.56.0)(typescript@5.3.3): resolution: { integrity: sha512-1ZJBykBCXaSHG94vMMKmiHoL0MhNHKSVlcHVYZNw+BKxufhqQVTOawNpwwI1P5nIFZ/4jLVop0mcY6mJJDFNaw==, @@ -2458,13 +2458,13 @@ packages: optional: true dependencies: "@eslint-community/regexpp": 4.10.0 - "@typescript-eslint/parser": 6.14.0(eslint@8.55.0)(typescript@5.3.3) + "@typescript-eslint/parser": 6.14.0(eslint@8.56.0)(typescript@5.3.3) "@typescript-eslint/scope-manager": 6.14.0 - "@typescript-eslint/type-utils": 6.14.0(eslint@8.55.0)(typescript@5.3.3) - "@typescript-eslint/utils": 6.14.0(eslint@8.55.0)(typescript@5.3.3) + "@typescript-eslint/type-utils": 6.14.0(eslint@8.56.0)(typescript@5.3.3) + "@typescript-eslint/utils": 6.14.0(eslint@8.56.0)(typescript@5.3.3) "@typescript-eslint/visitor-keys": 6.14.0 debug: 4.3.4(supports-color@8.1.1) - eslint: 8.55.0 + eslint: 8.56.0 graphemer: 1.4.0 ignore: 5.3.0 natural-compare: 1.4.0 @@ -2475,7 +2475,7 @@ packages: - supports-color dev: true - /@typescript-eslint/parser@6.14.0(eslint@8.55.0)(typescript@5.3.3): + /@typescript-eslint/parser@6.14.0(eslint@8.56.0)(typescript@5.3.3): resolution: { integrity: sha512-QjToC14CKacd4Pa7JK4GeB/vHmWFJckec49FR4hmIRf97+KXole0T97xxu9IFiPxVQ1DBWrQ5wreLwAGwWAVQA==, @@ -2493,7 +2493,7 @@ packages: "@typescript-eslint/typescript-estree": 6.14.0(typescript@5.3.3) "@typescript-eslint/visitor-keys": 6.14.0 debug: 4.3.4(supports-color@8.1.1) - eslint: 8.55.0 + eslint: 8.56.0 typescript: 5.3.3 transitivePeerDependencies: - supports-color @@ -2510,7 +2510,7 @@ packages: "@typescript-eslint/visitor-keys": 6.14.0 dev: true - /@typescript-eslint/type-utils@6.14.0(eslint@8.55.0)(typescript@5.3.3): + /@typescript-eslint/type-utils@6.14.0(eslint@8.56.0)(typescript@5.3.3): resolution: { integrity: sha512-x6OC9Q7HfYKqjnuNu5a7kffIYs3No30isapRBJl1iCHLitD8O0lFbRcVGiOcuyN837fqXzPZ1NS10maQzZMKqw==, @@ -2524,9 +2524,9 @@ packages: optional: true dependencies: "@typescript-eslint/typescript-estree": 6.14.0(typescript@5.3.3) - "@typescript-eslint/utils": 6.14.0(eslint@8.55.0)(typescript@5.3.3) + "@typescript-eslint/utils": 6.14.0(eslint@8.56.0)(typescript@5.3.3) debug: 4.3.4(supports-color@8.1.1) - eslint: 8.55.0 + eslint: 8.56.0 ts-api-utils: 1.0.3(typescript@5.3.3) typescript: 5.3.3 transitivePeerDependencies: @@ -2565,7 +2565,7 @@ packages: - supports-color dev: true - /@typescript-eslint/utils@6.14.0(eslint@8.55.0)(typescript@5.3.3): + /@typescript-eslint/utils@6.14.0(eslint@8.56.0)(typescript@5.3.3): resolution: { integrity: sha512-XwRTnbvRr7Ey9a1NT6jqdKX8y/atWG+8fAIu3z73HSP8h06i3r/ClMhmaF/RGWGW1tHJEwij1uEg2GbEmPYvYg==, @@ -2574,13 +2574,13 @@ packages: peerDependencies: eslint: ^7.0.0 || ^8.0.0 dependencies: - "@eslint-community/eslint-utils": 4.4.0(eslint@8.55.0) + "@eslint-community/eslint-utils": 4.4.0(eslint@8.56.0) "@types/json-schema": 7.0.15 "@types/semver": 7.5.6 "@typescript-eslint/scope-manager": 6.14.0 "@typescript-eslint/types": 6.14.0 "@typescript-eslint/typescript-estree": 6.14.0(typescript@5.3.3) - eslint: 8.55.0 + eslint: 8.56.0 semver: 7.5.4 transitivePeerDependencies: - supports-color @@ -4727,7 +4727,7 @@ packages: source-map: 0.2.0 dev: true - /eslint-config-prettier@9.1.0(eslint@8.55.0): + /eslint-config-prettier@9.1.0(eslint@8.56.0): resolution: { integrity: sha512-NSWl5BFQWEPi1j4TjVNItzYV7dZXZ+wP6I6ZhrBGpChQhZRUaElihE9uRRkcbRnNb76UMKDF3r+WTmNcGPKsqw==, @@ -4736,7 +4736,7 @@ packages: peerDependencies: eslint: ">=7.0.0" dependencies: - eslint: 8.55.0 + eslint: 8.56.0 dev: true /eslint-scope@7.2.2: @@ -4758,18 +4758,18 @@ packages: engines: { node: ^12.22.0 || ^14.17.0 || >=16.0.0 } dev: true - /eslint@8.55.0: + /eslint@8.56.0: resolution: { - integrity: sha512-iyUUAM0PCKj5QpwGfmCAG9XXbZCWsqP/eWAWrG/W0umvjuLRBECwSFdt+rCntju0xEH7teIABPwXpahftIaTdA==, + integrity: sha512-Go19xM6T9puCOWntie1/P997aXxFsOi37JIHRWI514Hc6ZnaHGKY9xFhrU65RT6CcBEzZoGG1e6Nq+DT04ZtZQ==, } engines: { node: ^12.22.0 || ^14.17.0 || >=16.0.0 } hasBin: true dependencies: - "@eslint-community/eslint-utils": 4.4.0(eslint@8.55.0) + "@eslint-community/eslint-utils": 4.4.0(eslint@8.56.0) "@eslint-community/regexpp": 4.10.0 "@eslint/eslintrc": 2.1.4 - "@eslint/js": 8.55.0 + "@eslint/js": 8.56.0 "@humanwhocodes/config-array": 0.11.13 "@humanwhocodes/module-importer": 1.0.1 "@nodelib/fs.walk": 1.2.8 @@ -6076,10 +6076,10 @@ packages: strip-ansi: 6.0.1 dev: true - /hardhat-deploy@0.11.44: + /hardhat-deploy@0.11.45: resolution: { - integrity: sha512-kAkCvTYPpdIvnWCc3F0xg3AbVsa/SgH9aePPO7e7nHUOkg07LGKuknU/UaVAfWwHe7Zs57pQIAolAQyKI+mnXw==, + integrity: sha512-aC8UNaq3JcORnEUIwV945iJuvBwi65tjHVDU3v6mOcqik7WAzHVCJ7cwmkkipsHrWysrB5YvGF1q9S1vIph83w==, } dependencies: "@ethersproject/abi": 5.7.0 @@ -6190,7 +6190,7 @@ packages: solc: 0.7.3(debug@4.3.4) source-map-support: 0.5.21 stacktrace-parser: 0.1.10 - ts-node: 10.9.2(@types/node@20.10.4)(typescript@5.3.3) + ts-node: 10.9.2(@types/node@20.10.5)(typescript@5.3.3) tsort: 0.0.1 typescript: 5.3.3 undici: 5.28.2 @@ -8745,10 +8745,10 @@ packages: engines: { node: ">=6" } dev: true - /regenerator-runtime@0.14.0: + /regenerator-runtime@0.14.1: resolution: { - integrity: sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA==, + integrity: sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==, } dev: true @@ -9878,7 +9878,7 @@ packages: js-yaml: 4.1.0 open: 8.4.2 prompts: 2.4.2 - ts-node: 10.9.2(@types/node@20.10.4)(typescript@5.3.3) + ts-node: 10.9.2(@types/node@20.10.5)(typescript@5.3.3) tslog: 4.9.2 typescript: 5.3.3 transitivePeerDependencies: @@ -10033,7 +10033,7 @@ packages: code-block-writer: 12.0.0 dev: true - /ts-node@10.9.2(@types/node@20.10.4)(typescript@5.3.3): + /ts-node@10.9.2(@types/node@20.10.5)(typescript@5.3.3): resolution: { integrity: sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==, @@ -10055,7 +10055,7 @@ packages: "@tsconfig/node12": 1.0.11 "@tsconfig/node14": 1.0.3 "@tsconfig/node16": 1.0.4 - "@types/node": 20.10.4 + "@types/node": 20.10.5 acorn: 8.11.2 acorn-walk: 8.3.1 arg: 4.1.3 diff --git a/scripts/deploy.ts b/scripts/deploy.ts index 54a9f2d..d9fa33f 100644 --- a/scripts/deploy.ts +++ b/scripts/deploy.ts @@ -1,5 +1,9 @@ import hre from "hardhat"; +// Colour codes for terminal prints +const RESET = "\x1b[0m"; +const GREEN = "\x1b[32m"; + function delay(ms: number) { return new Promise((resolve) => setTimeout(resolve, ms)); } @@ -11,8 +15,11 @@ async function main() { await contract.waitForDeployment(); const contractAddress = await contract.getAddress(); - console.log("Greeter deployed to:", contractAddress); + console.log("Greeter deployed to: " + `${GREEN}${contractAddress}${RESET}\n`); + console.log( + "Waiting 30 seconds before beginning the contract verification to allow the block explorer to index the contract...\n", + ); await delay(30000); // Wait for 30 seconds before verifying the contract await hre.run("verify:verify", { diff --git a/scripts/interact.ts b/scripts/interact.ts index 48bdc9a..fc19094 100644 --- a/scripts/interact.ts +++ b/scripts/interact.ts @@ -2,8 +2,12 @@ // You must customise it according to your contract's specifications import hre from "hardhat"; +// Colour codes for terminal prints +const RESET = "\x1b[0m"; +const GREEN = "\x1b[32m"; + async function main() { - const address = "0xdFf511FC04478a2fdEc2Efb93D92C4C6a55911EE"; // Specify here your contract address + const address = "0xB8d2BDd1C99A33b831553DA64F6215983bf0475a"; // Specify here your contract address const contract = await hre.ethers.getContractAt("Greeter", address); // Specify here your contract name //////////////// @@ -17,7 +21,8 @@ async function main() { ////////////// const tx = await contract.setGreeting(newGreeting); // Specify here the to-be-called function name - console.log("The transaction hash is:", tx.hash); + console.log("The transaction hash is: " + `${GREEN}${tx.hash}${RESET}\n`); + console.log("Waiting until the transaction is confirmed...\n"); const receipt = await tx.wait(); // Wait until the transaction is confirmed console.log( "The transaction returned the following transaction receipt:\n",