From d3cd915bba59b22694a0578e51e3b6334ea5b0c8 Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Thu, 1 Feb 2024 11:58:44 -0300 Subject: [PATCH 01/12] update addresses --- packages/zeta-app-contracts/data/addresses.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/zeta-app-contracts/data/addresses.json b/packages/zeta-app-contracts/data/addresses.json index 4541ca49..4d912ce9 100644 --- a/packages/zeta-app-contracts/data/addresses.json +++ b/packages/zeta-app-contracts/data/addresses.json @@ -8,7 +8,7 @@ }, "bsc_mainnet": { "multiChainSwap": "", - "multiChainValue": "", + "multiChainValue": "0x33e5fCFfe910B99DB46c259804fCA1317EA0Aa89", "zetaTokenConsumerUniV2": "", "zetaTokenConsumerUniV3": "" }, @@ -26,7 +26,7 @@ }, "eth_mainnet": { "multiChainSwap": "", - "multiChainValue": "", + "multiChainValue": "0x910966E1C0Bc9FD74f499723c19Ff9799fE258a5", "zetaTokenConsumerUniV2": "", "zetaTokenConsumerUniV3": "" }, From 5daba4df77b52b32af0f8994bdf447d22dcff5b3 Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Thu, 1 Feb 2024 14:27:56 -0300 Subject: [PATCH 02/12] feat: withdrawerc20 --- .../contracts/withdrawErc20/withdrawErc20.sol | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol diff --git a/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol b/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol new file mode 100644 index 00000000..115dc0f1 --- /dev/null +++ b/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.7; + +import "@zetachain/protocol-contracts/contracts/zevm/SystemContract.sol"; +import "@zetachain/toolkit/contracts/SwapHelperLib.sol"; + +contract WithdrawERC20 { + SystemContract public immutable systemContract; + + constructor(address systemContractAddress) { + systemContract = SystemContract(systemContractAddress); + } + + function withdraw(address zrc20, uint256 amount, bytes memory to) external virtual { + IZRC20(zrc20).transferFrom(msg.sender, address(this), amount); + + (address gasZRC20, uint256 gasFee) = IZRC20(zrc20).withdrawGasFee(); + + uint256 inputForGas = SwapHelperLib.swapTokensForExactTokens( + systemContract.wZetaContractAddress(), + systemContract.uniswapv2FactoryAddress(), + systemContract.uniswapv2Router02Address(), + zrc20, + gasFee, + gasZRC20, + amount + ); + + IZRC20(gasZRC20).approve(zrc20, gasFee); + IZRC20(zrc20).withdraw(to, amount - inputForGas); + } +} From a05dde214b3283389ed52eb31baf73eab8b96b94 Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Fri, 2 Feb 2024 13:30:59 -0300 Subject: [PATCH 03/12] update deploy script --- .../scripts/withdrawERC20/deploy.ts | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts diff --git a/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts b/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts new file mode 100644 index 00000000..098d7bab --- /dev/null +++ b/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts @@ -0,0 +1,34 @@ +import { isProtocolNetworkName } from "@zetachain/protocol-contracts"; +import { ethers, network } from "hardhat"; + +import { ERC20__factory, WithdrawERC20__factory } from "../../typechain-types"; +import { saveAddress } from "../address.helpers"; + +const networkName = network.name; + +async function main() { + if (!isProtocolNetworkName(networkName)) throw new Error("Invalid network name"); + + const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; + + // const withdrawERC20 = await WithdrawERC20Factory.deploy(); + // await withdrawERC20.deployed(); + // console.log("WithdrawERC20 deployed to:", withdrawERC20.address); + // saveAddress("withdrawERC20", withdrawERC20.address); + + const WithdrawERC20 = WithdrawERC20Factory.attach("0x16a790cf206bbcd30cb2e36cc7b1f890d260b80c"); + const ERC20Factory = (await ethers.getContractFactory("ERC20")) as ERC20__factory; + const erc20 = ERC20Factory.attach("0x0cbe0dF132a6c6B4a2974Fa1b7Fb953CF0Cc798a"); + + await erc20.approve(WithdrawERC20.address, ethers.utils.parseUnits("5", 6)); + await WithdrawERC20.withdraw( + erc20.address, + ethers.utils.parseUnits("5", 6), + "0x19caCb4c0A7fC25598CC44564ED0eCA01249fc31" + ); +} + +main().catch((error) => { + console.error(error); + process.exit(1); +}); From ccd87af2c5218b4c04822c60b6f9b4f358c5aac2 Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Wed, 6 Mar 2024 11:58:44 -0300 Subject: [PATCH 04/12] restore addresses --- packages/zeta-app-contracts/data/addresses.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/zeta-app-contracts/data/addresses.json b/packages/zeta-app-contracts/data/addresses.json index 4d912ce9..4541ca49 100644 --- a/packages/zeta-app-contracts/data/addresses.json +++ b/packages/zeta-app-contracts/data/addresses.json @@ -8,7 +8,7 @@ }, "bsc_mainnet": { "multiChainSwap": "", - "multiChainValue": "0x33e5fCFfe910B99DB46c259804fCA1317EA0Aa89", + "multiChainValue": "", "zetaTokenConsumerUniV2": "", "zetaTokenConsumerUniV3": "" }, @@ -26,7 +26,7 @@ }, "eth_mainnet": { "multiChainSwap": "", - "multiChainValue": "0x910966E1C0Bc9FD74f499723c19Ff9799fE258a5", + "multiChainValue": "", "zetaTokenConsumerUniV2": "", "zetaTokenConsumerUniV3": "" }, From f871058c1e83a2caa7db9bf528addfc3b6a4e44c Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Wed, 13 Mar 2024 15:24:24 -0300 Subject: [PATCH 05/12] add toolkit --- packages/zeta-app-contracts/package.json | 2 +- .../contracts/withdrawErc20/withdrawErc20.sol | 27 +- packages/zevm-app-contracts/package.json | 1 + .../scripts/withdrawERC20/deploy.ts | 20 +- .../scripts/withdrawERC20/withdraw.ts | 34 + .../test/withdrawERC20/withdrawERC20.ts | 105 ++ yarn.lock | 1532 ++++++++++++++++- 7 files changed, 1632 insertions(+), 89 deletions(-) create mode 100644 packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts create mode 100644 packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts diff --git a/packages/zeta-app-contracts/package.json b/packages/zeta-app-contracts/package.json index db82c197..8a38f9af 100644 --- a/packages/zeta-app-contracts/package.json +++ b/packages/zeta-app-contracts/package.json @@ -40,4 +40,4 @@ "@zetachain/protocol-contracts": "^4.0.1", "ethers": "5.6.8" } -} \ No newline at end of file +} diff --git a/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol b/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol index 115dc0f1..c5dec015 100644 --- a/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol +++ b/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol @@ -2,7 +2,8 @@ pragma solidity 0.8.7; import "@zetachain/protocol-contracts/contracts/zevm/SystemContract.sol"; -import "@zetachain/toolkit/contracts/SwapHelperLib.sol"; + +// import "@zetachain/toolkit/contracts/SwapHelperLib.sol"; contract WithdrawERC20 { SystemContract public immutable systemContract; @@ -16,17 +17,17 @@ contract WithdrawERC20 { (address gasZRC20, uint256 gasFee) = IZRC20(zrc20).withdrawGasFee(); - uint256 inputForGas = SwapHelperLib.swapTokensForExactTokens( - systemContract.wZetaContractAddress(), - systemContract.uniswapv2FactoryAddress(), - systemContract.uniswapv2Router02Address(), - zrc20, - gasFee, - gasZRC20, - amount - ); - - IZRC20(gasZRC20).approve(zrc20, gasFee); - IZRC20(zrc20).withdraw(to, amount - inputForGas); + // uint256 inputForGas = SwapHelperLib.swapTokensForExactTokens( + // systemContract.wZetaContractAddress(), + // systemContract.uniswapv2FactoryAddress(), + // systemContract.uniswapv2Router02Address(), + // zrc20, + // gasFee, + // gasZRC20, + // amount + // ); + + // IZRC20(gasZRC20).approve(zrc20, gasFee); + // IZRC20(zrc20).withdraw(to, amount - inputForGas); } } diff --git a/packages/zevm-app-contracts/package.json b/packages/zevm-app-contracts/package.json index c836f53e..7648d960 100644 --- a/packages/zevm-app-contracts/package.json +++ b/packages/zevm-app-contracts/package.json @@ -38,6 +38,7 @@ "@uniswap/v2-periphery": "1.1.0-beta.0", "@zetachain/networks": "^4.0.0", "@zetachain/protocol-contracts": "^4.0.1", + "@zetachain/toolkit": "^5.0.0", "ethers": "5.6.8" } } diff --git a/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts b/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts index 098d7bab..f16fed9d 100644 --- a/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts +++ b/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts @@ -1,7 +1,7 @@ import { isProtocolNetworkName } from "@zetachain/protocol-contracts"; import { ethers, network } from "hardhat"; -import { ERC20__factory, WithdrawERC20__factory } from "../../typechain-types"; +import { WithdrawERC20__factory } from "../../typechain-types"; import { saveAddress } from "../address.helpers"; const networkName = network.name; @@ -11,21 +11,11 @@ async function main() { const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; - // const withdrawERC20 = await WithdrawERC20Factory.deploy(); - // await withdrawERC20.deployed(); - // console.log("WithdrawERC20 deployed to:", withdrawERC20.address); - // saveAddress("withdrawERC20", withdrawERC20.address); + const withdrawERC20 = await WithdrawERC20Factory.deploy(); + await withdrawERC20.deployed(); - const WithdrawERC20 = WithdrawERC20Factory.attach("0x16a790cf206bbcd30cb2e36cc7b1f890d260b80c"); - const ERC20Factory = (await ethers.getContractFactory("ERC20")) as ERC20__factory; - const erc20 = ERC20Factory.attach("0x0cbe0dF132a6c6B4a2974Fa1b7Fb953CF0Cc798a"); - - await erc20.approve(WithdrawERC20.address, ethers.utils.parseUnits("5", 6)); - await WithdrawERC20.withdraw( - erc20.address, - ethers.utils.parseUnits("5", 6), - "0x19caCb4c0A7fC25598CC44564ED0eCA01249fc31" - ); + console.log("WithdrawERC20 deployed to:", withdrawERC20.address); + saveAddress("withdrawERC20", withdrawERC20.address, networkName); } main().catch((error) => { diff --git a/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts b/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts new file mode 100644 index 00000000..098d7bab --- /dev/null +++ b/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts @@ -0,0 +1,34 @@ +import { isProtocolNetworkName } from "@zetachain/protocol-contracts"; +import { ethers, network } from "hardhat"; + +import { ERC20__factory, WithdrawERC20__factory } from "../../typechain-types"; +import { saveAddress } from "../address.helpers"; + +const networkName = network.name; + +async function main() { + if (!isProtocolNetworkName(networkName)) throw new Error("Invalid network name"); + + const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; + + // const withdrawERC20 = await WithdrawERC20Factory.deploy(); + // await withdrawERC20.deployed(); + // console.log("WithdrawERC20 deployed to:", withdrawERC20.address); + // saveAddress("withdrawERC20", withdrawERC20.address); + + const WithdrawERC20 = WithdrawERC20Factory.attach("0x16a790cf206bbcd30cb2e36cc7b1f890d260b80c"); + const ERC20Factory = (await ethers.getContractFactory("ERC20")) as ERC20__factory; + const erc20 = ERC20Factory.attach("0x0cbe0dF132a6c6B4a2974Fa1b7Fb953CF0Cc798a"); + + await erc20.approve(WithdrawERC20.address, ethers.utils.parseUnits("5", 6)); + await WithdrawERC20.withdraw( + erc20.address, + ethers.utils.parseUnits("5", 6), + "0x19caCb4c0A7fC25598CC44564ED0eCA01249fc31" + ); +} + +main().catch((error) => { + console.error(error); + process.exit(1); +}); diff --git a/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts b/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts new file mode 100644 index 00000000..6cfac71a --- /dev/null +++ b/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts @@ -0,0 +1,105 @@ +import { parseUnits } from "@ethersproject/units"; +import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; +import { expect } from "chai"; +import { parseEther } from "ethers/lib/utils"; +import { ethers, network } from "hardhat"; + +import { Disperse, Disperse__factory, MockZRC20, MockZRC20__factory } from "../typechain-types"; + +describe("WithdrawERC20 tests", () => { + let withdrawERC20Contract: WithdrawERC20; + + let accounts: SignerWithAddress[]; + let deployer: SignerWithAddress; + + beforeEach(async () => { + [deployer, ...accounts] = await ethers.getSigners(); + + await network.provider.send("hardhat_setBalance", [deployer.address, parseUnits("1000000").toHexString()]); + + const DisperseFactory = (await ethers.getContractFactory("Disperse")) as Disperse__factory; + withdrawERC20Contract = (await DisperseFactory.deploy()) as Disperse; + await withdrawERC20Contract.deployed(); + }); + + describe("Disperse", () => { + it("Should disperse ETH", async () => { + const count = 500; + const amount = parseEther("0.01"); + const balance0 = await ethers.provider.getBalance(accounts[0].address); + const balance1 = await ethers.provider.getBalance(accounts[1].address); + + const bigArrayAddress = new Array(count).fill(accounts[0].address); + const bigArrayAmount = new Array(count).fill(amount); + + await withdrawERC20Contract.disperseEther(bigArrayAddress, bigArrayAmount, { + value: amount.mul(count), + }); + + const balance0After = await ethers.provider.getBalance(accounts[0].address); + const balance1After = await ethers.provider.getBalance(accounts[1].address); + + expect(balance0After.sub(balance0)).to.be.eq(amount.mul(count)); + expect(balance1After.sub(balance1)).to.be.eq(0); + }); + + it("Should disperse ETH with surplus", async () => { + const amount = parseUnits("10"); + const balance0 = await ethers.provider.getBalance(accounts[0].address); + const balance1 = await ethers.provider.getBalance(accounts[1].address); + await withdrawERC20Contract.disperseEther([accounts[0].address, accounts[1].address], [amount, amount.mul(2)], { + value: amount.mul(4), + }); + + const balance0After = await ethers.provider.getBalance(accounts[0].address); + const balance1After = await ethers.provider.getBalance(accounts[1].address); + + expect(balance0After.sub(balance0)).to.be.eq(amount); + expect(balance1After.sub(balance1)).to.be.eq(amount.mul(2)); + }); + + it("Should disperse token", async () => { + const MockTokenFactory = (await ethers.getContractFactory("MockZRC20")) as MockZRC20__factory; + const mockTokenContract = (await MockTokenFactory.deploy(1_000_000, "MOCK", "MOCK")) as MockZRC20; + await mockTokenContract.deployed(); + await mockTokenContract.approve(withdrawERC20Contract.address, parseUnits("1000000")); + + const amount = parseUnits("10"); + const balance0 = await mockTokenContract.balanceOf(accounts[0].address); + const balance1 = await mockTokenContract.balanceOf(accounts[1].address); + await withdrawERC20Contract.disperseToken( + mockTokenContract.address, + [accounts[0].address, accounts[1].address], + [amount, amount.mul(2)] + ); + + const balance0After = await mockTokenContract.balanceOf(accounts[0].address); + const balance1After = await mockTokenContract.balanceOf(accounts[1].address); + + expect(balance0After.sub(balance0)).to.be.eq(amount); + expect(balance1After.sub(balance1)).to.be.eq(amount.mul(2)); + }); + + it("Should disperse token simple", async () => { + const MockTokenFactory = (await ethers.getContractFactory("MockZRC20")) as MockZRC20__factory; + const mockTokenContract = (await MockTokenFactory.deploy(1_000_000, "MOCK", "MOCK")) as MockZRC20; + await mockTokenContract.deployed(); + await mockTokenContract.approve(withdrawERC20Contract.address, parseUnits("1000000")); + + const amount = parseUnits("10"); + const balance0 = await mockTokenContract.balanceOf(accounts[0].address); + const balance1 = await mockTokenContract.balanceOf(accounts[1].address); + await withdrawERC20Contract.disperseTokenSimple( + mockTokenContract.address, + [accounts[0].address, accounts[1].address], + [amount, amount.mul(2)] + ); + + const balance0After = await mockTokenContract.balanceOf(accounts[0].address); + const balance1After = await mockTokenContract.balanceOf(accounts[1].address); + + expect(balance0After.sub(balance0)).to.be.eq(amount); + expect(balance1After.sub(balance1)).to.be.eq(amount.mul(2)); + }); + }); +}); diff --git a/yarn.lock b/yarn.lock index 773526e9..1ea174fb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -565,6 +565,23 @@ __metadata: languageName: node linkType: hard +"@ethersproject/abi@npm:5.4.1": + version: 5.4.1 + resolution: "@ethersproject/abi@npm:5.4.1" + dependencies: + "@ethersproject/address": ^5.4.0 + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/constants": ^5.4.0 + "@ethersproject/hash": ^5.4.0 + "@ethersproject/keccak256": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/strings": ^5.4.0 + checksum: 75460eee1d4eeaa438a43a003343dfcd2a8c3b1b7e0d8a3dd31c9200375d52daeea7022622696d1fec54913ec3b72423057236677907793ec134d2601a061fec + languageName: node + linkType: hard + "@ethersproject/abi@npm:5.6.3": version: 5.6.3 resolution: "@ethersproject/abi@npm:5.6.3" @@ -582,7 +599,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/abi@npm:5.7.0, @ethersproject/abi@npm:^5.1.2, @ethersproject/abi@npm:^5.6.3, @ethersproject/abi@npm:^5.7.0": +"@ethersproject/abi@npm:5.7.0, @ethersproject/abi@npm:^5.1.2, @ethersproject/abi@npm:^5.4.0, @ethersproject/abi@npm:^5.6.3, @ethersproject/abi@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/abi@npm:5.7.0" dependencies: @@ -599,6 +616,21 @@ __metadata: languageName: node linkType: hard +"@ethersproject/abstract-provider@npm:5.4.1": + version: 5.4.1 + resolution: "@ethersproject/abstract-provider@npm:5.4.1" + dependencies: + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/networks": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/transactions": ^5.4.0 + "@ethersproject/web": ^5.4.0 + checksum: dd4b8b0b58a58b094377e657e46cb59231bed89abdaa774cad6b0a21015d797283d50585fd4e7f1f9dfda66feede0aed8725183839f4527067427902720e360b + languageName: node + linkType: hard + "@ethersproject/abstract-provider@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/abstract-provider@npm:5.6.1" @@ -614,7 +646,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/abstract-provider@npm:5.7.0, @ethersproject/abstract-provider@npm:^5.6.1, @ethersproject/abstract-provider@npm:^5.7.0": +"@ethersproject/abstract-provider@npm:5.7.0, @ethersproject/abstract-provider@npm:^5.4.0, @ethersproject/abstract-provider@npm:^5.6.1, @ethersproject/abstract-provider@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/abstract-provider@npm:5.7.0" dependencies: @@ -629,6 +661,19 @@ __metadata: languageName: node linkType: hard +"@ethersproject/abstract-signer@npm:5.4.1": + version: 5.4.1 + resolution: "@ethersproject/abstract-signer@npm:5.4.1" + dependencies: + "@ethersproject/abstract-provider": ^5.4.0 + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + checksum: 5fe9c3978d9c1ca9a5f47ed8afb2d8d00c97e4304114e72ea149816c9a607979022bff01176cb9b293ac8753158399ae7bdf57901f3deb8f7cb050e06070ad1e + languageName: node + linkType: hard + "@ethersproject/abstract-signer@npm:5.6.2": version: 5.6.2 resolution: "@ethersproject/abstract-signer@npm:5.6.2" @@ -642,7 +687,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/abstract-signer@npm:5.7.0, @ethersproject/abstract-signer@npm:^5.6.2, @ethersproject/abstract-signer@npm:^5.7.0": +"@ethersproject/abstract-signer@npm:5.7.0, @ethersproject/abstract-signer@npm:^5.4.0, @ethersproject/abstract-signer@npm:^5.6.2, @ethersproject/abstract-signer@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/abstract-signer@npm:5.7.0" dependencies: @@ -655,6 +700,19 @@ __metadata: languageName: node linkType: hard +"@ethersproject/address@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/address@npm:5.4.0" + dependencies: + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/keccak256": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/rlp": ^5.4.0 + checksum: c7ad0cffa86a24c5e4c176d4c08b99a35551abd72520ccc55de9c94ef45737f6082c2a784586360915f17802008154c995990f8f35b0f6c2b6738b80b766c0a4 + languageName: node + linkType: hard + "@ethersproject/address@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/address@npm:5.6.1" @@ -668,7 +726,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/address@npm:5.7.0, @ethersproject/address@npm:^5.0.2, @ethersproject/address@npm:^5.6.1, @ethersproject/address@npm:^5.7.0": +"@ethersproject/address@npm:5.7.0, @ethersproject/address@npm:^5.0.2, @ethersproject/address@npm:^5.4.0, @ethersproject/address@npm:^5.6.1, @ethersproject/address@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/address@npm:5.7.0" dependencies: @@ -681,6 +739,15 @@ __metadata: languageName: node linkType: hard +"@ethersproject/base64@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/base64@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + checksum: 40e14debc4534005cc8a1594074dab272c49d84fb3a6b4c0eedd6144211312a8ad97009603381e90f6ddfeaf5f227c0e8e56d6753562981a9ae6ccfcb8430d4e + languageName: node + linkType: hard + "@ethersproject/base64@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/base64@npm:5.6.1" @@ -690,7 +757,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/base64@npm:5.7.0, @ethersproject/base64@npm:^5.6.1, @ethersproject/base64@npm:^5.7.0": +"@ethersproject/base64@npm:5.7.0, @ethersproject/base64@npm:^5.4.0, @ethersproject/base64@npm:^5.6.1, @ethersproject/base64@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/base64@npm:5.7.0" dependencies: @@ -699,6 +766,16 @@ __metadata: languageName: node linkType: hard +"@ethersproject/basex@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/basex@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + checksum: 0a364834f29b27bb04c91698cd2612f07f96f73709af20d99a4b96babc75baf770e84ac01fa2c6b34f0ee3e04c35566d601c6cf1933973844c1a0b785f6f0da5 + languageName: node + linkType: hard + "@ethersproject/basex@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/basex@npm:5.6.1" @@ -709,7 +786,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/basex@npm:5.7.0, @ethersproject/basex@npm:^5.6.1, @ethersproject/basex@npm:^5.7.0": +"@ethersproject/basex@npm:5.7.0, @ethersproject/basex@npm:^5.4.0, @ethersproject/basex@npm:^5.6.1, @ethersproject/basex@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/basex@npm:5.7.0" dependencies: @@ -719,6 +796,17 @@ __metadata: languageName: node linkType: hard +"@ethersproject/bignumber@npm:5.4.2": + version: 5.4.2 + resolution: "@ethersproject/bignumber@npm:5.4.2" + dependencies: + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + bn.js: ^4.11.9 + checksum: 4332d27826b5f443824caa93232e7024d77d180cd59c184ee19d15637f696908da609fab8dfa805a5825f258f48ec0aeb20db890b1094779453320460ac2a50b + languageName: node + linkType: hard + "@ethersproject/bignumber@npm:5.6.2": version: 5.6.2 resolution: "@ethersproject/bignumber@npm:5.6.2" @@ -730,7 +818,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/bignumber@npm:5.7.0, @ethersproject/bignumber@npm:^5.6.2, @ethersproject/bignumber@npm:^5.7.0": +"@ethersproject/bignumber@npm:5.7.0, @ethersproject/bignumber@npm:^5.4.0, @ethersproject/bignumber@npm:^5.6.2, @ethersproject/bignumber@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/bignumber@npm:5.7.0" dependencies: @@ -741,6 +829,15 @@ __metadata: languageName: node linkType: hard +"@ethersproject/bytes@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/bytes@npm:5.4.0" + dependencies: + "@ethersproject/logger": ^5.4.0 + checksum: be8678ec713858e6d944defc78b9950ab83a9cde22c51ea2658ee4a5aa176f1ce9c36dd6630a2a17dcf6bd098b1b33b7b1d3b8fe2edb8840af4028567ca68775 + languageName: node + linkType: hard + "@ethersproject/bytes@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/bytes@npm:5.6.1" @@ -750,7 +847,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/bytes@npm:5.7.0, @ethersproject/bytes@npm:^5.6.1, @ethersproject/bytes@npm:^5.7.0": +"@ethersproject/bytes@npm:5.7.0, @ethersproject/bytes@npm:^5.4.0, @ethersproject/bytes@npm:^5.6.1, @ethersproject/bytes@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/bytes@npm:5.7.0" dependencies: @@ -759,6 +856,15 @@ __metadata: languageName: node linkType: hard +"@ethersproject/constants@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/constants@npm:5.4.0" + dependencies: + "@ethersproject/bignumber": ^5.4.0 + checksum: 736f601d54b1f427cf5451ac463c5470929aac590a287ec40fa5d5f69582f2695b6bc4b476228d63030fb7f215a302fc6db690b2d55038207910232e17b09d89 + languageName: node + linkType: hard + "@ethersproject/constants@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/constants@npm:5.6.1" @@ -768,7 +874,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/constants@npm:5.7.0, @ethersproject/constants@npm:^5.6.1, @ethersproject/constants@npm:^5.7.0": +"@ethersproject/constants@npm:5.7.0, @ethersproject/constants@npm:^5.4.0, @ethersproject/constants@npm:^5.6.1, @ethersproject/constants@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/constants@npm:5.7.0" dependencies: @@ -777,6 +883,24 @@ __metadata: languageName: node linkType: hard +"@ethersproject/contracts@npm:5.4.1": + version: 5.4.1 + resolution: "@ethersproject/contracts@npm:5.4.1" + dependencies: + "@ethersproject/abi": ^5.4.0 + "@ethersproject/abstract-provider": ^5.4.0 + "@ethersproject/abstract-signer": ^5.4.0 + "@ethersproject/address": ^5.4.0 + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/constants": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/transactions": ^5.4.0 + checksum: da817280c44244bf66c9d6136110e4baecad2e30780143598078081b8b34b6a93023ab83a601746d37336a5fceabbcaa267b3b09cf297a7a105949e5b21f255b + languageName: node + linkType: hard + "@ethersproject/contracts@npm:5.6.2": version: 5.6.2 resolution: "@ethersproject/contracts@npm:5.6.2" @@ -813,6 +937,22 @@ __metadata: languageName: node linkType: hard +"@ethersproject/hash@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/hash@npm:5.4.0" + dependencies: + "@ethersproject/abstract-signer": ^5.4.0 + "@ethersproject/address": ^5.4.0 + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/keccak256": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/strings": ^5.4.0 + checksum: 20c48688568cc6bb3643bdc69626d0358d1d45994d2f4e38ee01823c0f0dbb47920e74e751bbbfe7c02995a7fd5afe4e2594c0a301fb579339cb3e908141f7b2 + languageName: node + linkType: hard + "@ethersproject/hash@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/hash@npm:5.6.1" @@ -829,7 +969,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/hash@npm:5.7.0, @ethersproject/hash@npm:^5.6.1, @ethersproject/hash@npm:^5.7.0": +"@ethersproject/hash@npm:5.7.0, @ethersproject/hash@npm:^5.4.0, @ethersproject/hash@npm:^5.6.1, @ethersproject/hash@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/hash@npm:5.7.0" dependencies: @@ -846,6 +986,26 @@ __metadata: languageName: node linkType: hard +"@ethersproject/hdnode@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/hdnode@npm:5.4.0" + dependencies: + "@ethersproject/abstract-signer": ^5.4.0 + "@ethersproject/basex": ^5.4.0 + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/pbkdf2": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/sha2": ^5.4.0 + "@ethersproject/signing-key": ^5.4.0 + "@ethersproject/strings": ^5.4.0 + "@ethersproject/transactions": ^5.4.0 + "@ethersproject/wordlists": ^5.4.0 + checksum: cfd3b1512800877223960ad4e8ce6eacc09486b6e07d74f109c37f6211a3bb77c528c684d3a2dadff933f12d5b8d9676659ef65baa9c5eab257d255d78743dbd + languageName: node + linkType: hard + "@ethersproject/hdnode@npm:5.6.2": version: 5.6.2 resolution: "@ethersproject/hdnode@npm:5.6.2" @@ -866,7 +1026,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/hdnode@npm:5.7.0, @ethersproject/hdnode@npm:^5.6.2, @ethersproject/hdnode@npm:^5.7.0": +"@ethersproject/hdnode@npm:5.7.0, @ethersproject/hdnode@npm:^5.4.0, @ethersproject/hdnode@npm:^5.6.2, @ethersproject/hdnode@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/hdnode@npm:5.7.0" dependencies: @@ -886,6 +1046,27 @@ __metadata: languageName: node linkType: hard +"@ethersproject/json-wallets@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/json-wallets@npm:5.4.0" + dependencies: + "@ethersproject/abstract-signer": ^5.4.0 + "@ethersproject/address": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/hdnode": ^5.4.0 + "@ethersproject/keccak256": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/pbkdf2": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/random": ^5.4.0 + "@ethersproject/strings": ^5.4.0 + "@ethersproject/transactions": ^5.4.0 + aes-js: 3.0.0 + scrypt-js: 3.0.1 + checksum: 8bd933253212199d6594cc2b7777b0e110724e756a9693f4d07f3549355eb599a7ede98b52bd96d2b0f8985ed52ad5a6ff2148fc0aa5a78812535636e4e9dffa + languageName: node + linkType: hard + "@ethersproject/json-wallets@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/json-wallets@npm:5.6.1" @@ -907,7 +1088,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/json-wallets@npm:5.7.0, @ethersproject/json-wallets@npm:^5.6.1, @ethersproject/json-wallets@npm:^5.7.0": +"@ethersproject/json-wallets@npm:5.7.0, @ethersproject/json-wallets@npm:^5.4.0, @ethersproject/json-wallets@npm:^5.6.1, @ethersproject/json-wallets@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/json-wallets@npm:5.7.0" dependencies: @@ -928,6 +1109,16 @@ __metadata: languageName: node linkType: hard +"@ethersproject/keccak256@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/keccak256@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + js-sha3: 0.5.7 + checksum: b76d2818734fb55b80c3b7fc07e761a594b721840c276a52b92e457e4f460802c2f6fe6e684ef444a1d28565351b5859a6e202751fafe111bccef2e596bf9a1e + languageName: node + linkType: hard + "@ethersproject/keccak256@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/keccak256@npm:5.6.1" @@ -938,7 +1129,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/keccak256@npm:5.7.0, @ethersproject/keccak256@npm:^5.6.1, @ethersproject/keccak256@npm:^5.7.0": +"@ethersproject/keccak256@npm:5.7.0, @ethersproject/keccak256@npm:^5.4.0, @ethersproject/keccak256@npm:^5.6.1, @ethersproject/keccak256@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/keccak256@npm:5.7.0" dependencies: @@ -948,6 +1139,13 @@ __metadata: languageName: node linkType: hard +"@ethersproject/logger@npm:5.4.1": + version: 5.4.1 + resolution: "@ethersproject/logger@npm:5.4.1" + checksum: 40ade2d1d9408cf786239d850aa6c1bd41403d68f8ab8974643836406efdae1a9419f25a184037ed7c2ee9dcb09896a09d078eed6dd424351f025b1e2eaf19e3 + languageName: node + linkType: hard + "@ethersproject/logger@npm:5.6.0": version: 5.6.0 resolution: "@ethersproject/logger@npm:5.6.0" @@ -955,13 +1153,22 @@ __metadata: languageName: node linkType: hard -"@ethersproject/logger@npm:5.7.0, @ethersproject/logger@npm:^5.6.0, @ethersproject/logger@npm:^5.7.0": +"@ethersproject/logger@npm:5.7.0, @ethersproject/logger@npm:^5.4.0, @ethersproject/logger@npm:^5.6.0, @ethersproject/logger@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/logger@npm:5.7.0" checksum: 075ab2f605f1fd0813f2e39c3308f77b44a67732b36e712d9bc085f22a84aac4da4f71b39bee50fe78da3e1c812673fadc41180c9970fe5e486e91ea17befe0d languageName: node linkType: hard +"@ethersproject/networks@npm:5.4.2": + version: 5.4.2 + resolution: "@ethersproject/networks@npm:5.4.2" + dependencies: + "@ethersproject/logger": ^5.4.0 + checksum: 08b794f537fe291a566d930877a4a05a18543537755d323b634a7e4818032e5c8bd4f14bb97dafce4d3e4149ecea499b59e4f75a07fd554cab87c3a7fbeb0a0c + languageName: node + linkType: hard + "@ethersproject/networks@npm:5.6.3": version: 5.6.3 resolution: "@ethersproject/networks@npm:5.6.3" @@ -971,7 +1178,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/networks@npm:5.7.1, @ethersproject/networks@npm:^5.6.3, @ethersproject/networks@npm:^5.7.0": +"@ethersproject/networks@npm:5.7.1, @ethersproject/networks@npm:^5.4.0, @ethersproject/networks@npm:^5.6.3, @ethersproject/networks@npm:^5.7.0": version: 5.7.1 resolution: "@ethersproject/networks@npm:5.7.1" dependencies: @@ -980,6 +1187,16 @@ __metadata: languageName: node linkType: hard +"@ethersproject/pbkdf2@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/pbkdf2@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/sha2": ^5.4.0 + checksum: 596c6b8f920a147eb8f7c1b36d6119be3bf0b31c591cc844b3067300a7ee605d9b03959309a58a37c1ab64e112b4edf838dcac658c5163c5d17966700936c615 + languageName: node + linkType: hard + "@ethersproject/pbkdf2@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/pbkdf2@npm:5.6.1" @@ -990,7 +1207,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/pbkdf2@npm:5.7.0, @ethersproject/pbkdf2@npm:^5.6.1, @ethersproject/pbkdf2@npm:^5.7.0": +"@ethersproject/pbkdf2@npm:5.7.0, @ethersproject/pbkdf2@npm:^5.4.0, @ethersproject/pbkdf2@npm:^5.6.1, @ethersproject/pbkdf2@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/pbkdf2@npm:5.7.0" dependencies: @@ -1000,6 +1217,15 @@ __metadata: languageName: node linkType: hard +"@ethersproject/properties@npm:5.4.1": + version: 5.4.1 + resolution: "@ethersproject/properties@npm:5.4.1" + dependencies: + "@ethersproject/logger": ^5.4.0 + checksum: 9c1fc83e26e0b2d7c26c1fb49e14cf5a08598bc06e9b1b5b2f67c9368febb6a35066e445debfc4f600e2a6516fc01baf42d65c23f79b32e634afd6a5b5dd9faf + languageName: node + linkType: hard + "@ethersproject/properties@npm:5.6.0": version: 5.6.0 resolution: "@ethersproject/properties@npm:5.6.0" @@ -1009,7 +1235,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/properties@npm:5.7.0, @ethersproject/properties@npm:^5.6.0, @ethersproject/properties@npm:^5.7.0": +"@ethersproject/properties@npm:5.7.0, @ethersproject/properties@npm:^5.4.0, @ethersproject/properties@npm:^5.6.0, @ethersproject/properties@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/properties@npm:5.7.0" dependencies: @@ -1018,6 +1244,33 @@ __metadata: languageName: node linkType: hard +"@ethersproject/providers@npm:5.4.5": + version: 5.4.5 + resolution: "@ethersproject/providers@npm:5.4.5" + dependencies: + "@ethersproject/abstract-provider": ^5.4.0 + "@ethersproject/abstract-signer": ^5.4.0 + "@ethersproject/address": ^5.4.0 + "@ethersproject/basex": ^5.4.0 + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/constants": ^5.4.0 + "@ethersproject/hash": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/networks": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/random": ^5.4.0 + "@ethersproject/rlp": ^5.4.0 + "@ethersproject/sha2": ^5.4.0 + "@ethersproject/strings": ^5.4.0 + "@ethersproject/transactions": ^5.4.0 + "@ethersproject/web": ^5.4.0 + bech32: 1.1.4 + ws: 7.4.6 + checksum: 09692fb053453c2a7e5d566e42d4542cd4225ea829d9177b6227c09559b11c041b4be5958d550ece3fb1d4677e67e45a4604604fd9f5d1b8dcbd04b8c259c186 + languageName: node + linkType: hard + "@ethersproject/providers@npm:5.6.8": version: 5.6.8 resolution: "@ethersproject/providers@npm:5.6.8" @@ -1074,6 +1327,16 @@ __metadata: languageName: node linkType: hard +"@ethersproject/random@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/random@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + checksum: 7bf0150b639faac4f9c8c234083d2f1b5d3fbd530ab64d5602240c8873d856418e1512f41b8c39b771118ff7d06d257dd0ad473aca9e3886535baeeb5ac6b7e8 + languageName: node + linkType: hard + "@ethersproject/random@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/random@npm:5.6.1" @@ -1084,7 +1347,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/random@npm:5.7.0, @ethersproject/random@npm:^5.6.1, @ethersproject/random@npm:^5.7.0": +"@ethersproject/random@npm:5.7.0, @ethersproject/random@npm:^5.4.0, @ethersproject/random@npm:^5.6.1, @ethersproject/random@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/random@npm:5.7.0" dependencies: @@ -1094,6 +1357,16 @@ __metadata: languageName: node linkType: hard +"@ethersproject/rlp@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/rlp@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + checksum: d6c45c17f8062a93737267aca52c16725fa197706b5dade1f806f9be3e498d3f70101cad631dc979d7db94ee170f225fed03900df35676cfe6ba86b16136f046 + languageName: node + linkType: hard + "@ethersproject/rlp@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/rlp@npm:5.6.1" @@ -1104,7 +1377,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/rlp@npm:5.7.0, @ethersproject/rlp@npm:^5.6.1, @ethersproject/rlp@npm:^5.7.0": +"@ethersproject/rlp@npm:5.7.0, @ethersproject/rlp@npm:^5.4.0, @ethersproject/rlp@npm:^5.6.1, @ethersproject/rlp@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/rlp@npm:5.7.0" dependencies: @@ -1114,6 +1387,17 @@ __metadata: languageName: node linkType: hard +"@ethersproject/sha2@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/sha2@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + hash.js: 1.1.7 + checksum: 253a5ad3894c3a0bcd1d7af6dc19fbd80680732bf05c708b9c27c26ffc0a8c2be04eaeabf98be6be18e7181a130b142ac391aceac705382cea7f24876f012671 + languageName: node + linkType: hard + "@ethersproject/sha2@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/sha2@npm:5.6.1" @@ -1125,7 +1409,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/sha2@npm:5.7.0, @ethersproject/sha2@npm:^5.6.1, @ethersproject/sha2@npm:^5.7.0": +"@ethersproject/sha2@npm:5.7.0, @ethersproject/sha2@npm:^5.4.0, @ethersproject/sha2@npm:^5.6.1, @ethersproject/sha2@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/sha2@npm:5.7.0" dependencies: @@ -1136,6 +1420,20 @@ __metadata: languageName: node linkType: hard +"@ethersproject/signing-key@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/signing-key@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + bn.js: ^4.11.9 + elliptic: 6.5.4 + hash.js: 1.1.7 + checksum: aa5666aec046f57cd6b66044b2ea34cd72e481b209cadbf7a2d09e1eb9123e0817398e0e31dad22acef72fa9e06faf78026169c82f800826bcf4fbbed2d7d5a3 + languageName: node + linkType: hard + "@ethersproject/signing-key@npm:5.6.2": version: 5.6.2 resolution: "@ethersproject/signing-key@npm:5.6.2" @@ -1150,7 +1448,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/signing-key@npm:5.7.0, @ethersproject/signing-key@npm:^5.6.2, @ethersproject/signing-key@npm:^5.7.0": +"@ethersproject/signing-key@npm:5.7.0, @ethersproject/signing-key@npm:^5.4.0, @ethersproject/signing-key@npm:^5.6.2, @ethersproject/signing-key@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/signing-key@npm:5.7.0" dependencies: @@ -1164,6 +1462,19 @@ __metadata: languageName: node linkType: hard +"@ethersproject/solidity@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/solidity@npm:5.4.0" + dependencies: + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/keccak256": ^5.4.0 + "@ethersproject/sha2": ^5.4.0 + "@ethersproject/strings": ^5.4.0 + checksum: 62f8756a9b9e15073b4785f8880a3c248eba6397f33b6de1bd4ed7f83a362c5a61dfe5b2e602b30aec0b0f46efc27cbdd796de43b2c1b62db9e3d2fed43ec90a + languageName: node + linkType: hard + "@ethersproject/solidity@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/solidity@npm:5.6.1" @@ -1192,6 +1503,17 @@ __metadata: languageName: node linkType: hard +"@ethersproject/strings@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/strings@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/constants": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + checksum: f62ab89803f6cbc9c91093589e8e117b0c0857d8642d7d85bef1807f3ced7757127d3f271bf0bd7f644e02a31282842c1339f678b7f8a79c88ad3326d775db2a + languageName: node + linkType: hard + "@ethersproject/strings@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/strings@npm:5.6.1" @@ -1203,7 +1525,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/strings@npm:5.7.0, @ethersproject/strings@npm:^5.6.1, @ethersproject/strings@npm:^5.7.0": +"@ethersproject/strings@npm:5.7.0, @ethersproject/strings@npm:^5.4.0, @ethersproject/strings@npm:^5.6.1, @ethersproject/strings@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/strings@npm:5.7.0" dependencies: @@ -1214,6 +1536,23 @@ __metadata: languageName: node linkType: hard +"@ethersproject/transactions@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/transactions@npm:5.4.0" + dependencies: + "@ethersproject/address": ^5.4.0 + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/constants": ^5.4.0 + "@ethersproject/keccak256": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/rlp": ^5.4.0 + "@ethersproject/signing-key": ^5.4.0 + checksum: 7407c93301fe634bf74150e1b4dc0636246ee4022ae988c003e1a52d0ad5cc6a693a6cb763b2280cb856f76e314b8650206cb1308a7a679e63bfbe8604294fe3 + languageName: node + linkType: hard + "@ethersproject/transactions@npm:5.6.2": version: 5.6.2 resolution: "@ethersproject/transactions@npm:5.6.2" @@ -1231,7 +1570,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/transactions@npm:5.7.0, @ethersproject/transactions@npm:^5.6.2, @ethersproject/transactions@npm:^5.7.0": +"@ethersproject/transactions@npm:5.7.0, @ethersproject/transactions@npm:^5.4.0, @ethersproject/transactions@npm:^5.6.2, @ethersproject/transactions@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/transactions@npm:5.7.0" dependencies: @@ -1248,6 +1587,17 @@ __metadata: languageName: node linkType: hard +"@ethersproject/units@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/units@npm:5.4.0" + dependencies: + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/constants": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + checksum: 47054df485b4b648a982186d280f0eef9489acbd0d1a4036cc8f9170b8c3c91552b5d8d21213cef206e76b475fc83c9318d87c50b4931e0495198637181f068d + languageName: node + linkType: hard + "@ethersproject/units@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/units@npm:5.6.1" @@ -1270,6 +1620,29 @@ __metadata: languageName: node linkType: hard +"@ethersproject/wallet@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/wallet@npm:5.4.0" + dependencies: + "@ethersproject/abstract-provider": ^5.4.0 + "@ethersproject/abstract-signer": ^5.4.0 + "@ethersproject/address": ^5.4.0 + "@ethersproject/bignumber": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/hash": ^5.4.0 + "@ethersproject/hdnode": ^5.4.0 + "@ethersproject/json-wallets": ^5.4.0 + "@ethersproject/keccak256": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/random": ^5.4.0 + "@ethersproject/signing-key": ^5.4.0 + "@ethersproject/transactions": ^5.4.0 + "@ethersproject/wordlists": ^5.4.0 + checksum: 537bea004798951476b15752fad672d919e3130aeacaff3cf2497d466f1346e5fa15b6cd716c0c879ce68bc7f33e1bd355ce11032a94e9d30eef0666b6fd1ddf + languageName: node + linkType: hard + "@ethersproject/wallet@npm:5.6.2": version: 5.6.2 resolution: "@ethersproject/wallet@npm:5.6.2" @@ -1316,6 +1689,19 @@ __metadata: languageName: node linkType: hard +"@ethersproject/web@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/web@npm:5.4.0" + dependencies: + "@ethersproject/base64": ^5.4.0 + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/strings": ^5.4.0 + checksum: 09954d42aaa91690448b8dacfb16d82351138f13c2bf05ab18c4e03c5c5c1df625bc094d781665ef5b034a24f5c0c305d6b01f4f5e6bf082e30933b3788d69ce + languageName: node + linkType: hard + "@ethersproject/web@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/web@npm:5.6.1" @@ -1329,7 +1715,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/web@npm:5.7.1, @ethersproject/web@npm:^5.6.1, @ethersproject/web@npm:^5.7.0": +"@ethersproject/web@npm:5.7.1, @ethersproject/web@npm:^5.4.0, @ethersproject/web@npm:^5.6.1, @ethersproject/web@npm:^5.7.0": version: 5.7.1 resolution: "@ethersproject/web@npm:5.7.1" dependencies: @@ -1342,6 +1728,19 @@ __metadata: languageName: node linkType: hard +"@ethersproject/wordlists@npm:5.4.0": + version: 5.4.0 + resolution: "@ethersproject/wordlists@npm:5.4.0" + dependencies: + "@ethersproject/bytes": ^5.4.0 + "@ethersproject/hash": ^5.4.0 + "@ethersproject/logger": ^5.4.0 + "@ethersproject/properties": ^5.4.0 + "@ethersproject/strings": ^5.4.0 + checksum: db9fb8994a27cec040a44efa4a9c16af6443db71e809012a7dfa05c2ea2162c699a7f5e5ca9683580a490e90c55718aa110fa1eb79749a359f85794cc43d67b6 + languageName: node + linkType: hard + "@ethersproject/wordlists@npm:5.6.1": version: 5.6.1 resolution: "@ethersproject/wordlists@npm:5.6.1" @@ -1355,7 +1754,7 @@ __metadata: languageName: node linkType: hard -"@ethersproject/wordlists@npm:5.7.0, @ethersproject/wordlists@npm:^5.6.1, @ethersproject/wordlists@npm:^5.7.0": +"@ethersproject/wordlists@npm:5.7.0, @ethersproject/wordlists@npm:^5.4.0, @ethersproject/wordlists@npm:^5.6.1, @ethersproject/wordlists@npm:^5.7.0": version: 5.7.0 resolution: "@ethersproject/wordlists@npm:5.7.0" dependencies: @@ -1476,6 +1875,201 @@ __metadata: languageName: node linkType: hard +"@inquirer/checkbox@npm:^1.3.4": + version: 1.5.2 + resolution: "@inquirer/checkbox@npm:1.5.2" + dependencies: + "@inquirer/core": ^6.0.0 + "@inquirer/type": ^1.1.6 + ansi-escapes: ^4.3.2 + chalk: ^4.1.2 + figures: ^3.2.0 + checksum: aeb1efe6cd424d32c8c971b97fd4f95f84a44f8e8538c9e1d6c552b05a7efb74cafdb6c5173d6a9f8a085d17e247524f620118408e74d64179ec7d219dba99f7 + languageName: node + linkType: hard + +"@inquirer/confirm@npm:^2.0.5": + version: 2.0.17 + resolution: "@inquirer/confirm@npm:2.0.17" + dependencies: + "@inquirer/core": ^6.0.0 + "@inquirer/type": ^1.1.6 + chalk: ^4.1.2 + checksum: 58085b31618308f2082b019c65c87a9698f05ba2336cc29d95f5d89680aa3ab0ff5cf6ec9828158b3850a5dee329a3050736b4c5b77af78870136605909e5a95 + languageName: node + linkType: hard + +"@inquirer/core@npm:^1.1.3": + version: 1.3.0 + resolution: "@inquirer/core@npm:1.3.0" + dependencies: + "@inquirer/type": ^1.0.5 + ansi-escapes: ^4.3.2 + chalk: ^4.1.2 + cli-spinners: ^2.8.0 + cli-width: ^4.0.0 + figures: ^3.2.0 + mute-stream: ^1.0.0 + run-async: ^3.0.0 + string-width: ^4.2.3 + strip-ansi: ^6.0.1 + wrap-ansi: ^6.0.1 + checksum: e6d3ee4a32714e37bc1a0b094c69367017bbbe1bc86743807e54112a4c370ee7c205507455006b7a4de8c176699d91eb1f9edcb8286d6b0393e364d564d8e55a + languageName: node + linkType: hard + +"@inquirer/core@npm:^2.3.1": + version: 2.3.1 + resolution: "@inquirer/core@npm:2.3.1" + dependencies: + "@inquirer/type": ^1.1.1 + "@types/mute-stream": ^0.0.1 + "@types/node": ^20.4.2 + "@types/wrap-ansi": ^3.0.0 + ansi-escapes: ^4.3.2 + chalk: ^4.1.2 + cli-spinners: ^2.8.0 + cli-width: ^4.0.0 + figures: ^3.2.0 + mute-stream: ^1.0.0 + run-async: ^3.0.0 + string-width: ^4.2.3 + strip-ansi: ^6.0.1 + wrap-ansi: ^6.0.1 + checksum: 78c46bed906b69c2c3512b009bb54cada1c1e6c2dafb54c039abdb3c99195d40c441d1acab9b55081345c61da58a8b6fa1b7456b8d3b112cb4d9eb008cacbe12 + languageName: node + linkType: hard + +"@inquirer/core@npm:^6.0.0": + version: 6.0.0 + resolution: "@inquirer/core@npm:6.0.0" + dependencies: + "@inquirer/type": ^1.1.6 + "@types/mute-stream": ^0.0.4 + "@types/node": ^20.10.7 + "@types/wrap-ansi": ^3.0.0 + ansi-escapes: ^4.3.2 + chalk: ^4.1.2 + cli-spinners: ^2.9.2 + cli-width: ^4.1.0 + figures: ^3.2.0 + mute-stream: ^1.0.0 + run-async: ^3.0.0 + signal-exit: ^4.1.0 + strip-ansi: ^6.0.1 + wrap-ansi: ^6.2.0 + checksum: 77a7185db6015ebcfb0429923be7da59f30b487204bb8692515c1059a79caad790da9915b0dea9eb9f6a9b1596e05edec98b5d57851f2180e84aba5f94077a2c + languageName: node + linkType: hard + +"@inquirer/editor@npm:^1.2.3": + version: 1.2.15 + resolution: "@inquirer/editor@npm:1.2.15" + dependencies: + "@inquirer/core": ^6.0.0 + "@inquirer/type": ^1.1.6 + chalk: ^4.1.2 + external-editor: ^3.1.0 + checksum: 84743b62c014d5da4d9e9d5b2ccf3bc99544aa4dd9e9e7059e6f88c76e6ddfba1b490b6a441ce3f3d16360b34a5b4d273120ba078d159a2aba75e7e34e0ed0f1 + languageName: node + linkType: hard + +"@inquirer/expand@npm:^1.1.4": + version: 1.1.16 + resolution: "@inquirer/expand@npm:1.1.16" + dependencies: + "@inquirer/core": ^6.0.0 + "@inquirer/type": ^1.1.6 + chalk: ^4.1.2 + figures: ^3.2.0 + checksum: 5158f8eb807bd1d55e7e7ca9288051f5947970b32b1a33cd9c94ea228c03cdb18508be5ecd0237061276721f5c9ca96741b3e2c288123c526cdd5049cdf566db + languageName: node + linkType: hard + +"@inquirer/input@npm:^1.2.4": + version: 1.2.16 + resolution: "@inquirer/input@npm:1.2.16" + dependencies: + "@inquirer/core": ^6.0.0 + "@inquirer/type": ^1.1.6 + chalk: ^4.1.2 + checksum: 35b4c414c12964989eb941e97fd2e27945869a2e8889a8131fa908687b0f09955f34fe4e50a075c2a1fc5034ea82ce96fa0a1da764d24f0127db0da68550378a + languageName: node + linkType: hard + +"@inquirer/password@npm:^1.1.4": + version: 1.1.16 + resolution: "@inquirer/password@npm:1.1.16" + dependencies: + "@inquirer/core": ^6.0.0 + "@inquirer/type": ^1.1.6 + ansi-escapes: ^4.3.2 + chalk: ^4.1.2 + checksum: d5a1b2ae68b462aa364543fe0cb8cfbaaf979a5997f6a1c4de02d9aec67b7326c09456205ebec4dd09f38c7c5f16c6655e5e9b1e6d01436e6270ad6e94f5d6a1 + languageName: node + linkType: hard + +"@inquirer/prompts@npm:^2.1.1": + version: 2.3.1 + resolution: "@inquirer/prompts@npm:2.3.1" + dependencies: + "@inquirer/checkbox": ^1.3.4 + "@inquirer/confirm": ^2.0.5 + "@inquirer/core": ^2.3.1 + "@inquirer/editor": ^1.2.3 + "@inquirer/expand": ^1.1.4 + "@inquirer/input": ^1.2.4 + "@inquirer/password": ^1.1.4 + "@inquirer/rawlist": ^1.2.4 + "@inquirer/select": ^1.2.4 + checksum: 8984f07d2c5a839a75a8f27908ecbab68724a7d4183906fa8079a1dae0bd5f56b7f2bb49ef0e575e141232b9f63d28b4b050f3eccb45ca3b1e6f40f8acc12880 + languageName: node + linkType: hard + +"@inquirer/rawlist@npm:^1.2.4": + version: 1.2.16 + resolution: "@inquirer/rawlist@npm:1.2.16" + dependencies: + "@inquirer/core": ^6.0.0 + "@inquirer/type": ^1.1.6 + chalk: ^4.1.2 + checksum: a4acefb0f54e4d4c3f7c44d35971cb0b8cbf2acd6dbe490576cd24369f3304ff4a36255cd4cc851c2de7c037cf70f71c129bc6c8c5c80dce495998e6168904fd + languageName: node + linkType: hard + +"@inquirer/select@npm:1.1.3": + version: 1.1.3 + resolution: "@inquirer/select@npm:1.1.3" + dependencies: + "@inquirer/core": ^1.1.3 + "@inquirer/type": ^1.0.3 + ansi-escapes: ^4.3.2 + chalk: ^4.1.2 + figures: ^3.2.0 + checksum: 509abfe3ab80f100cca30ad5c79893853187d289cc82ae2bd66f0c21bee79d2eb32b74e746f01c30648a81d7d4b637fea9f00fe4536967fa172250d37cc6a9a8 + languageName: node + linkType: hard + +"@inquirer/select@npm:^1.2.4": + version: 1.3.3 + resolution: "@inquirer/select@npm:1.3.3" + dependencies: + "@inquirer/core": ^6.0.0 + "@inquirer/type": ^1.1.6 + ansi-escapes: ^4.3.2 + chalk: ^4.1.2 + figures: ^3.2.0 + checksum: 0f33c51ab69c156b96092bfb107d08dd0f4227274917b9406aa23877e3ba94fd6738800fb973c44c051aaebdba72d07dc328df4b76e6e1285f68aa01a7ed0ed8 + languageName: node + linkType: hard + +"@inquirer/type@npm:^1.0.3, @inquirer/type@npm:^1.0.5, @inquirer/type@npm:^1.1.1, @inquirer/type@npm:^1.1.6": + version: 1.2.1 + resolution: "@inquirer/type@npm:1.2.1" + checksum: f7965acdd3c2c244e1470ae2724cf23c40afeaf2d8a01cfcb7f187d7a500715852988516a5744211c02f25efb52b70716b8d2311b0d703238bf62db6b0adb010 + languageName: node + linkType: hard + "@isaacs/cliui@npm:^8.0.2": version: 8.0.2 resolution: "@isaacs/cliui@npm:8.0.2" @@ -1576,6 +2170,13 @@ __metadata: languageName: node linkType: hard +"@noble/hashes@npm:^1.2.0": + version: 1.3.3 + resolution: "@noble/hashes@npm:1.3.3" + checksum: 8a6496d1c0c64797339bc694ad06cdfaa0f9e56cd0c3f68ae3666cfb153a791a55deb0af9c653c7ed2db64d537aa3e3054629740d2f2338bb1dcb7ab60cd205b + languageName: node + linkType: hard + "@noble/hashes@npm:~1.3.0, @noble/hashes@npm:~1.3.1": version: 1.3.2 resolution: "@noble/hashes@npm:1.3.2" @@ -1617,6 +2218,105 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/edr-darwin-arm64@npm:0.2.1": + version: 0.2.1 + resolution: "@nomicfoundation/edr-darwin-arm64@npm:0.2.1" + conditions: os=darwin & cpu=arm64 + languageName: node + linkType: hard + +"@nomicfoundation/edr-darwin-x64@npm:0.2.1": + version: 0.2.1 + resolution: "@nomicfoundation/edr-darwin-x64@npm:0.2.1" + conditions: os=darwin & cpu=x64 + languageName: node + linkType: hard + +"@nomicfoundation/edr-linux-arm64-gnu@npm:0.2.1": + version: 0.2.1 + resolution: "@nomicfoundation/edr-linux-arm64-gnu@npm:0.2.1" + conditions: os=linux & cpu=arm64 & libc=glibc + languageName: node + linkType: hard + +"@nomicfoundation/edr-linux-arm64-musl@npm:0.2.1": + version: 0.2.1 + resolution: "@nomicfoundation/edr-linux-arm64-musl@npm:0.2.1" + conditions: os=linux & cpu=arm64 & libc=musl + languageName: node + linkType: hard + +"@nomicfoundation/edr-linux-x64-gnu@npm:0.2.1": + version: 0.2.1 + resolution: "@nomicfoundation/edr-linux-x64-gnu@npm:0.2.1" + conditions: os=linux & cpu=x64 & libc=glibc + languageName: node + linkType: hard + +"@nomicfoundation/edr-linux-x64-musl@npm:0.2.1": + version: 0.2.1 + resolution: "@nomicfoundation/edr-linux-x64-musl@npm:0.2.1" + conditions: os=linux & cpu=x64 & libc=musl + languageName: node + linkType: hard + +"@nomicfoundation/edr-win32-arm64-msvc@npm:0.2.1": + version: 0.2.1 + resolution: "@nomicfoundation/edr-win32-arm64-msvc@npm:0.2.1" + conditions: os=win32 & cpu=arm64 + languageName: node + linkType: hard + +"@nomicfoundation/edr-win32-ia32-msvc@npm:0.2.1": + version: 0.2.1 + resolution: "@nomicfoundation/edr-win32-ia32-msvc@npm:0.2.1" + conditions: os=win32 & cpu=ia32 + languageName: node + linkType: hard + +"@nomicfoundation/edr-win32-x64-msvc@npm:0.2.1": + version: 0.2.1 + resolution: "@nomicfoundation/edr-win32-x64-msvc@npm:0.2.1" + conditions: os=win32 & cpu=x64 + languageName: node + linkType: hard + +"@nomicfoundation/edr@npm:^0.2.0": + version: 0.2.1 + resolution: "@nomicfoundation/edr@npm:0.2.1" + dependencies: + "@nomicfoundation/edr-darwin-arm64": 0.2.1 + "@nomicfoundation/edr-darwin-x64": 0.2.1 + "@nomicfoundation/edr-linux-arm64-gnu": 0.2.1 + "@nomicfoundation/edr-linux-arm64-musl": 0.2.1 + "@nomicfoundation/edr-linux-x64-gnu": 0.2.1 + "@nomicfoundation/edr-linux-x64-musl": 0.2.1 + "@nomicfoundation/edr-win32-arm64-msvc": 0.2.1 + "@nomicfoundation/edr-win32-ia32-msvc": 0.2.1 + "@nomicfoundation/edr-win32-x64-msvc": 0.2.1 + dependenciesMeta: + "@nomicfoundation/edr-darwin-arm64": + optional: true + "@nomicfoundation/edr-darwin-x64": + optional: true + "@nomicfoundation/edr-linux-arm64-gnu": + optional: true + "@nomicfoundation/edr-linux-arm64-musl": + optional: true + "@nomicfoundation/edr-linux-x64-gnu": + optional: true + "@nomicfoundation/edr-linux-x64-musl": + optional: true + "@nomicfoundation/edr-win32-arm64-msvc": + optional: true + "@nomicfoundation/edr-win32-ia32-msvc": + optional: true + "@nomicfoundation/edr-win32-x64-msvc": + optional: true + checksum: 74abad4a1094eb0474f1e809686f80f4e9c1c573a08ceba451515776b75ee90ac1437d2a0ff827bedd8f927e5e4b4a3ccf7ed10388a9f80cd3c58ce90153f0a0 + languageName: node + linkType: hard + "@nomicfoundation/ethereumjs-block@npm:4.2.2, @nomicfoundation/ethereumjs-block@npm:^4.0.0": version: 4.2.2 resolution: "@nomicfoundation/ethereumjs-block@npm:4.2.2" @@ -1661,6 +2361,15 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/ethereumjs-common@npm:4.0.4": + version: 4.0.4 + resolution: "@nomicfoundation/ethereumjs-common@npm:4.0.4" + dependencies: + "@nomicfoundation/ethereumjs-util": 9.0.4 + checksum: ce3f6e4ae15b976efdb7ccda27e19aadb62b5ffee209f9503e68b4fd8633715d4d697c0cc10ccd35f5e4e977edd05100d0f214e28880ec64fff77341dc34fcdf + languageName: node + linkType: hard + "@nomicfoundation/ethereumjs-ethash@npm:2.0.5": version: 2.0.5 resolution: "@nomicfoundation/ethereumjs-ethash@npm:2.0.5" @@ -1700,6 +2409,15 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/ethereumjs-rlp@npm:5.0.4": + version: 5.0.4 + resolution: "@nomicfoundation/ethereumjs-rlp@npm:5.0.4" + bin: + rlp: bin/rlp.cjs + checksum: ee2c2e5776c73801dc5ed636f4988b599b4563c2d0037da542ea57eb237c69dd1ac555f6bcb5e06f70515b6459779ba0d68252a6e105132b4659ab4bf62919b0 + languageName: node + linkType: hard + "@nomicfoundation/ethereumjs-statemanager@npm:1.0.5, @nomicfoundation/ethereumjs-statemanager@npm:^1.0.0": version: 1.0.5 resolution: "@nomicfoundation/ethereumjs-statemanager@npm:1.0.5" @@ -1739,6 +2457,23 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/ethereumjs-tx@npm:5.0.4": + version: 5.0.4 + resolution: "@nomicfoundation/ethereumjs-tx@npm:5.0.4" + dependencies: + "@nomicfoundation/ethereumjs-common": 4.0.4 + "@nomicfoundation/ethereumjs-rlp": 5.0.4 + "@nomicfoundation/ethereumjs-util": 9.0.4 + ethereum-cryptography: 0.1.3 + peerDependencies: + c-kzg: ^2.1.2 + peerDependenciesMeta: + c-kzg: + optional: true + checksum: 0f1c87716682ccbcf4d92ffc6cf8ab557e658b90319d82be3219a091a736859f8803c73c98e4863682e3e86d264751c472d33ff6d3c3daf4e75b5f01d0af8fa3 + languageName: node + linkType: hard + "@nomicfoundation/ethereumjs-util@npm:8.0.6, @nomicfoundation/ethereumjs-util@npm:^8.0.0, @nomicfoundation/ethereumjs-util@npm:^8.0.0-rc.3": version: 8.0.6 resolution: "@nomicfoundation/ethereumjs-util@npm:8.0.6" @@ -1749,6 +2484,21 @@ __metadata: languageName: node linkType: hard +"@nomicfoundation/ethereumjs-util@npm:9.0.4": + version: 9.0.4 + resolution: "@nomicfoundation/ethereumjs-util@npm:9.0.4" + dependencies: + "@nomicfoundation/ethereumjs-rlp": 5.0.4 + ethereum-cryptography: 0.1.3 + peerDependencies: + c-kzg: ^2.1.2 + peerDependenciesMeta: + c-kzg: + optional: true + checksum: 754439f72b11cad2d8986707ad020077dcc763c4055f73e2668a0b4cadb22aa4407faa9b3c587d9eb5b97ac337afbe037eb642bc1d5a16197284f83db3462cbe + languageName: node + linkType: hard + "@nomicfoundation/ethereumjs-vm@npm:^6.0.0, @nomicfoundation/ethereumjs-vm@npm:^6.0.0-rc.3": version: 6.4.2 resolution: "@nomicfoundation/ethereumjs-vm@npm:6.4.2" @@ -1901,7 +2651,7 @@ __metadata: languageName: node linkType: hard -"@nomiclabs/hardhat-ethers@npm:^2.0.5": +"@nomiclabs/hardhat-ethers@npm:^2.0.5, @nomiclabs/hardhat-ethers@npm:^2.2.3": version: 2.2.3 resolution: "@nomiclabs/hardhat-ethers@npm:2.2.3" peerDependencies: @@ -1953,6 +2703,13 @@ __metadata: languageName: node linkType: hard +"@openzeppelin/contracts@npm:^4.9.2": + version: 4.9.6 + resolution: "@openzeppelin/contracts@npm:4.9.6" + checksum: 274b6e968268294f12d5ca4f0278f6e6357792c8bb4d76664f83dbdc325f780541538a127e6a6e97e4f018088b42f65952014dec9c745c0fa25081f43ef9c4bf + languageName: node + linkType: hard + "@pkgjs/parseargs@npm:^0.11.0": version: 0.11.0 resolution: "@pkgjs/parseargs@npm:0.11.0" @@ -2479,6 +3236,24 @@ __metadata: languageName: node linkType: hard +"@types/mute-stream@npm:^0.0.1": + version: 0.0.1 + resolution: "@types/mute-stream@npm:0.0.1" + dependencies: + "@types/node": "*" + checksum: 01bb9f45a77b691538cba7f0c89166a5bfb112993056ae06a8218cd47d417a5f6a5cfc31f0d31293790c647d27564fe6aa39aa9cb2ef08792d42ed40f18de8d5 + languageName: node + linkType: hard + +"@types/mute-stream@npm:^0.0.4": + version: 0.0.4 + resolution: "@types/mute-stream@npm:0.0.4" + dependencies: + "@types/node": "*" + checksum: af8d83ad7b68ea05d9357985daf81b6c9b73af4feacb2f5c2693c7fd3e13e5135ef1bd083ce8d5bdc8e97acd28563b61bb32dec4e4508a8067fcd31b8a098632 + languageName: node + linkType: hard + "@types/node-fetch@npm:^2.6.1": version: 2.6.9 resolution: "@types/node-fetch@npm:2.6.9" @@ -2526,6 +3301,15 @@ __metadata: languageName: node linkType: hard +"@types/node@npm:^20.10.7, @types/node@npm:^20.4.2": + version: 20.11.27 + resolution: "@types/node@npm:20.11.27" + dependencies: + undici-types: ~5.26.4 + checksum: 24a134a3c18e7261b6d6385c2b7714b6cf93663f30d5df8ca95c649f9cef917a422d77bfd4a18b2c7d190d3a39f445b345ecd9ef6f994e61c7e92f400ecbe80f + languageName: node + linkType: hard + "@types/node@npm:^8.0.0": version: 8.10.66 resolution: "@types/node@npm:8.10.66" @@ -2604,6 +3388,13 @@ __metadata: languageName: node linkType: hard +"@types/wrap-ansi@npm:^3.0.0": + version: 3.0.0 + resolution: "@types/wrap-ansi@npm:3.0.0" + checksum: 492f0610093b5802f45ca292777679bb9b381f1f32ae939956dd9e00bf81dba7cc99979687620a2817d9a7d8b59928207698166c47a0861c6a2e5c30d4aaf1e9 + languageName: node + linkType: hard + "@typescript-eslint/eslint-plugin@npm:^5.20.0": version: 5.62.0 resolution: "@typescript-eslint/eslint-plugin@npm:5.62.0" @@ -2757,7 +3548,7 @@ __metadata: languageName: node linkType: hard -"@uniswap/v2-periphery@npm:1.1.0-beta.0": +"@uniswap/v2-periphery@npm:1.1.0-beta.0, @uniswap/v2-periphery@npm:^1.1.0-beta.0": version: 1.1.0-beta.0 resolution: "@uniswap/v2-periphery@npm:1.1.0-beta.0" dependencies: @@ -2767,6 +3558,33 @@ __metadata: languageName: node linkType: hard +"@zetachain/faucet-cli@npm:^4.0.1": + version: 4.1.0 + resolution: "@zetachain/faucet-cli@npm:4.1.0" + dependencies: + axios: 1.6.2 + commander: 10.0.1 + dayjs: 1.11.10 + ethers: 5.7.2 + figlet: 1.6.0 + launchdarkly-node-client-sdk: 3.0.2 + typescript: 5.0.4 + zod: 3.22.4 + bin: + zetafaucet: dist/cli.js + checksum: 53d1a04c9e9769ae85984226bcf5de4b401c040b8c58a391cb3371ea298a35d81bce536ff310389b36a6fc87d21ef6bb1deeb4d5665a54579a969309edbfef73 + languageName: node + linkType: hard + +"@zetachain/networks@npm:^3.0.0": + version: 3.0.1 + resolution: "@zetachain/networks@npm:3.0.1" + dependencies: + dotenv: ^16.1.4 + checksum: b017735d829935f67efc6b5ee9a6ed23ce41e236e13120eb5c45ca444715395fc200476603570468aa420a85db54052c7690cc2cb0462ea1a8b7222eb53c4557 + languageName: node + linkType: hard + "@zetachain/networks@npm:^4.0.0": version: 4.0.0 resolution: "@zetachain/networks@npm:4.0.0" @@ -2776,6 +3594,13 @@ __metadata: languageName: node linkType: hard +"@zetachain/protocol-contracts@npm:^3.0.2": + version: 3.0.2 + resolution: "@zetachain/protocol-contracts@npm:3.0.2" + checksum: 7e24b486da26bea9f37a5e81d2462947668ade3e81c0f955fa8509da179fcdf1ca2d4ef5fae1d9006343bf18919402770bedd16554454218a0df44980ed6b5df + languageName: node + linkType: hard + "@zetachain/protocol-contracts@npm:^4.0.1": version: 4.0.1 resolution: "@zetachain/protocol-contracts@npm:4.0.1" @@ -2783,6 +3608,40 @@ __metadata: languageName: node linkType: hard +"@zetachain/toolkit@npm:^5.0.0": + version: 5.0.0 + resolution: "@zetachain/toolkit@npm:5.0.0" + dependencies: + "@inquirer/prompts": ^2.1.1 + "@inquirer/select": 1.1.3 + "@nomiclabs/hardhat-ethers": ^2.2.3 + "@openzeppelin/contracts": ^4.9.2 + "@uniswap/v2-periphery": ^1.1.0-beta.0 + "@zetachain/faucet-cli": ^4.0.1 + "@zetachain/networks": ^3.0.0 + "@zetachain/protocol-contracts": ^3.0.2 + axios: ^1.4.0 + bech32: ^2.0.0 + bip39: ^3.1.0 + bitcoinjs-lib: ^6.1.3 + dotenv: 16.0.3 + ecpair: ^2.1.0 + envfile: ^6.18.0 + ethers: 5.4.7 + eventemitter3: ^5.0.1 + form-data: ^4.0.0 + handlebars: 4.7.7 + hardhat: ^2.15.0 + isomorphic-fetch: ^3.0.0 + moment: ^2.29.4 + ora: 5.4.1 + spinnies: ^0.5.1 + tiny-secp256k1: ^2.2.3 + ws: ^8.13.0 + checksum: 16f73a2d4ec12d46a4809094d7c1414e54a223bab587ddbb3a8743d1473eeb62637ae370df119f7e5d77c53e1434a7cc3d78a9a6f341675f3f130bf82d4ba95d + languageName: node + linkType: hard + "@zetachain/zeta-app-contracts@workspace:packages/zeta-app-contracts": version: 0.0.0-use.local resolution: "@zetachain/zeta-app-contracts@workspace:packages/zeta-app-contracts" @@ -2806,6 +3665,7 @@ __metadata: "@uniswap/v2-periphery": 1.1.0-beta.0 "@zetachain/networks": ^4.0.0 "@zetachain/protocol-contracts": ^4.0.1 + "@zetachain/toolkit": ^5.0.0 ethers: 5.6.8 hardhat-gas-reporter: ^1.0.8 solidity-coverage: ^0.7.20 @@ -3029,6 +3889,15 @@ __metadata: languageName: node linkType: hard +"ansi-align@npm:^3.0.0": + version: 3.0.1 + resolution: "ansi-align@npm:3.0.1" + dependencies: + string-width: ^4.1.0 + checksum: 6abfa08f2141d231c257162b15292467081fa49a208593e055c866aa0455b57f3a86b5a678c190c618faa79b4c59e254493099cb700dd9cf2293c6be2c8f5d8d + languageName: node + linkType: hard + "ansi-colors@npm:4.1.1": version: 4.1.1 resolution: "ansi-colors@npm:4.1.1" @@ -3043,7 +3912,7 @@ __metadata: languageName: node linkType: hard -"ansi-escapes@npm:^4.2.1, ansi-escapes@npm:^4.3.0": +"ansi-escapes@npm:^4.2.1, ansi-escapes@npm:^4.3.0, ansi-escapes@npm:^4.3.2": version: 4.3.2 resolution: "ansi-escapes@npm:4.3.2" dependencies: @@ -3059,6 +3928,13 @@ __metadata: languageName: node linkType: hard +"ansi-regex@npm:^4.1.0": + version: 4.1.1 + resolution: "ansi-regex@npm:4.1.1" + checksum: b1a6ee44cb6ecdabaa770b2ed500542714d4395d71c7e5c25baa631f680fb2ad322eb9ba697548d498a6fd366949fc8b5bfcf48d49a32803611f648005b01888 + languageName: node + linkType: hard + "ansi-regex@npm:^5.0.1": version: 5.0.1 resolution: "ansi-regex@npm:5.0.1" @@ -3373,7 +4249,7 @@ __metadata: languageName: node linkType: hard -"axios@npm:^1.5.1": +"axios@npm:1.6.2, axios@npm:^1.5.1": version: 1.6.2 resolution: "axios@npm:1.6.2" dependencies: @@ -3384,6 +4260,17 @@ __metadata: languageName: node linkType: hard +"axios@npm:^1.4.0": + version: 1.6.7 + resolution: "axios@npm:1.6.7" + dependencies: + follow-redirects: ^1.15.4 + form-data: ^4.0.0 + proxy-from-env: ^1.1.0 + checksum: 87d4d429927d09942771f3b3a6c13580c183e31d7be0ee12f09be6d5655304996bb033d85e54be81606f4e89684df43be7bf52d14becb73a12727bf33298a082 + languageName: node + linkType: hard + "balanced-match@npm:^1.0.0": version: 1.0.2 resolution: "balanced-match@npm:1.0.2" @@ -3400,7 +4287,14 @@ __metadata: languageName: node linkType: hard -"base64-js@npm:^1.3.1": +"base-x@npm:^4.0.0": + version: 4.0.0 + resolution: "base-x@npm:4.0.0" + checksum: b25db9e07eb1998472a20557c7f00c797dc0595f79df95155ab74274e7fa98b9f2659b3ee547ac8773666b7f69540656793aeb97ad2b1ceccdb6fa5faaf69ac0 + languageName: node + linkType: hard + +"base64-js@npm:^1.3.0, base64-js@npm:^1.3.1": version: 1.5.1 resolution: "base64-js@npm:1.5.1" checksum: 669632eb3745404c2f822a18fc3a0122d2f9a7a13f7fb8b5823ee19d1d2ff9ee5b52c53367176ea4ad093c332fd5ab4bd0ebae5a8e27917a4105a4cfc86b1005 @@ -3423,6 +4317,13 @@ __metadata: languageName: node linkType: hard +"bech32@npm:^2.0.0": + version: 2.0.0 + resolution: "bech32@npm:2.0.0" + checksum: fa15acb270b59aa496734a01f9155677b478987b773bf701f465858bf1606c6a970085babd43d71ce61895f1baa594cb41a2cd1394bd2c6698f03cc2d811300e + languageName: node + linkType: hard + "better-path-resolve@npm:1.0.0": version: 1.0.0 resolution: "better-path-resolve@npm:1.0.0" @@ -3462,6 +4363,13 @@ __metadata: languageName: node linkType: hard +"bip174@npm:^2.1.1": + version: 2.1.1 + resolution: "bip174@npm:2.1.1" + checksum: bc5b99e7d1acd9484aec117dc4d931a8b6d3a77ffb84e9672a9e8be2e41c22a3d41b4dad307cbe84091c6a30ee2ceaf8e1b3036b91201d4767d0772485ecb225 + languageName: node + linkType: hard + "bip39@npm:3.0.4": version: 3.0.4 resolution: "bip39@npm:3.0.4" @@ -3474,6 +4382,15 @@ __metadata: languageName: node linkType: hard +"bip39@npm:^3.1.0": + version: 3.1.0 + resolution: "bip39@npm:3.1.0" + dependencies: + "@noble/hashes": ^1.2.0 + checksum: 1224e763ffc6b097052ed8abd57f0e521ad6d31f1645be0d0a15f4417c13f8461f00e47e9cf7c8c784bd533f4fb1ee3ab020f258c7df45ee5dc722b4b0336cfc + languageName: node + linkType: hard + "bip66@npm:^1.1.5": version: 1.1.5 resolution: "bip66@npm:1.1.5" @@ -3483,6 +4400,20 @@ __metadata: languageName: node linkType: hard +"bitcoinjs-lib@npm:^6.1.3": + version: 6.1.5 + resolution: "bitcoinjs-lib@npm:6.1.5" + dependencies: + "@noble/hashes": ^1.2.0 + bech32: ^2.0.0 + bip174: ^2.1.1 + bs58check: ^3.0.1 + typeforce: ^1.11.3 + varuint-bitcoin: ^1.1.2 + checksum: c45580863efca0abecfcfea194d7e6d2abeec29a4c7928c77b4af57936b9908f0d85175aa2208232a568de9cfb8ef75d1acfb1283c98dc41da20fe8f1462bb86 + languageName: node + linkType: hard + "bl@npm:^4.1.0": version: 4.1.0 resolution: "bl@npm:4.1.0" @@ -3569,6 +4500,22 @@ __metadata: languageName: node linkType: hard +"boxen@npm:^5.1.2": + version: 5.1.2 + resolution: "boxen@npm:5.1.2" + dependencies: + ansi-align: ^3.0.0 + camelcase: ^6.2.0 + chalk: ^4.1.0 + cli-boxes: ^2.2.1 + string-width: ^4.2.2 + type-fest: ^0.20.2 + widest-line: ^3.1.0 + wrap-ansi: ^7.0.0 + checksum: 82d03e42a72576ff235123f17b7c505372fe05c83f75f61e7d4fa4bcb393897ec95ce766fecb8f26b915f0f7a7227d66e5ec7cef43f5b2bd9d3aeed47ec55877 + languageName: node + linkType: hard + "brace-expansion@npm:^1.1.7": version: 1.1.11 resolution: "brace-expansion@npm:1.1.11" @@ -3705,7 +4652,16 @@ __metadata: languageName: node linkType: hard -"bs58check@npm:^2.1.2": +"bs58@npm:^5.0.0": + version: 5.0.0 + resolution: "bs58@npm:5.0.0" + dependencies: + base-x: ^4.0.0 + checksum: 2475cb0684e07077521aac718e604a13e0f891d58cff923d437a2f7e9e28703ab39fce9f84c7c703ab369815a675f11e3bd394d38643bfe8969fbe42e6833d45 + languageName: node + linkType: hard + +"bs58check@npm:<3.0.0, bs58check@npm:^2.1.2": version: 2.1.2 resolution: "bs58check@npm:2.1.2" dependencies: @@ -3716,6 +4672,16 @@ __metadata: languageName: node linkType: hard +"bs58check@npm:^3.0.1": + version: 3.0.1 + resolution: "bs58check@npm:3.0.1" + dependencies: + "@noble/hashes": ^1.2.0 + bs58: ^5.0.0 + checksum: dbbecc7a09f3836e821149266c864c4bbd545539cea43c35f23f4c3c46b54c86c52b65d224b9ea2e916fa6d93bd2ce9fac5b6c6bfcf19621a9c209a5602f71c8 + languageName: node + linkType: hard + "buffer-from@npm:^1.0.0, buffer-from@npm:^1.1.0": version: 1.1.2 resolution: "buffer-from@npm:1.1.2" @@ -3893,7 +4859,7 @@ __metadata: languageName: node linkType: hard -"camelcase@npm:^6.0.0": +"camelcase@npm:^6.0.0, camelcase@npm:^6.2.0": version: 6.3.0 resolution: "camelcase@npm:6.3.0" checksum: 8c96818a9076434998511251dcb2761a94817ea17dbdc37f47ac080bd088fc62c7369429a19e2178b993497132c8cbcf5cc1f44ba963e76782ba469c0474938d @@ -4080,7 +5046,14 @@ __metadata: languageName: node linkType: hard -"cli-cursor@npm:^3.1.0": +"cli-boxes@npm:^2.2.1": + version: 2.2.1 + resolution: "cli-boxes@npm:2.2.1" + checksum: be79f8ec23a558b49e01311b39a1ea01243ecee30539c880cf14bf518a12e223ef40c57ead0cb44f509bffdffc5c129c746cd50d863ab879385370112af4f585 + languageName: node + linkType: hard + +"cli-cursor@npm:^3.0.0, cli-cursor@npm:^3.1.0": version: 3.1.0 resolution: "cli-cursor@npm:3.1.0" dependencies: @@ -4089,7 +5062,7 @@ __metadata: languageName: node linkType: hard -"cli-spinners@npm:^2.5.0": +"cli-spinners@npm:^2.5.0, cli-spinners@npm:^2.8.0, cli-spinners@npm:^2.9.2": version: 2.9.2 resolution: "cli-spinners@npm:2.9.2" checksum: 1bd588289b28432e4676cb5d40505cfe3e53f2e4e10fbe05c8a710a154d6fe0ce7836844b00d6858f740f2ffe67cdc36e0fce9c7b6a8430e80e6388d5aa4956c @@ -4117,6 +5090,13 @@ __metadata: languageName: node linkType: hard +"cli-width@npm:^4.0.0, cli-width@npm:^4.1.0": + version: 4.1.0 + resolution: "cli-width@npm:4.1.0" + checksum: 0a79cff2dbf89ef530bcd54c713703ba94461457b11e5634bd024c78796ed21401e32349c004995954e06f442d82609287e7aabf6a5f02c919a1cf3b9b6854ff + languageName: node + linkType: hard + "cliui@npm:^6.0.0": version: 6.0.0 resolution: "cliui@npm:6.0.0" @@ -4245,6 +5225,13 @@ __metadata: languageName: node linkType: hard +"commander@npm:10.0.1": + version: 10.0.1 + resolution: "commander@npm:10.0.1" + checksum: 436901d64a818295803c1996cd856621a74f30b9f9e28a588e726b2b1670665bccd7c1a77007ebf328729f0139838a88a19265858a0fa7a8728c4656796db948 + languageName: node + linkType: hard + "commander@npm:3.0.2": version: 3.0.2 resolution: "commander@npm:3.0.2" @@ -4526,6 +5513,13 @@ __metadata: languageName: node linkType: hard +"dayjs@npm:1.11.10": + version: 1.11.10 + resolution: "dayjs@npm:1.11.10" + checksum: a6b5a3813b8884f5cd557e2e6b7fa569f4c5d0c97aca9558e38534af4f2d60daafd3ff8c2000fed3435cfcec9e805bcebd99f90130c6d1c5ef524084ced588c4 + languageName: node + linkType: hard + "death@npm:^1.1.0": version: 1.1.0 resolution: "death@npm:1.1.0" @@ -4814,6 +5808,13 @@ __metadata: languageName: node linkType: hard +"dotenv@npm:16.0.3": + version: 16.0.3 + resolution: "dotenv@npm:16.0.3" + checksum: afcf03f373d7a6d62c7e9afea6328e62851d627a4e73f2e12d0a8deae1cd375892004f3021883f8aec85932cd2834b091f568ced92b4774625b321db83b827f8 + languageName: node + linkType: hard + "dotenv@npm:^16.0.0, dotenv@npm:^16.1.4": version: 16.3.1 resolution: "dotenv@npm:16.3.1" @@ -4856,6 +5857,17 @@ __metadata: languageName: node linkType: hard +"ecpair@npm:^2.1.0": + version: 2.1.0 + resolution: "ecpair@npm:2.1.0" + dependencies: + randombytes: ^2.1.0 + typeforce: ^1.18.0 + wif: ^2.0.6 + checksum: 924a776808f91d2fdd33a7033f84e3bbfe668ae98c0b9764c7b923e018accd8de57012bf20e419e0a5ef73ec3ec3738a654e71abe12f537b2fd7bcf02b93659f + languageName: node + linkType: hard + "ee-first@npm:1.1.1": version: 1.1.1 resolution: "ee-first@npm:1.1.1" @@ -4953,6 +5965,15 @@ __metadata: languageName: node linkType: hard +"envfile@npm:^6.18.0": + version: 6.22.0 + resolution: "envfile@npm:6.22.0" + bin: + envfile: bin.cjs + checksum: 95e29f82be5f1365bf3dc3b324576c5df69fbc9b28238cf876cff08124307693e49cf0d9df6ba8735d42b35b6f59ec01fda28435b839319652e9618a1430aa6b + languageName: node + linkType: hard + "err-code@npm:^2.0.2": version: 2.0.3 resolution: "err-code@npm:2.0.3" @@ -5708,6 +6729,44 @@ __metadata: languageName: node linkType: hard +"ethers@npm:5.4.7": + version: 5.4.7 + resolution: "ethers@npm:5.4.7" + dependencies: + "@ethersproject/abi": 5.4.1 + "@ethersproject/abstract-provider": 5.4.1 + "@ethersproject/abstract-signer": 5.4.1 + "@ethersproject/address": 5.4.0 + "@ethersproject/base64": 5.4.0 + "@ethersproject/basex": 5.4.0 + "@ethersproject/bignumber": 5.4.2 + "@ethersproject/bytes": 5.4.0 + "@ethersproject/constants": 5.4.0 + "@ethersproject/contracts": 5.4.1 + "@ethersproject/hash": 5.4.0 + "@ethersproject/hdnode": 5.4.0 + "@ethersproject/json-wallets": 5.4.0 + "@ethersproject/keccak256": 5.4.0 + "@ethersproject/logger": 5.4.1 + "@ethersproject/networks": 5.4.2 + "@ethersproject/pbkdf2": 5.4.0 + "@ethersproject/properties": 5.4.1 + "@ethersproject/providers": 5.4.5 + "@ethersproject/random": 5.4.0 + "@ethersproject/rlp": 5.4.0 + "@ethersproject/sha2": 5.4.0 + "@ethersproject/signing-key": 5.4.0 + "@ethersproject/solidity": 5.4.0 + "@ethersproject/strings": 5.4.0 + "@ethersproject/transactions": 5.4.0 + "@ethersproject/units": 5.4.0 + "@ethersproject/wallet": 5.4.0 + "@ethersproject/web": 5.4.0 + "@ethersproject/wordlists": 5.4.0 + checksum: 744d58c1c46c88ea6f713ab58436c3f2e1d976691842c021c0377fb22a647eaa64c603ef52273e9de5bdbfaf2831a191c6ae9efc4e78fb571453e9b9492c32a0 + languageName: node + linkType: hard + "ethers@npm:5.6.8": version: 5.6.8 resolution: "ethers@npm:5.6.8" @@ -5746,24 +6805,7 @@ __metadata: languageName: node linkType: hard -"ethers@npm:^4.0.32": - version: 4.0.49 - resolution: "ethers@npm:4.0.49" - dependencies: - aes-js: 3.0.0 - bn.js: ^4.11.9 - elliptic: 6.5.4 - hash.js: 1.1.3 - js-sha3: 0.5.7 - scrypt-js: 2.0.4 - setimmediate: 1.0.4 - uuid: 2.0.1 - xmlhttprequest: 1.8.0 - checksum: 357115348a5f1484c7745fae1d852876788216c7d94c072c80132192f1800c4d388433ea2456750856641d6d4eed8a3b41847eb44f5e1c42139963864e3bcc38 - languageName: node - linkType: hard - -"ethers@npm:^5.7.2": +"ethers@npm:5.7.2, ethers@npm:^5.7.2": version: 5.7.2 resolution: "ethers@npm:5.7.2" dependencies: @@ -5801,6 +6843,23 @@ __metadata: languageName: node linkType: hard +"ethers@npm:^4.0.32": + version: 4.0.49 + resolution: "ethers@npm:4.0.49" + dependencies: + aes-js: 3.0.0 + bn.js: ^4.11.9 + elliptic: 6.5.4 + hash.js: 1.1.3 + js-sha3: 0.5.7 + scrypt-js: 2.0.4 + setimmediate: 1.0.4 + uuid: 2.0.1 + xmlhttprequest: 1.8.0 + checksum: 357115348a5f1484c7745fae1d852876788216c7d94c072c80132192f1800c4d388433ea2456750856641d6d4eed8a3b41847eb44f5e1c42139963864e3bcc38 + languageName: node + linkType: hard + "ethjs-unit@npm:0.1.6": version: 0.1.6 resolution: "ethjs-unit@npm:0.1.6" @@ -5835,6 +6894,13 @@ __metadata: languageName: node linkType: hard +"eventemitter3@npm:^5.0.1": + version: 5.0.1 + resolution: "eventemitter3@npm:5.0.1" + checksum: 543d6c858ab699303c3c32e0f0f47fc64d360bf73c3daf0ac0b5079710e340d6fe9f15487f94e66c629f5f82cd1a8678d692f3dbb6f6fcd1190e1b97fcad36f8 + languageName: node + linkType: hard + "evp_bytestokey@npm:^1.0.0, evp_bytestokey@npm:^1.0.3": version: 1.0.3 resolution: "evp_bytestokey@npm:1.0.3" @@ -5940,6 +7006,13 @@ __metadata: languageName: node linkType: hard +"fast-deep-equal@npm:^2.0.1": + version: 2.0.1 + resolution: "fast-deep-equal@npm:2.0.1" + checksum: b701835a87985e0ec4925bdf1f0c1e7eb56309b5d12d534d5b4b69d95a54d65bb16861c081781ead55f73f12d6c60ba668713391ee7fbf6b0567026f579b7b0b + languageName: node + linkType: hard + "fast-deep-equal@npm:^3.1.1, fast-deep-equal@npm:^3.1.3": version: 3.1.3 resolution: "fast-deep-equal@npm:3.1.3" @@ -5990,7 +7063,16 @@ __metadata: languageName: node linkType: hard -"figures@npm:^3.0.0": +"figlet@npm:1.6.0": + version: 1.6.0 + resolution: "figlet@npm:1.6.0" + bin: + figlet: bin/index.js + checksum: 7455df4198ab4e260310a2f0bbd8970b8a6c757de16b40f451944eac2a3299f6935b1f40d1cf54d3235c147c9f65ae465533c054ecb7656c076b5cc6037d9274 + languageName: node + linkType: hard + +"figures@npm:^3.0.0, figures@npm:^3.2.0": version: 3.2.0 resolution: "figures@npm:3.2.0" dependencies: @@ -6124,6 +7206,16 @@ __metadata: languageName: node linkType: hard +"follow-redirects@npm:^1.15.4": + version: 1.15.5 + resolution: "follow-redirects@npm:1.15.5" + peerDependenciesMeta: + debug: + optional: true + checksum: 5ca49b5ce6f44338cbfc3546823357e7a70813cecc9b7b768158a1d32c1e62e7407c944402a918ea8c38ae2e78266312d617dc68783fac502cbb55e1047b34ec + languageName: node + linkType: hard + "for-each@npm:^0.3.3": version: 0.3.3 resolution: "for-each@npm:0.3.3" @@ -6718,7 +7810,7 @@ __metadata: languageName: node linkType: hard -"graceful-fs@npm:^4.1.2, graceful-fs@npm:^4.1.5, graceful-fs@npm:^4.1.6, graceful-fs@npm:^4.1.9, graceful-fs@npm:^4.2.0, graceful-fs@npm:^4.2.6": +"graceful-fs@npm:^4.1.11, graceful-fs@npm:^4.1.2, graceful-fs@npm:^4.1.5, graceful-fs@npm:^4.1.6, graceful-fs@npm:^4.1.9, graceful-fs@npm:^4.2.0, graceful-fs@npm:^4.2.6": version: 4.2.11 resolution: "graceful-fs@npm:4.2.11" checksum: ac85f94da92d8eb6b7f5a8b20ce65e43d66761c55ce85ac96df6865308390da45a8d3f0296dd3a663de65d30ba497bd46c696cc1e248c72b13d6d567138a4fc7 @@ -6739,6 +7831,24 @@ __metadata: languageName: node linkType: hard +"handlebars@npm:4.7.7": + version: 4.7.7 + resolution: "handlebars@npm:4.7.7" + dependencies: + minimist: ^1.2.5 + neo-async: ^2.6.0 + source-map: ^0.6.1 + uglify-js: ^3.1.4 + wordwrap: ^1.0.0 + dependenciesMeta: + uglify-js: + optional: true + bin: + handlebars: bin/handlebars + checksum: 1e79a43f5e18d15742977cb987923eab3e2a8f44f2d9d340982bcb69e1735ed049226e534d7c1074eaddaf37e4fb4f471a8adb71cddd5bc8cf3f894241df5cee + languageName: node + linkType: hard + "handlebars@npm:^4.0.1": version: 4.7.8 resolution: "handlebars@npm:4.7.8" @@ -6862,6 +7972,67 @@ __metadata: languageName: node linkType: hard +"hardhat@npm:^2.15.0": + version: 2.21.0 + resolution: "hardhat@npm:2.21.0" + dependencies: + "@ethersproject/abi": ^5.1.2 + "@metamask/eth-sig-util": ^4.0.0 + "@nomicfoundation/edr": ^0.2.0 + "@nomicfoundation/ethereumjs-common": 4.0.4 + "@nomicfoundation/ethereumjs-tx": 5.0.4 + "@nomicfoundation/ethereumjs-util": 9.0.4 + "@nomicfoundation/solidity-analyzer": ^0.1.0 + "@sentry/node": ^5.18.1 + "@types/bn.js": ^5.1.0 + "@types/lru-cache": ^5.1.0 + adm-zip: ^0.4.16 + aggregate-error: ^3.0.0 + ansi-escapes: ^4.3.0 + boxen: ^5.1.2 + chalk: ^2.4.2 + chokidar: ^3.4.0 + ci-info: ^2.0.0 + debug: ^4.1.1 + enquirer: ^2.3.0 + env-paths: ^2.2.0 + ethereum-cryptography: ^1.0.3 + ethereumjs-abi: ^0.6.8 + find-up: ^2.1.0 + fp-ts: 1.19.3 + fs-extra: ^7.0.1 + glob: 7.2.0 + immutable: ^4.0.0-rc.12 + io-ts: 1.10.4 + keccak: ^3.0.2 + lodash: ^4.17.11 + mnemonist: ^0.38.0 + mocha: ^10.0.0 + p-map: ^4.0.0 + raw-body: ^2.4.1 + resolve: 1.17.0 + semver: ^6.3.0 + solc: 0.7.3 + source-map-support: ^0.5.13 + stacktrace-parser: ^0.1.10 + tsort: 0.0.1 + undici: ^5.14.0 + uuid: ^8.3.2 + ws: ^7.4.6 + peerDependencies: + ts-node: "*" + typescript: "*" + peerDependenciesMeta: + ts-node: + optional: true + typescript: + optional: true + bin: + hardhat: internal/cli/bootstrap.js + checksum: cb5eadad5256a3a9d49a544f46d3b8c7927acc9f55049c2b7f61a017d7308fefa4cb687ce45972ce16643c3efc6ae64a0a572f6fcc791a1b8d4cfc9007c74b4c + languageName: node + linkType: hard + "has-bigints@npm:^1.0.1, has-bigints@npm:^1.0.2": version: 1.0.2 resolution: "has-bigints@npm:1.0.2" @@ -7598,6 +8769,16 @@ __metadata: languageName: node linkType: hard +"isomorphic-fetch@npm:^3.0.0": + version: 3.0.0 + resolution: "isomorphic-fetch@npm:3.0.0" + dependencies: + node-fetch: ^2.6.1 + whatwg-fetch: ^3.4.1 + checksum: e5ab79a56ce5af6ddd21265f59312ad9a4bc5a72cebc98b54797b42cb30441d5c5f8d17c5cd84a99e18101c8af6f90c081ecb8d12fd79e332be1778d58486d75 + languageName: node + linkType: hard + "isstream@npm:~0.1.2": version: 0.1.2 resolution: "isstream@npm:0.1.2" @@ -7893,6 +9074,37 @@ __metadata: languageName: node linkType: hard +"launchdarkly-eventsource@npm:1.4.3": + version: 1.4.3 + resolution: "launchdarkly-eventsource@npm:1.4.3" + dependencies: + original: ^1.0.2 + checksum: 764e1133d681f2de6900444e3194b6e5bbeb6ef25e06891a5fc7a2d58ba820f10861c9f2448b4e8af4b4b1b4db934444b1edf5be83dd69b484b444f04a8395ff + languageName: node + linkType: hard + +"launchdarkly-js-sdk-common@npm:5.0.3": + version: 5.0.3 + resolution: "launchdarkly-js-sdk-common@npm:5.0.3" + dependencies: + base64-js: ^1.3.0 + fast-deep-equal: ^2.0.1 + uuid: ^8.0.0 + checksum: 69f03217e1810f4a8a1d7f72035022902b96aa0fe4b6a45fe29b9430120a7becdb3540c3a0ffcf2044f88d62aaebef9bc1bb068a59ddc1cacfd447be988aa97f + languageName: node + linkType: hard + +"launchdarkly-node-client-sdk@npm:3.0.2": + version: 3.0.2 + resolution: "launchdarkly-node-client-sdk@npm:3.0.2" + dependencies: + launchdarkly-eventsource: 1.4.3 + launchdarkly-js-sdk-common: 5.0.3 + node-localstorage: ^1.3.1 + checksum: 569e840a75fbb7f5d975eb0055df9aedcb468c55440a19dab1b3b43a708ae6eb76055d5199bfdfc455bd52da447a642901526d81c981e0056bba5ef5a877fcaa + languageName: node + linkType: hard + "level-codec@npm:^9.0.0": version: 9.0.2 resolution: "level-codec@npm:9.0.2" @@ -8760,6 +9972,13 @@ __metadata: languageName: node linkType: hard +"moment@npm:^2.29.4": + version: 2.30.1 + resolution: "moment@npm:2.30.1" + checksum: 859236bab1e88c3e5802afcf797fc801acdbd0ee509d34ea3df6eea21eb6bcc2abd4ae4e4e64aa7c986aa6cba563c6e62806218e6412a765010712e5fa121ba6 + languageName: node + linkType: hard + "ms@npm:2.0.0": version: 2.0.0 resolution: "ms@npm:2.0.0" @@ -8838,6 +10057,13 @@ __metadata: languageName: node linkType: hard +"mute-stream@npm:^1.0.0": + version: 1.0.0 + resolution: "mute-stream@npm:1.0.0" + checksum: 36fc968b0e9c9c63029d4f9dc63911950a3bdf55c9a87f58d3a266289b67180201cade911e7699f8b2fa596b34c9db43dad37649e3f7fdd13c3bb9edb0017ee7 + languageName: node + linkType: hard + "nan@npm:^2.14.0, nan@npm:^2.2.1": version: 2.18.0 resolution: "nan@npm:2.18.0" @@ -8898,7 +10124,7 @@ __metadata: languageName: node linkType: hard -"neo-async@npm:^2.6.2": +"neo-async@npm:^2.6.0, neo-async@npm:^2.6.2": version: 2.6.2 resolution: "neo-async@npm:2.6.2" checksum: deac9f8d00eda7b2e5cd1b2549e26e10a0faa70adaa6fdadca701cc55f49ee9018e427f424bac0c790b7c7e2d3068db97f3093f1093975f2acb8f8818b936ed9 @@ -8930,7 +10156,7 @@ __metadata: languageName: node linkType: hard -"node-fetch@npm:^2.6.12, node-fetch@npm:^2.6.7": +"node-fetch@npm:^2.6.1, node-fetch@npm:^2.6.12, node-fetch@npm:^2.6.7": version: 2.7.0 resolution: "node-fetch@npm:2.7.0" dependencies: @@ -8997,6 +10223,15 @@ __metadata: languageName: node linkType: hard +"node-localstorage@npm:^1.3.1": + version: 1.3.1 + resolution: "node-localstorage@npm:1.3.1" + dependencies: + write-file-atomic: ^1.1.4 + checksum: adbeb54e63a16a13fc28ca92ca616a79da039822962d6d9c8d026779a9c9ddad9c40d848c324ea4472193dd1c06b48e153047ef45d3efd7741d13462ec0aec37 + languageName: node + linkType: hard + "nofilter@npm:^3.1.0": version: 3.1.0 resolution: "nofilter@npm:3.1.0" @@ -9214,7 +10449,7 @@ __metadata: languageName: node linkType: hard -"ora@npm:^5.4.1": +"ora@npm:5.4.1, ora@npm:^5.4.1": version: 5.4.1 resolution: "ora@npm:5.4.1" dependencies: @@ -9231,6 +10466,15 @@ __metadata: languageName: node linkType: hard +"original@npm:^1.0.2": + version: 1.0.2 + resolution: "original@npm:1.0.2" + dependencies: + url-parse: ^1.4.3 + checksum: 8dca9311dab50c8953366127cb86b7c07bf547d6aa6dc6873a75964b7563825351440557e5724d9c652c5e99043b8295624f106af077f84bccf19592e421beb9 + languageName: node + linkType: hard + "os-tmpdir@npm:~1.0.2": version: 1.0.2 resolution: "os-tmpdir@npm:1.0.2" @@ -9740,6 +10984,13 @@ __metadata: languageName: node linkType: hard +"querystringify@npm:^2.1.1": + version: 2.2.0 + resolution: "querystringify@npm:2.2.0" + checksum: 5641ea231bad7ef6d64d9998faca95611ed4b11c2591a8cae741e178a974f6a8e0ebde008475259abe1621cb15e692404e6b6626e927f7b849d5c09392604b15 + languageName: node + linkType: hard + "queue-microtask@npm:^1.2.2, queue-microtask@npm:^1.2.3": version: 1.2.3 resolution: "queue-microtask@npm:1.2.3" @@ -10015,6 +11266,13 @@ __metadata: languageName: node linkType: hard +"requires-port@npm:^1.0.0": + version: 1.0.0 + resolution: "requires-port@npm:1.0.0" + checksum: eee0e303adffb69be55d1a214e415cf42b7441ae858c76dfc5353148644f6fd6e698926fc4643f510d5c126d12a705e7c8ed7e38061113bdf37547ab356797ff + languageName: node + linkType: hard + "resolve-alpn@npm:^1.0.0, resolve-alpn@npm:^1.2.0": version: 1.2.1 resolution: "resolve-alpn@npm:1.2.1" @@ -10204,6 +11462,13 @@ __metadata: languageName: node linkType: hard +"run-async@npm:^3.0.0": + version: 3.0.0 + resolution: "run-async@npm:3.0.0" + checksum: 280c03d5a88603f48103fc6fd69f07fb0c392a1e0d319c34ec96a2516030e07ba06f79231a563c78698b882649c2fc1fda601bc84705f57d50efcd1fa506cfc0 + languageName: node + linkType: hard + "run-parallel-limit@npm:^1.1.0": version: 1.1.0 resolution: "run-parallel-limit@npm:1.1.0" @@ -10583,7 +11848,7 @@ __metadata: languageName: node linkType: hard -"signal-exit@npm:^4.0.1": +"signal-exit@npm:^4.0.1, signal-exit@npm:^4.1.0": version: 4.1.0 resolution: "signal-exit@npm:4.1.0" checksum: 64c757b498cb8629ffa5f75485340594d2f8189e9b08700e69199069c8e3070fb3e255f7ab873c05dc0b3cec412aea7402e10a5990cb6a050bd33ba062a6c549 @@ -10626,6 +11891,13 @@ __metadata: languageName: node linkType: hard +"slide@npm:^1.1.5": + version: 1.1.6 + resolution: "slide@npm:1.1.6" + checksum: 5768635d227172e215b7a1a91d32f8781f5783b4961feaaf3d536bbf83cc51878928c137508cde7659fea6d7c04074927cab982731302771ee0051518ff24896 + languageName: node + linkType: hard + "smart-buffer@npm:^4.2.0": version: 4.2.0 resolution: "smart-buffer@npm:4.2.0" @@ -10823,6 +12095,17 @@ __metadata: languageName: node linkType: hard +"spinnies@npm:^0.5.1": + version: 0.5.1 + resolution: "spinnies@npm:0.5.1" + dependencies: + chalk: ^2.4.2 + cli-cursor: ^3.0.0 + strip-ansi: ^5.2.0 + checksum: 7407c8cae31ff5868e56cfa12898e5a2db6f42b278c098637e28939d53ed6c7b0726027796c8e12bc6705f7dd5ec405d467c7cacf989d0beefca14c69440be77 + languageName: node + linkType: hard + "sprintf-js@npm:~1.0.2": version: 1.0.3 resolution: "sprintf-js@npm:1.0.3" @@ -10899,7 +12182,7 @@ __metadata: languageName: node linkType: hard -"string-width-cjs@npm:string-width@^4.2.0, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": +"string-width-cjs@npm:string-width@^4.2.0, string-width@npm:^4.0.0, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.2, string-width@npm:^4.2.3": version: 4.2.3 resolution: "string-width@npm:4.2.3" dependencies: @@ -11000,6 +12283,15 @@ __metadata: languageName: node linkType: hard +"strip-ansi@npm:^5.2.0": + version: 5.2.0 + resolution: "strip-ansi@npm:5.2.0" + dependencies: + ansi-regex: ^4.1.0 + checksum: bdb5f76ade97062bd88e7723aa019adbfacdcba42223b19ccb528ffb9fb0b89a5be442c663c4a3fb25268eaa3f6ea19c7c3fbae830bd1562d55adccae1fcec46 + languageName: node + linkType: hard + "strip-ansi@npm:^7.0.1": version: 7.1.0 resolution: "strip-ansi@npm:7.1.0" @@ -11224,6 +12516,15 @@ __metadata: languageName: node linkType: hard +"tiny-secp256k1@npm:^2.2.3": + version: 2.2.3 + resolution: "tiny-secp256k1@npm:2.2.3" + dependencies: + uint8array-tools: 0.0.7 + checksum: f7a74a1fceacab39d268907cd84798d3a07f3de2e00ba2557a043316ef45298d9acc96fb1614d72c728c3e512ecfef985b0fbd43b7fdb789fd9901df983e3e44 + languageName: node + linkType: hard + "tmp@npm:0.0.33, tmp@npm:^0.0.33": version: 0.0.33 resolution: "tmp@npm:0.0.33" @@ -11643,6 +12944,23 @@ __metadata: languageName: node linkType: hard +"typeforce@npm:^1.11.3, typeforce@npm:^1.18.0": + version: 1.18.0 + resolution: "typeforce@npm:1.18.0" + checksum: e3b21e27e76cb05f32285bef7c30a29760e79c622cfe4aa3c179ce49d1c7895b7154c8deedb9fe4599b1fd0428d35860d43e0776da1c04861168f3ad7ed99c70 + languageName: node + linkType: hard + +"typescript@npm:5.0.4": + version: 5.0.4 + resolution: "typescript@npm:5.0.4" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: 82b94da3f4604a8946da585f7d6c3025fff8410779e5bde2855ab130d05e4fd08938b9e593b6ebed165bda6ad9292b230984f10952cf82f0a0ca07bbeaa08172 + languageName: node + linkType: hard + "typescript@npm:^4.6.3": version: 4.9.5 resolution: "typescript@npm:4.9.5" @@ -11653,6 +12971,16 @@ __metadata: languageName: node linkType: hard +"typescript@patch:typescript@5.0.4#~builtin": + version: 5.0.4 + resolution: "typescript@patch:typescript@npm%3A5.0.4#~builtin::version=5.0.4&hash=bda367" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: 6a1fe9a77bb9c5176ead919cc4a1499ee63e46b4e05bf667079f11bf3a8f7887f135aa72460a4c3b016e6e6bb65a822cb8689a6d86cbfe92d22cc9f501f09213 + languageName: node + linkType: hard + "typescript@patch:typescript@^4.6.3#~builtin": version: 4.9.5 resolution: "typescript@patch:typescript@npm%3A4.9.5#~builtin::version=4.9.5&hash=bda367" @@ -11686,6 +13014,13 @@ __metadata: languageName: node linkType: hard +"uint8array-tools@npm:0.0.7": + version: 0.0.7 + resolution: "uint8array-tools@npm:0.0.7" + checksum: 6ffc45c7d2136757d63c6e556eb8345f908948618a9de37c805fec1249d989c265187b3fbef6cffc4ce5129083204829025b3c58800a0f24c8548e243d42ba13 + languageName: node + linkType: hard + "ultron@npm:~1.1.0": version: 1.1.1 resolution: "ultron@npm:1.1.1" @@ -11778,6 +13113,16 @@ __metadata: languageName: node linkType: hard +"url-parse@npm:^1.4.3": + version: 1.5.10 + resolution: "url-parse@npm:1.5.10" + dependencies: + querystringify: ^2.1.1 + requires-port: ^1.0.0 + checksum: fbdba6b1d83336aca2216bbdc38ba658d9cfb8fc7f665eb8b17852de638ff7d1a162c198a8e4ed66001ddbf6c9888d41e4798912c62b4fd777a31657989f7bdf + languageName: node + linkType: hard + "url-set-query@npm:^1.0.0": version: 1.0.0 resolution: "url-set-query@npm:1.0.0" @@ -11874,7 +13219,7 @@ __metadata: languageName: node linkType: hard -"uuid@npm:^8.3.2": +"uuid@npm:^8.0.0, uuid@npm:^8.3.2": version: 8.3.2 resolution: "uuid@npm:8.3.2" bin: @@ -11916,6 +13261,15 @@ __metadata: languageName: node linkType: hard +"varuint-bitcoin@npm:^1.1.2": + version: 1.1.2 + resolution: "varuint-bitcoin@npm:1.1.2" + dependencies: + safe-buffer: ^5.1.1 + checksum: 1c900bf08f2408ae33a6094dc5d809bdb6673eaf6039062d88c230155873e51e29c760053611f93ccd024854d04ebd92ed95c744720e94a79ca4e1150fcce071 + languageName: node + linkType: hard + "vary@npm:^1, vary@npm:~1.1.2": version: 1.1.2 resolution: "vary@npm:1.1.2" @@ -12521,6 +13875,13 @@ __metadata: languageName: node linkType: hard +"whatwg-fetch@npm:^3.4.1": + version: 3.6.20 + resolution: "whatwg-fetch@npm:3.6.20" + checksum: c58851ea2c4efe5c2235f13450f426824cf0253c1d45da28f45900290ae602a20aff2ab43346f16ec58917d5562e159cd691efa368354b2e82918c2146a519c5 + languageName: node + linkType: hard + "whatwg-url@npm:^5.0.0": version: 5.0.0 resolution: "whatwg-url@npm:5.0.0" @@ -12607,6 +13968,24 @@ __metadata: languageName: node linkType: hard +"widest-line@npm:^3.1.0": + version: 3.1.0 + resolution: "widest-line@npm:3.1.0" + dependencies: + string-width: ^4.0.0 + checksum: 03db6c9d0af9329c37d74378ff1d91972b12553c7d72a6f4e8525fe61563fa7adb0b9d6e8d546b7e059688712ea874edd5ded475999abdeedf708de9849310e0 + languageName: node + linkType: hard + +"wif@npm:^2.0.6": + version: 2.0.6 + resolution: "wif@npm:2.0.6" + dependencies: + bs58check: <3.0.0 + checksum: 8c3147ef98d56f394d66f0477f699fba7fc18dd0d1c2c5d0f8408be41acffed589fa82447d80eae5afc9a3cbd943bc3eebb337b9f114955adeaad02a244f4f9a + languageName: node + linkType: hard + "word-wrap@npm:~1.2.3": version: 1.2.5 resolution: "word-wrap@npm:1.2.5" @@ -12678,6 +14057,17 @@ __metadata: languageName: node linkType: hard +"write-file-atomic@npm:^1.1.4": + version: 1.3.4 + resolution: "write-file-atomic@npm:1.3.4" + dependencies: + graceful-fs: ^4.1.11 + imurmurhash: ^0.1.4 + slide: ^1.1.5 + checksum: ed5a1fc812abe99dd03cd42be145a5e13af42609e19873244510c71b2e261a169db6d06cb9a92b6b0489dd05f045e53bf464d9ad7713e443934af9b81a9cc65d + languageName: node + linkType: hard + "ws@npm:7.4.6": version: 7.4.6 resolution: "ws@npm:7.4.6" @@ -12719,6 +14109,21 @@ __metadata: languageName: node linkType: hard +"ws@npm:^8.13.0": + version: 8.16.0 + resolution: "ws@npm:8.16.0" + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: ">=5.0.2" + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + checksum: feb3eecd2bae82fa8a8beef800290ce437d8b8063bdc69712725f21aef77c49cb2ff45c6e5e7fce622248f9c7abaee506bae0a9064067ffd6935460c7357321b + languageName: node + linkType: hard + "xhr-request-promise@npm:^0.1.2": version: 0.1.3 resolution: "xhr-request-promise@npm:0.1.3" @@ -12975,3 +14380,10 @@ __metadata: typescript: ^4.6.3 languageName: unknown linkType: soft + +"zod@npm:3.22.4": + version: 3.22.4 + resolution: "zod@npm:3.22.4" + checksum: 80bfd7f8039b24fddeb0718a2ec7c02aa9856e4838d6aa4864335a047b6b37a3273b191ef335bf0b2002e5c514ef261ffcda5a589fb084a48c336ffc4cdbab7f + languageName: node + linkType: hard From 880e89d3cd5b9cb9ffb3b365902917bec2470311 Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Wed, 13 Mar 2024 16:06:59 -0300 Subject: [PATCH 06/12] add toolkit --- package.json | 1 + .../contracts/withdrawErc20/withdrawErc20.sol | 26 ++++++++-------- .../zevm-app-contracts/data/addresses.json | 3 +- packages/zevm-app-contracts/package.json | 1 - .../scripts/withdrawERC20/deploy.ts | 28 +++++++++++++++-- .../scripts/withdrawERC20/withdraw.ts | 31 +++++++++---------- .../test/withdrawERC20/withdrawERC20.ts | 7 +++-- yarn.lock | 2 +- 8 files changed, 61 insertions(+), 38 deletions(-) diff --git a/package.json b/package.json index 278681fe..7e621e50 100644 --- a/package.json +++ b/package.json @@ -39,6 +39,7 @@ "@types/node": "^17.0.25", "@typescript-eslint/eslint-plugin": "^5.20.0", "@typescript-eslint/parser": "^5.20.0", + "@zetachain/toolkit": "^5.0.0", "chai": "^4.3.6", "dotenv": "^16.0.0", "eslint": "^8.13.0", diff --git a/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol b/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol index c5dec015..8efea31c 100644 --- a/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol +++ b/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol @@ -3,7 +3,7 @@ pragma solidity 0.8.7; import "@zetachain/protocol-contracts/contracts/zevm/SystemContract.sol"; -// import "@zetachain/toolkit/contracts/SwapHelperLib.sol"; +import "@zetachain/toolkit/contracts/SwapHelperLib.sol"; contract WithdrawERC20 { SystemContract public immutable systemContract; @@ -17,17 +17,17 @@ contract WithdrawERC20 { (address gasZRC20, uint256 gasFee) = IZRC20(zrc20).withdrawGasFee(); - // uint256 inputForGas = SwapHelperLib.swapTokensForExactTokens( - // systemContract.wZetaContractAddress(), - // systemContract.uniswapv2FactoryAddress(), - // systemContract.uniswapv2Router02Address(), - // zrc20, - // gasFee, - // gasZRC20, - // amount - // ); - - // IZRC20(gasZRC20).approve(zrc20, gasFee); - // IZRC20(zrc20).withdraw(to, amount - inputForGas); + uint256 inputForGas = SwapHelperLib.swapTokensForExactTokens( + systemContract.wZetaContractAddress(), + systemContract.uniswapv2FactoryAddress(), + systemContract.uniswapv2Router02Address(), + zrc20, + gasFee, + gasZRC20, + amount + ); + + IZRC20(gasZRC20).approve(zrc20, gasFee); + IZRC20(zrc20).withdraw(to, amount - inputForGas); } } diff --git a/packages/zevm-app-contracts/data/addresses.json b/packages/zevm-app-contracts/data/addresses.json index bd53a842..6b538d1c 100644 --- a/packages/zevm-app-contracts/data/addresses.json +++ b/packages/zevm-app-contracts/data/addresses.json @@ -5,7 +5,8 @@ "rewardDistributorFactory": "0xB9dc665610CF5109cE23aBBdaAc315B41FA094c1", "zetaSwap": "0xA8168Dc495Ed61E70f5c1941e2860050AB902cEF", "zetaSwapBtcInbound": "0x358E2cfC0E16444Ba7D3164Bbeeb6bEA7472c559", - "invitationManager": "0x3649C03C472B698213926543456E9c21081e529d" + "invitationManager": "0x3649C03C472B698213926543456E9c21081e529d", + "withdrawERC20": "0xB5De3Eb98e29853a99adA24029786aa670f6D580" } } } \ No newline at end of file diff --git a/packages/zevm-app-contracts/package.json b/packages/zevm-app-contracts/package.json index 7648d960..c836f53e 100644 --- a/packages/zevm-app-contracts/package.json +++ b/packages/zevm-app-contracts/package.json @@ -38,7 +38,6 @@ "@uniswap/v2-periphery": "1.1.0-beta.0", "@zetachain/networks": "^4.0.0", "@zetachain/protocol-contracts": "^4.0.1", - "@zetachain/toolkit": "^5.0.0", "ethers": "5.6.8" } } diff --git a/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts b/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts index f16fed9d..ed16b0bd 100644 --- a/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts +++ b/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts @@ -1,21 +1,43 @@ import { isProtocolNetworkName } from "@zetachain/protocol-contracts"; import { ethers, network } from "hardhat"; -import { WithdrawERC20__factory } from "../../typechain-types"; -import { saveAddress } from "../address.helpers"; +import { ERC20__factory } from "../../typechain-types"; +import { WithdrawERC20__factory } from "../../typechain-types/factories/contracts/withdrawErc20/withdrawErc20.sol"; +import { getSystemContractAddress, saveAddress } from "../address.helpers"; const networkName = network.name; +const SYSTEM_CONTRACT = getSystemContractAddress(); + +const ZUSDC_ADDRESS = "0x0cbe0dF132a6c6B4a2974Fa1b7Fb953CF0Cc798a"; +const AMOUNT = ethers.utils.parseUnits("0.5", 6); + async function main() { if (!isProtocolNetworkName(networkName)) throw new Error("Invalid network name"); const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; - const withdrawERC20 = await WithdrawERC20Factory.deploy(); + const withdrawERC20 = await WithdrawERC20Factory.deploy(SYSTEM_CONTRACT); await withdrawERC20.deployed(); console.log("WithdrawERC20 deployed to:", withdrawERC20.address); saveAddress("withdrawERC20", withdrawERC20.address, networkName); + { + const [signer] = await ethers.getSigners(); + const withdrawERC20Address = withdrawERC20.address; + + const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; + const WithdrawERC20 = WithdrawERC20Factory.attach(withdrawERC20Address); + + const ERC20Factory = (await ethers.getContractFactory("ERC20")) as ERC20__factory; + const erc20 = ERC20Factory.attach(ZUSDC_ADDRESS); + + await erc20.approve(WithdrawERC20.address, AMOUNT); + const tx = await WithdrawERC20.withdraw(erc20.address, AMOUNT, signer.address); + console.log(`Sending transaction ${tx.hash}`); + const receipt = await tx.wait(); + console.log(receipt); + } } main().catch((error) => { diff --git a/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts b/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts index 098d7bab..3428ed23 100644 --- a/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts +++ b/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts @@ -1,31 +1,30 @@ import { isProtocolNetworkName } from "@zetachain/protocol-contracts"; import { ethers, network } from "hardhat"; -import { ERC20__factory, WithdrawERC20__factory } from "../../typechain-types"; -import { saveAddress } from "../address.helpers"; +import { ERC20__factory } from "../../typechain-types"; +import { WithdrawERC20__factory } from "../../typechain-types/factories/contracts/withdrawErc20/withdrawErc20.sol"; +import { getZEVMAppAddress } from "../address.helpers"; const networkName = network.name; +const ZUSDC_ADDRESS = "0x0cbe0dF132a6c6B4a2974Fa1b7Fb953CF0Cc798a"; +const AMOUNT = ethers.utils.parseUnits("5", 6); + async function main() { if (!isProtocolNetworkName(networkName)) throw new Error("Invalid network name"); - const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; + const [signer] = await ethers.getSigners(); + const withdrawERC20Address = getZEVMAppAddress("withdrawERC20"); - // const withdrawERC20 = await WithdrawERC20Factory.deploy(); - // await withdrawERC20.deployed(); - // console.log("WithdrawERC20 deployed to:", withdrawERC20.address); - // saveAddress("withdrawERC20", withdrawERC20.address); + const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; + const WithdrawERC20 = WithdrawERC20Factory.attach(withdrawERC20Address); - const WithdrawERC20 = WithdrawERC20Factory.attach("0x16a790cf206bbcd30cb2e36cc7b1f890d260b80c"); const ERC20Factory = (await ethers.getContractFactory("ERC20")) as ERC20__factory; - const erc20 = ERC20Factory.attach("0x0cbe0dF132a6c6B4a2974Fa1b7Fb953CF0Cc798a"); - - await erc20.approve(WithdrawERC20.address, ethers.utils.parseUnits("5", 6)); - await WithdrawERC20.withdraw( - erc20.address, - ethers.utils.parseUnits("5", 6), - "0x19caCb4c0A7fC25598CC44564ED0eCA01249fc31" - ); + const erc20 = ERC20Factory.attach(ZUSDC_ADDRESS); + + await erc20.approve(WithdrawERC20.address, AMOUNT); + const tx = await WithdrawERC20.withdraw(erc20.address, AMOUNT, signer.address); + console.log(`Sending transaction ${tx.hash}`); } main().catch((error) => { diff --git a/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts b/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts index 6cfac71a..c032daa5 100644 --- a/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts +++ b/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts @@ -4,7 +4,8 @@ import { expect } from "chai"; import { parseEther } from "ethers/lib/utils"; import { ethers, network } from "hardhat"; -import { Disperse, Disperse__factory, MockZRC20, MockZRC20__factory } from "../typechain-types"; +import { WithdrawERC20 } from "../../typechain-types/contracts/withdrawErc20/withdrawErc20.sol"; +import { WithdrawERC20__factory } from "../../typechain-types/factories/contracts/withdrawErc20/withdrawErc20.sol"; describe("WithdrawERC20 tests", () => { let withdrawERC20Contract: WithdrawERC20; @@ -17,8 +18,8 @@ describe("WithdrawERC20 tests", () => { await network.provider.send("hardhat_setBalance", [deployer.address, parseUnits("1000000").toHexString()]); - const DisperseFactory = (await ethers.getContractFactory("Disperse")) as Disperse__factory; - withdrawERC20Contract = (await DisperseFactory.deploy()) as Disperse; + const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; + withdrawERC20Contract = (await WithdrawERC20Factory.deploy()) as WithdrawERC20; await withdrawERC20Contract.deployed(); }); diff --git a/yarn.lock b/yarn.lock index 1ea174fb..ca5b69d7 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3665,7 +3665,6 @@ __metadata: "@uniswap/v2-periphery": 1.1.0-beta.0 "@zetachain/networks": ^4.0.0 "@zetachain/protocol-contracts": ^4.0.1 - "@zetachain/toolkit": ^5.0.0 ethers: 5.6.8 hardhat-gas-reporter: ^1.0.8 solidity-coverage: ^0.7.20 @@ -14354,6 +14353,7 @@ __metadata: "@types/node": ^17.0.25 "@typescript-eslint/eslint-plugin": ^5.20.0 "@typescript-eslint/parser": ^5.20.0 + "@zetachain/toolkit": ^5.0.0 chai: ^4.3.6 dotenv: ^16.0.0 eslint: ^8.13.0 From 30bb3cc5b48c01ebcf96b00c501274c8735a0be8 Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Thu, 14 Mar 2024 12:23:02 -0300 Subject: [PATCH 07/12] deployment --- .../zevm-app-contracts/data/addresses.json | 2 +- .../scripts/withdrawERC20/deploy.ts | 20 ------------------- .../scripts/withdrawERC20/withdraw.ts | 2 +- 3 files changed, 2 insertions(+), 22 deletions(-) diff --git a/packages/zevm-app-contracts/data/addresses.json b/packages/zevm-app-contracts/data/addresses.json index 6b538d1c..192bddbe 100644 --- a/packages/zevm-app-contracts/data/addresses.json +++ b/packages/zevm-app-contracts/data/addresses.json @@ -6,7 +6,7 @@ "zetaSwap": "0xA8168Dc495Ed61E70f5c1941e2860050AB902cEF", "zetaSwapBtcInbound": "0x358E2cfC0E16444Ba7D3164Bbeeb6bEA7472c559", "invitationManager": "0x3649C03C472B698213926543456E9c21081e529d", - "withdrawERC20": "0xB5De3Eb98e29853a99adA24029786aa670f6D580" + "withdrawERC20": "0xB958746620Aa3E6F83B4cF2eA371fe475190A632" } } } \ No newline at end of file diff --git a/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts b/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts index ed16b0bd..2680458a 100644 --- a/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts +++ b/packages/zevm-app-contracts/scripts/withdrawERC20/deploy.ts @@ -1,7 +1,6 @@ import { isProtocolNetworkName } from "@zetachain/protocol-contracts"; import { ethers, network } from "hardhat"; -import { ERC20__factory } from "../../typechain-types"; import { WithdrawERC20__factory } from "../../typechain-types/factories/contracts/withdrawErc20/withdrawErc20.sol"; import { getSystemContractAddress, saveAddress } from "../address.helpers"; @@ -9,9 +8,6 @@ const networkName = network.name; const SYSTEM_CONTRACT = getSystemContractAddress(); -const ZUSDC_ADDRESS = "0x0cbe0dF132a6c6B4a2974Fa1b7Fb953CF0Cc798a"; -const AMOUNT = ethers.utils.parseUnits("0.5", 6); - async function main() { if (!isProtocolNetworkName(networkName)) throw new Error("Invalid network name"); @@ -22,22 +18,6 @@ async function main() { console.log("WithdrawERC20 deployed to:", withdrawERC20.address); saveAddress("withdrawERC20", withdrawERC20.address, networkName); - { - const [signer] = await ethers.getSigners(); - const withdrawERC20Address = withdrawERC20.address; - - const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; - const WithdrawERC20 = WithdrawERC20Factory.attach(withdrawERC20Address); - - const ERC20Factory = (await ethers.getContractFactory("ERC20")) as ERC20__factory; - const erc20 = ERC20Factory.attach(ZUSDC_ADDRESS); - - await erc20.approve(WithdrawERC20.address, AMOUNT); - const tx = await WithdrawERC20.withdraw(erc20.address, AMOUNT, signer.address); - console.log(`Sending transaction ${tx.hash}`); - const receipt = await tx.wait(); - console.log(receipt); - } } main().catch((error) => { diff --git a/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts b/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts index 3428ed23..a74413b4 100644 --- a/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts +++ b/packages/zevm-app-contracts/scripts/withdrawERC20/withdraw.ts @@ -8,7 +8,7 @@ import { getZEVMAppAddress } from "../address.helpers"; const networkName = network.name; const ZUSDC_ADDRESS = "0x0cbe0dF132a6c6B4a2974Fa1b7Fb953CF0Cc798a"; -const AMOUNT = ethers.utils.parseUnits("5", 6); +const AMOUNT = ethers.utils.parseUnits("0.5", 6); async function main() { if (!isProtocolNetworkName(networkName)) throw new Error("Invalid network name"); From 362da2e1cb46ce6c137e2135e64ec972c754911a Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Thu, 14 Mar 2024 16:22:16 -0300 Subject: [PATCH 08/12] remove test --- .../test/withdrawERC20/withdrawERC20.ts | 106 ------------------ 1 file changed, 106 deletions(-) delete mode 100644 packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts diff --git a/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts b/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts deleted file mode 100644 index c032daa5..00000000 --- a/packages/zevm-app-contracts/test/withdrawERC20/withdrawERC20.ts +++ /dev/null @@ -1,106 +0,0 @@ -import { parseUnits } from "@ethersproject/units"; -import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; -import { expect } from "chai"; -import { parseEther } from "ethers/lib/utils"; -import { ethers, network } from "hardhat"; - -import { WithdrawERC20 } from "../../typechain-types/contracts/withdrawErc20/withdrawErc20.sol"; -import { WithdrawERC20__factory } from "../../typechain-types/factories/contracts/withdrawErc20/withdrawErc20.sol"; - -describe("WithdrawERC20 tests", () => { - let withdrawERC20Contract: WithdrawERC20; - - let accounts: SignerWithAddress[]; - let deployer: SignerWithAddress; - - beforeEach(async () => { - [deployer, ...accounts] = await ethers.getSigners(); - - await network.provider.send("hardhat_setBalance", [deployer.address, parseUnits("1000000").toHexString()]); - - const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; - withdrawERC20Contract = (await WithdrawERC20Factory.deploy()) as WithdrawERC20; - await withdrawERC20Contract.deployed(); - }); - - describe("Disperse", () => { - it("Should disperse ETH", async () => { - const count = 500; - const amount = parseEther("0.01"); - const balance0 = await ethers.provider.getBalance(accounts[0].address); - const balance1 = await ethers.provider.getBalance(accounts[1].address); - - const bigArrayAddress = new Array(count).fill(accounts[0].address); - const bigArrayAmount = new Array(count).fill(amount); - - await withdrawERC20Contract.disperseEther(bigArrayAddress, bigArrayAmount, { - value: amount.mul(count), - }); - - const balance0After = await ethers.provider.getBalance(accounts[0].address); - const balance1After = await ethers.provider.getBalance(accounts[1].address); - - expect(balance0After.sub(balance0)).to.be.eq(amount.mul(count)); - expect(balance1After.sub(balance1)).to.be.eq(0); - }); - - it("Should disperse ETH with surplus", async () => { - const amount = parseUnits("10"); - const balance0 = await ethers.provider.getBalance(accounts[0].address); - const balance1 = await ethers.provider.getBalance(accounts[1].address); - await withdrawERC20Contract.disperseEther([accounts[0].address, accounts[1].address], [amount, amount.mul(2)], { - value: amount.mul(4), - }); - - const balance0After = await ethers.provider.getBalance(accounts[0].address); - const balance1After = await ethers.provider.getBalance(accounts[1].address); - - expect(balance0After.sub(balance0)).to.be.eq(amount); - expect(balance1After.sub(balance1)).to.be.eq(amount.mul(2)); - }); - - it("Should disperse token", async () => { - const MockTokenFactory = (await ethers.getContractFactory("MockZRC20")) as MockZRC20__factory; - const mockTokenContract = (await MockTokenFactory.deploy(1_000_000, "MOCK", "MOCK")) as MockZRC20; - await mockTokenContract.deployed(); - await mockTokenContract.approve(withdrawERC20Contract.address, parseUnits("1000000")); - - const amount = parseUnits("10"); - const balance0 = await mockTokenContract.balanceOf(accounts[0].address); - const balance1 = await mockTokenContract.balanceOf(accounts[1].address); - await withdrawERC20Contract.disperseToken( - mockTokenContract.address, - [accounts[0].address, accounts[1].address], - [amount, amount.mul(2)] - ); - - const balance0After = await mockTokenContract.balanceOf(accounts[0].address); - const balance1After = await mockTokenContract.balanceOf(accounts[1].address); - - expect(balance0After.sub(balance0)).to.be.eq(amount); - expect(balance1After.sub(balance1)).to.be.eq(amount.mul(2)); - }); - - it("Should disperse token simple", async () => { - const MockTokenFactory = (await ethers.getContractFactory("MockZRC20")) as MockZRC20__factory; - const mockTokenContract = (await MockTokenFactory.deploy(1_000_000, "MOCK", "MOCK")) as MockZRC20; - await mockTokenContract.deployed(); - await mockTokenContract.approve(withdrawERC20Contract.address, parseUnits("1000000")); - - const amount = parseUnits("10"); - const balance0 = await mockTokenContract.balanceOf(accounts[0].address); - const balance1 = await mockTokenContract.balanceOf(accounts[1].address); - await withdrawERC20Contract.disperseTokenSimple( - mockTokenContract.address, - [accounts[0].address, accounts[1].address], - [amount, amount.mul(2)] - ); - - const balance0After = await mockTokenContract.balanceOf(accounts[0].address); - const balance1After = await mockTokenContract.balanceOf(accounts[1].address); - - expect(balance0After.sub(balance0)).to.be.eq(amount); - expect(balance1After.sub(balance1)).to.be.eq(amount.mul(2)); - }); - }); -}); From fb3cfd8c546f5e374b0927e0a2aaa8b52f2659e0 Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Fri, 15 Mar 2024 16:11:15 -0300 Subject: [PATCH 09/12] add test --- .../contracts/shared/MockZRC20.sol | 19 ++++- .../contracts/withdrawErc20/withdrawErc20.sol | 4 + .../zevm-app-contracts/data/addresses.json | 2 +- .../zevm-app-contracts/test/Withdraw.spec.ts | 76 +++++++++++++++++++ .../zevm-app-contracts/test/test.helpers.ts | 8 +- 5 files changed, 104 insertions(+), 5 deletions(-) create mode 100644 packages/zevm-app-contracts/test/Withdraw.spec.ts diff --git a/packages/zevm-app-contracts/contracts/shared/MockZRC20.sol b/packages/zevm-app-contracts/contracts/shared/MockZRC20.sol index 49f5f334..c74b0d23 100644 --- a/packages/zevm-app-contracts/contracts/shared/MockZRC20.sol +++ b/packages/zevm-app-contracts/contracts/shared/MockZRC20.sol @@ -7,8 +7,22 @@ import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "./BytesHelperLib.sol"; contract MockZRC20 is ERC20 { + address public gasFeeAddress; + uint256 public gasFee; + + event Withdrawal(address indexed from, bytes to, uint256 value, uint256 gasfee, uint256 protocolFlatFee); + constructor(uint256 initialSupply, string memory name, string memory symbol) ERC20(name, symbol) { _mint(msg.sender, initialSupply * (10 ** uint256(decimals()))); + gasFeeAddress = address(this); + } + + function setGasFeeAddress(address gasFeeAddress_) external { + gasFeeAddress = gasFeeAddress_; + } + + function setGasFee(uint256 gasFee_) external { + gasFee = gasFee_; } function deposit(address to, uint256 amount) external returns (bool) { @@ -23,11 +37,12 @@ contract MockZRC20 is ERC20 { } function withdraw(bytes calldata to, uint256 amount) external returns (bool) { - address toAddress = BytesHelperLib.bytesToAddress(to, 12); + address toAddress = BytesHelperLib.bytesToAddress(to, 0); + emit Withdrawal(msg.sender, to, amount, gasFee, 0); return transfer(toAddress, amount); } function withdrawGasFee() external view returns (address, uint256) { - return (address(this), 0); + return (gasFeeAddress, gasFee); } } diff --git a/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol b/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol index 8efea31c..ab84e65e 100644 --- a/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol +++ b/packages/zevm-app-contracts/contracts/withdrawErc20/withdrawErc20.sol @@ -8,6 +8,8 @@ import "@zetachain/toolkit/contracts/SwapHelperLib.sol"; contract WithdrawERC20 { SystemContract public immutable systemContract; + error InsufficientInputAmount(); + constructor(address systemContractAddress) { systemContract = SystemContract(systemContractAddress); } @@ -27,6 +29,8 @@ contract WithdrawERC20 { amount ); + if (inputForGas > amount) revert InsufficientInputAmount(); + IZRC20(gasZRC20).approve(zrc20, gasFee); IZRC20(zrc20).withdraw(to, amount - inputForGas); } diff --git a/packages/zevm-app-contracts/data/addresses.json b/packages/zevm-app-contracts/data/addresses.json index 192bddbe..83d5c063 100644 --- a/packages/zevm-app-contracts/data/addresses.json +++ b/packages/zevm-app-contracts/data/addresses.json @@ -6,7 +6,7 @@ "zetaSwap": "0xA8168Dc495Ed61E70f5c1941e2860050AB902cEF", "zetaSwapBtcInbound": "0x358E2cfC0E16444Ba7D3164Bbeeb6bEA7472c559", "invitationManager": "0x3649C03C472B698213926543456E9c21081e529d", - "withdrawERC20": "0xB958746620Aa3E6F83B4cF2eA371fe475190A632" + "withdrawERC20": "0xa349B9367cc54b47CAb8D09A95836AE8b4D1d84E" } } } \ No newline at end of file diff --git a/packages/zevm-app-contracts/test/Withdraw.spec.ts b/packages/zevm-app-contracts/test/Withdraw.spec.ts new file mode 100644 index 00000000..24a1ae74 --- /dev/null +++ b/packages/zevm-app-contracts/test/Withdraw.spec.ts @@ -0,0 +1,76 @@ +import { parseUnits } from "@ethersproject/units"; +import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; +import { getNonZetaAddress } from "@zetachain/protocol-contracts"; +import { expect } from "chai"; +import { parseEther } from "ethers/lib/utils"; +import { ethers, network } from "hardhat"; + +import { MockSystemContract, MockZRC20 } from "../typechain-types"; +import { WithdrawalEvent } from "../typechain-types/contracts/shared/MockZRC20"; +import { WithdrawERC20 } from "../typechain-types/contracts/withdrawErc20/withdrawErc20.sol"; +import { WithdrawERC20__factory } from "../typechain-types/factories/contracts/withdrawErc20/withdrawErc20.sol"; +import { evmSetup } from "./test.helpers"; + +describe("Withdraw tests", () => { + let withdrawERC20Contract: WithdrawERC20; + let ZRC20Contracts: MockZRC20[]; + let mockUSDCContracts: MockZRC20; + let systemContract: MockSystemContract; + + let accounts: SignerWithAddress[]; + let deployer: SignerWithAddress; + let fakeTSS: SignerWithAddress; + + beforeEach(async () => { + [deployer, fakeTSS, ...accounts] = await ethers.getSigners(); + + await network.provider.send("hardhat_setBalance", [deployer.address, parseUnits("1000000").toHexString()]); + + const uniswapRouterAddr = getNonZetaAddress("uniswapV2Router02", "eth_mainnet"); + + const uniswapFactoryAddr = getNonZetaAddress("uniswapV2Factory", "eth_mainnet"); + + const wGasToken = getNonZetaAddress("weth9", "eth_mainnet"); + + const evmSetupResult = await evmSetup(wGasToken, uniswapFactoryAddr, uniswapRouterAddr); + ZRC20Contracts = evmSetupResult.ZRC20Contracts; + systemContract = evmSetupResult.systemContract; + mockUSDCContracts = ZRC20Contracts[3]; + + const WithdrawERC20Factory = (await ethers.getContractFactory("WithdrawERC20")) as WithdrawERC20__factory; + withdrawERC20Contract = (await WithdrawERC20Factory.deploy(systemContract.address)) as WithdrawERC20; + await withdrawERC20Contract.deployed(); + }); + + describe("WithdrawERC20", () => { + it("Should withdraw", async () => { + const INITIAL_AMOUNT = parseEther("10"); + const gasFee = await mockUSDCContracts.gasFee(); + const expectedAmount = INITIAL_AMOUNT.sub(gasFee); + + await mockUSDCContracts.approve(withdrawERC20Contract.address, INITIAL_AMOUNT); + const tx = await withdrawERC20Contract.withdraw(mockUSDCContracts.address, INITIAL_AMOUNT, fakeTSS.address); + const receipt = await tx.wait(); + + expect(receipt.events).not.to.be.undefined; + expect(receipt.events?.length).to.be.above(1); + + //@ts-ignore + const withdrawalEvent: WithdrawalEvent = receipt.events[receipt.events?.length - 2] as WithdrawalEvent; + const decodedEventData = mockUSDCContracts.interface.parseLog(withdrawalEvent); + + expect(decodedEventData.args.from).to.equal(withdrawERC20Contract.address); + expect(decodedEventData.args.to).equal(fakeTSS.address.toLowerCase()); + + //@dev: We are assuming that the value is within 10% of the expected amount because we lost something on swap + expect(decodedEventData.args.value).to.be.lt(expectedAmount); + expect(decodedEventData.args.value).to.be.gt(expectedAmount.mul(9).div(10)); + + expect(decodedEventData.args.gasfee).to.equal(gasFee); + expect(decodedEventData.args.protocolFlatFee).to.eq(0); + + const balance = await mockUSDCContracts.balanceOf(fakeTSS.address); + expect(balance).to.equal(decodedEventData.args.value); + }); + }); +}); diff --git a/packages/zevm-app-contracts/test/test.helpers.ts b/packages/zevm-app-contracts/test/test.helpers.ts index 2039977f..ea93256e 100644 --- a/packages/zevm-app-contracts/test/test.helpers.ts +++ b/packages/zevm-app-contracts/test/test.helpers.ts @@ -1,5 +1,5 @@ import { MaxUint256 } from "@ethersproject/constants"; -import { parseUnits } from "@ethersproject/units"; +import { parseEther, parseUnits } from "@ethersproject/units"; import { SignerWithAddress } from "@nomiclabs/hardhat-ethers/signers"; import { ethers } from "hardhat"; @@ -48,8 +48,9 @@ export const evmSetup = async ( const token1Contract = (await ZRC20Factory.deploy(parseUnits("1000000"), "tBNB", "tBNB")) as MockZRC20; const token2Contract = (await ZRC20Factory.deploy(parseUnits("1000000"), "gETH", "gETH")) as MockZRC20; const token3Contract = (await ZRC20Factory.deploy(parseUnits("1000000"), "tMATIC", "tMATIC")) as MockZRC20; + const token4Contract = (await ZRC20Factory.deploy(parseUnits("1000000"), "USDC", "USDC")) as MockZRC20; - const ZRC20Contracts = [token1Contract, token2Contract, token3Contract]; + const ZRC20Contracts = [token1Contract, token2Contract, token3Contract, token4Contract]; const SystemContractFactory = (await ethers.getContractFactory("MockSystemContract")) as MockSystemContract__factory; @@ -62,10 +63,13 @@ export const evmSetup = async ( await systemContract.setGasCoinZRC20(97, ZRC20Contracts[0].address); await systemContract.setGasCoinZRC20(5, ZRC20Contracts[1].address); await systemContract.setGasCoinZRC20(80001, ZRC20Contracts[2].address); + await ZRC20Contracts[3].setGasFeeAddress(ZRC20Contracts[1].address); + await ZRC20Contracts[3].setGasFee(parseEther("0.01")); await addZetaEthLiquidity(signer, ZRC20Contracts[0], uniswapRouterAddr); await addZetaEthLiquidity(signer, ZRC20Contracts[1], uniswapRouterAddr); await addZetaEthLiquidity(signer, ZRC20Contracts[2], uniswapRouterAddr); + await addZetaEthLiquidity(signer, ZRC20Contracts[3], uniswapRouterAddr); return { ZRC20Contracts, systemContract }; }; From e2575c1073e548a3dcade244713c067a2d225ee8 Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Fri, 15 Mar 2024 16:14:27 -0300 Subject: [PATCH 10/12] add test --- packages/zevm-app-contracts/test/Withdraw.spec.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/zevm-app-contracts/test/Withdraw.spec.ts b/packages/zevm-app-contracts/test/Withdraw.spec.ts index 24a1ae74..7f4352fe 100644 --- a/packages/zevm-app-contracts/test/Withdraw.spec.ts +++ b/packages/zevm-app-contracts/test/Withdraw.spec.ts @@ -72,5 +72,13 @@ describe("Withdraw tests", () => { const balance = await mockUSDCContracts.balanceOf(fakeTSS.address); expect(balance).to.equal(decodedEventData.args.value); }); + + it("Should revert if it's not enogth", async () => { + const INITIAL_AMOUNT = parseEther("0.01"); + + await mockUSDCContracts.approve(withdrawERC20Contract.address, INITIAL_AMOUNT); + const tx = withdrawERC20Contract.withdraw(mockUSDCContracts.address, INITIAL_AMOUNT, fakeTSS.address); + await expect(tx).to.be.reverted; + }); }); }); From 91113fe8e6809f6a7b58e936464da31ccd75a344 Mon Sep 17 00:00:00 2001 From: Andres Martin Aiello <50411235+andresaiello@users.noreply.github.com> Date: Sat, 16 Mar 2024 15:03:47 -0300 Subject: [PATCH 11/12] Update packages/zevm-app-contracts/test/Withdraw.spec.ts Co-authored-by: Lucas --- packages/zevm-app-contracts/test/Withdraw.spec.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/zevm-app-contracts/test/Withdraw.spec.ts b/packages/zevm-app-contracts/test/Withdraw.spec.ts index 7f4352fe..03ec1f26 100644 --- a/packages/zevm-app-contracts/test/Withdraw.spec.ts +++ b/packages/zevm-app-contracts/test/Withdraw.spec.ts @@ -73,7 +73,7 @@ describe("Withdraw tests", () => { expect(balance).to.equal(decodedEventData.args.value); }); - it("Should revert if it's not enogth", async () => { + it("Should revert if it's not enough", async () => { const INITIAL_AMOUNT = parseEther("0.01"); await mockUSDCContracts.approve(withdrawERC20Contract.address, INITIAL_AMOUNT); From fa0c47a8d870b65ff79775821b651e265debec71 Mon Sep 17 00:00:00 2001 From: Andres Aiello Date: Mon, 18 Mar 2024 11:45:17 -0300 Subject: [PATCH 12/12] fix test --- .../contracts/shared/MockZRC20.sol | 2 +- packages/zevm-app-contracts/test/Withdraw.spec.ts | 15 ++++++++++++--- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/packages/zevm-app-contracts/contracts/shared/MockZRC20.sol b/packages/zevm-app-contracts/contracts/shared/MockZRC20.sol index c74b0d23..5a810b89 100644 --- a/packages/zevm-app-contracts/contracts/shared/MockZRC20.sol +++ b/packages/zevm-app-contracts/contracts/shared/MockZRC20.sol @@ -37,7 +37,7 @@ contract MockZRC20 is ERC20 { } function withdraw(bytes calldata to, uint256 amount) external returns (bool) { - address toAddress = BytesHelperLib.bytesToAddress(to, 0); + address toAddress = BytesHelperLib.bytesToAddress(to, 12); emit Withdrawal(msg.sender, to, amount, gasFee, 0); return transfer(toAddress, amount); } diff --git a/packages/zevm-app-contracts/test/Withdraw.spec.ts b/packages/zevm-app-contracts/test/Withdraw.spec.ts index 03ec1f26..86952dc4 100644 --- a/packages/zevm-app-contracts/test/Withdraw.spec.ts +++ b/packages/zevm-app-contracts/test/Withdraw.spec.ts @@ -11,6 +11,10 @@ import { WithdrawERC20 } from "../typechain-types/contracts/withdrawErc20/withdr import { WithdrawERC20__factory } from "../typechain-types/factories/contracts/withdrawErc20/withdrawErc20.sol"; import { evmSetup } from "./test.helpers"; +const encodeToBytes = (destination: string) => { + return ethers.utils.hexlify(ethers.utils.zeroPad(destination, 32)); +}; + describe("Withdraw tests", () => { let withdrawERC20Contract: WithdrawERC20; let ZRC20Contracts: MockZRC20[]; @@ -44,12 +48,13 @@ describe("Withdraw tests", () => { describe("WithdrawERC20", () => { it("Should withdraw", async () => { + const encodedDestination = encodeToBytes(fakeTSS.address); const INITIAL_AMOUNT = parseEther("10"); const gasFee = await mockUSDCContracts.gasFee(); const expectedAmount = INITIAL_AMOUNT.sub(gasFee); await mockUSDCContracts.approve(withdrawERC20Contract.address, INITIAL_AMOUNT); - const tx = await withdrawERC20Contract.withdraw(mockUSDCContracts.address, INITIAL_AMOUNT, fakeTSS.address); + const tx = await withdrawERC20Contract.withdraw(mockUSDCContracts.address, INITIAL_AMOUNT, encodedDestination); const receipt = await tx.wait(); expect(receipt.events).not.to.be.undefined; @@ -60,7 +65,7 @@ describe("Withdraw tests", () => { const decodedEventData = mockUSDCContracts.interface.parseLog(withdrawalEvent); expect(decodedEventData.args.from).to.equal(withdrawERC20Contract.address); - expect(decodedEventData.args.to).equal(fakeTSS.address.toLowerCase()); + expect(decodedEventData.args.to).equal(encodedDestination.toLowerCase()); //@dev: We are assuming that the value is within 10% of the expected amount because we lost something on swap expect(decodedEventData.args.value).to.be.lt(expectedAmount); @@ -77,7 +82,11 @@ describe("Withdraw tests", () => { const INITIAL_AMOUNT = parseEther("0.01"); await mockUSDCContracts.approve(withdrawERC20Contract.address, INITIAL_AMOUNT); - const tx = withdrawERC20Contract.withdraw(mockUSDCContracts.address, INITIAL_AMOUNT, fakeTSS.address); + const tx = withdrawERC20Contract.withdraw( + mockUSDCContracts.address, + INITIAL_AMOUNT, + encodeToBytes(fakeTSS.address) + ); await expect(tx).to.be.reverted; }); });