From 70356aaf5d388de0d3eddf0f74212f5f0977e0c0 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Thu, 25 Jan 2024 15:55:28 +0100 Subject: [PATCH 01/43] publish sepolia default metadata --- source/pool/package.json | 2 +- tools/metadata/defaults.ts | 31 +++++++++++++------------------ tools/metadata/package.json | 2 +- 3 files changed, 15 insertions(+), 20 deletions(-) diff --git a/source/pool/package.json b/source/pool/package.json index a733bd61a..8f8745978 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -32,7 +32,7 @@ }, "devDependencies": { "@airswap/constants": "4.1.8", - "@airswap/metadata": "4.1.16", + "@airswap/metadata": "4.1.17", "@airswap/types": "4.1.4", "@airswap/utils": "4.1.12", "prompt-confirm": "^2.0.4" diff --git a/tools/metadata/defaults.ts b/tools/metadata/defaults.ts index 8ac2805c5..a28c0cd33 100644 --- a/tools/metadata/defaults.ts +++ b/tools/metadata/defaults.ts @@ -1,28 +1,23 @@ import { TokenInfo } from '@airswap/types' +import { ChainIds } from '@airswap/constants' + +const TEST_TOKEN_DECIMALS = 6 + +// Test tokens for Sepolia export default [ - /* - * Goerli Defaults - */ { - name: 'Tether USD', - address: '0x79c950c7446b234a6ad53b908fbf342b01c4d446', - decimals: 6, + address: '0x20aaebad8c7c6ffb6fdaa5a622c399561562beea', + chainId: ChainIds.SEPOLIA, + decimals: TEST_TOKEN_DECIMALS, + name: 'Mintable USDT', symbol: 'USDT', - chainId: 5, }, { - name: 'USD//C', - address: '0x07865c6e87b9f70255377e024ace6630c1eaa37f', - decimals: 6, + address: '0xf450ef4f268eaf2d3d8f9ed0354852e255a5eaef', + chainId: ChainIds.SEPOLIA, + decimals: TEST_TOKEN_DECIMALS, + name: 'Mintable USDC', symbol: 'USDC', - chainId: 5, - }, - { - name: 'Dai', - address: '0x2899a03ffdab5c90badc5920b4f53b0884eb13cc', - decimals: 18, - symbol: 'DAI', - chainId: 5, }, ] as TokenInfo[] diff --git a/tools/metadata/package.json b/tools/metadata/package.json index 57dd383e4..f8ac54546 100644 --- a/tools/metadata/package.json +++ b/tools/metadata/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/metadata", - "version": "4.1.16", + "version": "4.1.17", "description": "AirSwap: Token Metadata for Developers", "repository": { "type": "git", From 5b2580cda26f023d68dae1c2acaad738322871d7 Mon Sep 17 00:00:00 2001 From: don mosites Date: Sat, 27 Jan 2024 13:21:03 +0100 Subject: [PATCH 02/43] Initial 4.2 packages (#1274) * deploys and versions for initial 4.2 packages --- source/batch-call/deploys-blocks.js | 5 +++- source/batch-call/deploys.js | 5 +++- source/batch-call/package.json | 10 +++---- source/pool/package.json | 10 +++---- source/registry/deploys-blocks.js | 8 +++++- source/registry/deploys.js | 8 +++++- source/registry/package.json | 6 ++-- source/registry/scripts/config.js | 39 ++++++++++++++++++++++++++ source/registry/scripts/deploy.js | 21 +++++++------- source/registry/scripts/verify.js | 23 +++++++++------ source/staking/package.json | 4 +-- source/swap-erc20/deploys-blocks.js | 8 +++++- source/swap-erc20/deploys.js | 8 +++++- source/swap-erc20/package.json | 10 +++---- source/swap-erc20/scripts/config.js | 4 +-- source/swap/deploys-adapters-blocks.js | 5 +++- source/swap/deploys-adapters.js | 13 ++++++++- source/swap/deploys-blocks.js | 5 +++- source/swap/deploys.js | 5 +++- source/swap/package.json | 8 +++--- source/swap/scripts/config.js | 2 +- source/wrapper/package.json | 10 +++---- tools/constants/package.json | 2 +- tools/libraries/package.json | 22 +++++++-------- tools/metadata/defaults.ts | 2 +- tools/metadata/package.json | 8 +++--- tools/types/package.json | 2 +- tools/utils/package.json | 6 ++-- 28 files changed, 178 insertions(+), 81 deletions(-) create mode 100644 source/registry/scripts/config.js diff --git a/source/batch-call/deploys-blocks.js b/source/batch-call/deploys-blocks.js index 4ba52ba2c..3bd4c0c88 100644 --- a/source/batch-call/deploys-blocks.js +++ b/source/batch-call/deploys-blocks.js @@ -1 +1,4 @@ -module.exports = {} +module.exports = { + 80001: 45223507, + 11155111: 5163580, +} diff --git a/source/batch-call/deploys.js b/source/batch-call/deploys.js index 4ba52ba2c..64c0561f8 100644 --- a/source/batch-call/deploys.js +++ b/source/batch-call/deploys.js @@ -1 +1,4 @@ -module.exports = {} +module.exports = { + 80001: '0x2f9848b5644833b9A55F14375D5dAFCFa4d0E107', + 11155111: '0x2f9848b5644833b9A55F14375D5dAFCFa4d0E107', +} diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 0df83ec78..2e3d14a62 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/batch-call", - "version": "4.2.0-beta.1", + "version": "4.2.0", "description": "Batch balance, allowance, order validity checks", "license": "MIT", "repository": { @@ -27,12 +27,12 @@ }, "dependencies": { "@openzeppelin/contracts": "^4.8.3", - "@airswap/swap": "4.2.0-beta.1", - "@airswap/swap-erc20": "4.2.0-beta.2" + "@airswap/swap": "4.2.0", + "@airswap/swap-erc20": "4.2.0" }, "devDependencies": { - "@airswap/constants": "4.2.0-beta.3", - "@airswap/utils": "4.2.0-beta.2", + "@airswap/constants": "4.2.0", + "@airswap/utils": "4.2.0", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index b81706787..0890bbce1 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/pool", - "version": "4.2.0-beta.0", + "version": "4.1.4", "description": "AirSwap: Withdrawable Token Pool", "license": "MIT", "repository": { @@ -31,10 +31,10 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/constants": "4.2.0-beta.3", - "@airswap/metadata": "4.1.16", - "@airswap/types": "4.2.0-beta.1", - "@airswap/utils": "4.2.0-beta.2", + "@airswap/constants": "4.2.0", + "@airswap/metadata": "4.1.17", + "@airswap/types": "4.2.0", + "@airswap/utils": "4.2.0", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/registry/deploys-blocks.js b/source/registry/deploys-blocks.js index 8e52e43b1..de096cba8 100644 --- a/source/registry/deploys-blocks.js +++ b/source/registry/deploys-blocks.js @@ -1,3 +1,9 @@ module.exports = { - 11155111: 5151266, + 1: 19090182, + 56: 35580028, + 137: 52768712, + 43114: 40856912, + 59144: 1853987, + 80001: 45223040, + 11155111: 5156883, } diff --git a/source/registry/deploys.js b/source/registry/deploys.js index d3790c85f..90b99099a 100644 --- a/source/registry/deploys.js +++ b/source/registry/deploys.js @@ -1,3 +1,9 @@ module.exports = { - 11155111: '0x47C116ac7E9D1F020761eFb81D3ce9d887273967', + 1: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', + 56: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', + 137: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', + 43114: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', + 59144: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', + 80001: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', + 11155111: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', } diff --git a/source/registry/package.json b/source/registry/package.json index 0de263471..14e02e2a5 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/registry", - "version": "4.2.0-beta.1", + "version": "4.2.0", "description": "AirSwap: Server Registry", "license": "MIT", "repository": { @@ -32,8 +32,8 @@ "access": "public" }, "devDependencies": { - "@airswap/constants": "4.2.0-beta.3", - "@airswap/utils": "4.2.0-beta.2", + "@airswap/constants": "4.2.0", + "@airswap/utils": "4.2.0", "prompt-confirm": "^2.0.4" } } diff --git a/source/registry/scripts/config.js b/source/registry/scripts/config.js new file mode 100644 index 000000000..78d9238c7 --- /dev/null +++ b/source/registry/scripts/config.js @@ -0,0 +1,39 @@ +const { + ChainIds, + stakingTokenAddresses, + ADDRESS_ZERO, +} = require('@airswap/constants') +const wrappedTokenAddresses = require('@airswap/wrapper/deploys-weth') + +module.exports = { + [ChainIds.MAINNET]: { + stakingToken: stakingTokenAddresses[ChainIds.MAINNET], + stakingCost: '1000000000', + supportCost: '1000000', + }, + [ChainIds.BSC]: { + stakingToken: wrappedTokenAddresses[ChainIds.BSC], + stakingCost: '100000000000000000', + supportCost: '1000000000000000', + }, + [ChainIds.POLYGON]: { + stakingToken: wrappedTokenAddresses[ChainIds.POLYGON], + stakingCost: '100000000000000000000', + supportCost: '1000000000000000000', + }, + [ChainIds.AVALANCHE]: { + stakingToken: wrappedTokenAddresses[ChainIds.AVALANCHE], + stakingCost: '1000000000000000000', + supportCost: '10000000000000000', + }, + [ChainIds.LINEA]: { + stakingToken: wrappedTokenAddresses[ChainIds.LINEA], + stakingCost: '50000000000000000', + supportCost: '500000000000000', + }, + [ChainIds.MUMBAI]: { + stakingToken: ADDRESS_ZERO, + stakingCost: '0', + supportCost: '0', + }, +} diff --git a/source/registry/scripts/deploy.js b/source/registry/scripts/deploy.js index e069f3be9..77c821893 100644 --- a/source/registry/scripts/deploy.js +++ b/source/registry/scripts/deploy.js @@ -3,16 +3,11 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { - ChainIds, - chainLabels, - chainNames, - stakingTokenAddresses, - ADDRESS_ZERO, -} = require('@airswap/constants') +const { ChainIds, chainLabels, chainNames } = require('@airswap/constants') const { getReceiptUrl } = require('@airswap/utils') const registryDeploys = require('../deploys.js') const registryBlocks = require('../deploys-blocks.js') +const config = require('./config.js') async function main() { await run('compile') @@ -29,9 +24,15 @@ async function main() { console.log(`Network: ${chainNames[chainId].toUpperCase()}`) console.log(`Gas price: ${gasPrice / 10 ** 9} gwei\n`) - const stakingToken = stakingTokenAddresses[chainId] || ADDRESS_ZERO - const stakingCost = 0 - const supportCost = 0 + let stakingToken + let stakingCost + let supportCost + + if (config[chainId]) { + ;({ stakingToken, stakingCost, supportCost } = config[chainId]) + } else { + ;({ stakingToken, stakingCost, supportCost } = config[ChainIds.MAINNET]) + } console.log(`\nstakingToken: ${stakingToken}`) console.log(`stakingCost: ${stakingCost}`) diff --git a/source/registry/scripts/verify.js b/source/registry/scripts/verify.js index 960765f45..132d40abc 100644 --- a/source/registry/scripts/verify.js +++ b/source/registry/scripts/verify.js @@ -1,11 +1,8 @@ /* eslint-disable no-console */ const { ethers, run } = require('hardhat') const registryDeploys = require('../deploys.js') -const { - chainNames, - stakingTokenAddresses, - ADDRESS_ZERO, -} = require('@airswap/constants') +const { chainNames } = require('@airswap/constants') +const config = require('./config.js') async function main() { await run('compile') @@ -13,9 +10,19 @@ async function main() { console.log(`Deployer: ${deployer.address}`) const chainId = await deployer.getChainId() - const stakingToken = stakingTokenAddresses[chainId] || ADDRESS_ZERO - const stakingCost = 0 - const supportCost = 0 + let stakingToken + let stakingCost + let supportCost + + if (config[chainId]) { + ;({ stakingToken, stakingCost, supportCost } = config[chainId]) + } else { + ;({ stakingToken, stakingCost, supportCost } = config[ChainIds.MAINNET]) + } + + console.log(`\nstakingToken: ${stakingToken}`) + console.log(`stakingCost: ${stakingCost}`) + console.log(`supportCost: ${supportCost}\n`) console.log(`Verifying on ${chainNames[chainId].toUpperCase()}`) await run('verify:verify', { diff --git a/source/staking/package.json b/source/staking/package.json index 015eed178..d92a9af17 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/staking", - "version": "4.2.0-beta.1", + "version": "4.0.5", "description": "AirSwap: Stake Tokens", "license": "MIT", "repository": { @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.0-beta.2", + "@airswap/utils": "4.2.0", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/deploys-blocks.js b/source/swap-erc20/deploys-blocks.js index 140f5a381..e0886cc62 100644 --- a/source/swap-erc20/deploys-blocks.js +++ b/source/swap-erc20/deploys-blocks.js @@ -1,3 +1,9 @@ module.exports = { - 11155111: 5151268, + 1: 19090128, + 56: 35580014, + 137: 52768683, + 43114: 40856884, + 59144: 1853953, + 80001: 45222994, + 11155111: 5156848, } diff --git a/source/swap-erc20/deploys.js b/source/swap-erc20/deploys.js index 9ff0384b4..bd675d7c4 100644 --- a/source/swap-erc20/deploys.js +++ b/source/swap-erc20/deploys.js @@ -1,3 +1,9 @@ module.exports = { - 11155111: '0xE057458c99D44395B2Bcb773722f1c4B1d2932Ed', + 1: '0x5daDEFF339e1670B83957dA080c91334323A570f', + 56: '0x5daDEFF339e1670B83957dA080c91334323A570f', + 137: '0x5daDEFF339e1670B83957dA080c91334323A570f', + 43114: '0x5daDEFF339e1670B83957dA080c91334323A570f', + 59144: '0x5daDEFF339e1670B83957dA080c91334323A570f', + 80001: '0x5daDEFF339e1670B83957dA080c91334323A570f', + 11155111: '0x5daDEFF339e1670B83957dA080c91334323A570f', } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index f8325f7bb..c9546e6c1 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/swap-erc20", - "version": "4.2.0-beta.2", + "version": "4.2.0", "description": "AirSwap: Atomic ERC20 Token Swap", "license": "MIT", "repository": { @@ -29,10 +29,10 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/constants": "4.2.0-beta.3", - "@airswap/staking": "4.2.0-beta.1", - "@airswap/types": "4.2.0-beta.1", - "@airswap/utils": "4.2.0-beta.2", + "@airswap/constants": "4.2.0", + "@airswap/staking": "4.0.5", + "@airswap/types": "4.2.0", + "@airswap/utils": "4.2.0", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap-erc20/scripts/config.js b/source/swap-erc20/scripts/config.js index a37ed57ee..53c9921cc 100644 --- a/source/swap-erc20/scripts/config.js +++ b/source/swap-erc20/scripts/config.js @@ -2,8 +2,8 @@ const { ChainIds } = require('@airswap/constants') module.exports = { [ChainIds.MAINNET]: { - protocolFee: 7, - protocolFeeLight: 7, + protocolFee: 5, + protocolFeeLight: 5, bonusScale: 10, bonusMax: 100, }, diff --git a/source/swap/deploys-adapters-blocks.js b/source/swap/deploys-adapters-blocks.js index 4ba52ba2c..cb8428a0f 100644 --- a/source/swap/deploys-adapters-blocks.js +++ b/source/swap/deploys-adapters-blocks.js @@ -1 +1,4 @@ -module.exports = {} +module.exports = { + 80001: [45223326, 45223344, 45223347], + 11155111: [5163532, 5163533, 5163534], +} diff --git a/source/swap/deploys-adapters.js b/source/swap/deploys-adapters.js index 4ba52ba2c..5ae16afc8 100644 --- a/source/swap/deploys-adapters.js +++ b/source/swap/deploys-adapters.js @@ -1 +1,12 @@ -module.exports = {} +module.exports = { + 80001: [ + '0xec06d567cfB5360b422B2EBEB7c6ed0aAD132030', + '0x906052b51a22F34c93c1b91B3473D06521100f8e', + '0x647a06900091DEb81927a80Da8E4e6F4AeA4Dc55', + ], + 11155111: [ + '0xec06d567cfB5360b422B2EBEB7c6ed0aAD132030', + '0x906052b51a22F34c93c1b91B3473D06521100f8e', + '0x647a06900091DEb81927a80Da8E4e6F4AeA4Dc55', + ], +} diff --git a/source/swap/deploys-blocks.js b/source/swap/deploys-blocks.js index 4ba52ba2c..fd99f5416 100644 --- a/source/swap/deploys-blocks.js +++ b/source/swap/deploys-blocks.js @@ -1 +1,4 @@ -module.exports = {} +module.exports = { + 80001: 45223424, + 11155111: 5163542, +} diff --git a/source/swap/deploys.js b/source/swap/deploys.js index 4ba52ba2c..4836ed43e 100644 --- a/source/swap/deploys.js +++ b/source/swap/deploys.js @@ -1 +1,4 @@ -module.exports = {} +module.exports = { + 80001: '0xbBBAA3810e91a703884746deDb714e47C75524E0', + 11155111: '0xbBBAA3810e91a703884746deDb714e47C75524E0', +} diff --git a/source/swap/package.json b/source/swap/package.json index 74dcc955c..cea3b0a6b 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/swap", - "version": "4.2.0-beta.1", + "version": "4.2.0", "description": "AirSwap: Atomic Token Swap", "license": "MIT", "repository": { @@ -32,9 +32,9 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/constants": "4.2.0-beta.3", - "@airswap/types": "4.2.0-beta.1", - "@airswap/utils": "4.2.0-beta.2", + "@airswap/constants": "4.2.0", + "@airswap/types": "4.2.0", + "@airswap/utils": "4.2.0", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/swap/scripts/config.js b/source/swap/scripts/config.js index f6a4c3ec5..4903a8a0b 100644 --- a/source/swap/scripts/config.js +++ b/source/swap/scripts/config.js @@ -3,6 +3,6 @@ const { ChainIds, TokenKinds } = require('@airswap/constants') module.exports = { [ChainIds.MAINNET]: { requiredSenderKind: TokenKinds.ERC20, - protocolFee: 7, + protocolFee: 5, }, } diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 0284d5d50..ac96a746e 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/wrapper", - "version": "4.2.0-beta.0", + "version": "4.1.5", "description": "AirSwap: Wrap and Unwrap Native Tokens", "license": "MIT", "repository": { @@ -28,13 +28,13 @@ "owners": "hardhat run ./scripts/owner.js" }, "dependencies": { - "@airswap/swap-erc20": "4.2.0-beta.2", + "@airswap/swap-erc20": "4.2.0", "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/constants": "4.2.0-beta.3", - "@airswap/utils": "4.2.0-beta.2", - "@airswap/types": "4.2.0-beta.1", + "@airswap/constants": "4.2.0", + "@airswap/utils": "4.2.0", + "@airswap/types": "4.2.0", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/constants/package.json b/tools/constants/package.json index 20e6e8cfd..bcb9ff5da 100644 --- a/tools/constants/package.json +++ b/tools/constants/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/constants", - "version": "4.2.0-beta.3", + "version": "4.2.0", "description": "AirSwap: Constants for Developers", "repository": { "type": "git", diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 6a6ac5b49..ba2e7d9a6 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.1-beta.2", + "version": "4.2.1", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -26,17 +26,17 @@ "test:ci": "yarn test" }, "dependencies": { - "@airswap/batch-call": "4.2.0-beta.1", - "@airswap/constants": "4.2.0-beta.3", + "@airswap/batch-call": "4.2.0", + "@airswap/constants": "4.2.0", "@airswap/jsonrpc-client-websocket": "0.0.1", - "@airswap/registry": "4.2.0-beta.1", - "@airswap/pool": "4.2.0-beta.0", - "@airswap/staking": "4.2.0-beta.1", - "@airswap/swap": "4.2.0-beta.1", - "@airswap/swap-erc20": "4.2.0-beta.2", - "@airswap/types": "4.2.0-beta.1", - "@airswap/utils": "4.2.0-beta.2", - "@airswap/wrapper": "4.2.0-beta.0", + "@airswap/registry": "4.2.0", + "@airswap/pool": "4.1.4", + "@airswap/staking": "4.0.5", + "@airswap/swap": "4.2.0", + "@airswap/swap-erc20": "4.2.0", + "@airswap/types": "4.2.0", + "@airswap/utils": "4.2.0", + "@airswap/wrapper": "4.1.5", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", "jayson": "^4.0.0", diff --git a/tools/metadata/defaults.ts b/tools/metadata/defaults.ts index 276a76cea..a28c0cd33 100644 --- a/tools/metadata/defaults.ts +++ b/tools/metadata/defaults.ts @@ -3,7 +3,7 @@ import { ChainIds } from '@airswap/constants' const TEST_TOKEN_DECIMALS = 6 -// Test tokens for Sepolia, Holesky +// Test tokens for Sepolia export default [ { diff --git a/tools/metadata/package.json b/tools/metadata/package.json index 4d57d947e..1054f3d5d 100644 --- a/tools/metadata/package.json +++ b/tools/metadata/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/metadata", - "version": "4.1.16", + "version": "4.1.17", "description": "AirSwap: Token Metadata for Developers", "repository": { "type": "git", @@ -20,9 +20,9 @@ "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/constants": "4.2.0-beta.3", - "@airswap/types": "4.2.0-beta.1", - "@airswap/wrapper": "4.2.0-beta.0", + "@airswap/constants": "4.2.0", + "@airswap/types": "4.2.0", + "@airswap/wrapper": "4.1.5", "@openzeppelin/contracts": "^4.8.3", "@uniswap/token-lists": "^1.0.0-beta.24", "ethers": "^5.6.9", diff --git a/tools/types/package.json b/tools/types/package.json index 8770dda5a..881ddb9f9 100644 --- a/tools/types/package.json +++ b/tools/types/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/types", - "version": "4.2.0-beta.1", + "version": "4.2.0", "description": "AirSwap: Types for Developers", "repository": { "type": "git", diff --git a/tools/utils/package.json b/tools/utils/package.json index af2e9ffaa..99406490b 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.0-beta.2", + "version": "4.2.0", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", @@ -21,8 +21,8 @@ "test:ci": "yarn test" }, "dependencies": { - "@airswap/constants": "4.2.0-beta.3", - "@airswap/types": "4.2.0-beta.1", + "@airswap/constants": "4.2.0", + "@airswap/types": "4.2.0", "@metamask/eth-sig-util": "^5.0.2", "bignumber.js": "^9.0.1", "ethereumjs-util": "^7.1.5", From beb2a45480a95b6c704874dac5500acbab5889d9 Mon Sep 17 00:00:00 2001 From: don mosites Date: Sun, 28 Jan 2024 22:47:35 +0100 Subject: [PATCH 03/43] Consolidate into utils; update Indexing/ERC20 protocols (#1276) * consolidate constants, merkle, types into utils; update protocols * merkle naming; function ordering; filename casing --- hardhat.config.js | 2 +- scripts/owners-report.js | 4 +- scripts/owners-update.js | 2 +- scripts/receivers-report.js | 4 +- source/batch-call/package.json | 3 +- source/batch-call/scripts/deploy.js | 2 +- source/batch-call/scripts/verify.js | 2 +- source/batch-call/test/BatchCall.js | 2 +- source/pool/package.json | 4 +- source/pool/scripts/balances.js | 2 +- source/pool/scripts/deploy.js | 2 +- source/pool/scripts/migrate.js | 2 +- source/pool/scripts/verify.js | 2 +- source/pool/test/Pool.js | 78 +++++++----- source/pool/test/PoolIntegration.js | 14 ++- source/registry/package.json | 3 +- source/registry/scripts/config.js | 2 +- source/registry/scripts/deploy.js | 2 +- source/registry/scripts/verify.js | 2 +- source/staking/package.json | 2 +- source/staking/scripts/config.js | 2 +- source/staking/scripts/deploy.js | 2 +- source/staking/scripts/verify.js | 2 +- source/swap-erc20/package.json | 4 +- source/swap-erc20/scripts/config.js | 2 +- source/swap-erc20/scripts/deploy.js | 2 +- source/swap-erc20/scripts/verify.js | 2 +- source/swap-erc20/test/SwapERC20.js | 2 +- source/swap/package.json | 4 +- source/swap/scripts/config.js | 2 +- source/swap/scripts/deploy-adapters.js | 2 +- source/swap/scripts/deploy.js | 2 +- source/swap/scripts/verify-adapters.js | 2 +- source/swap/scripts/verify.js | 2 +- source/swap/test/ERC1155Adapter.js | 2 +- source/swap/test/ERC20Adapter.js | 2 +- source/swap/test/ERC721Adapter.js | 2 +- source/swap/test/Swap.js | 2 +- source/swap/test/SwapIntegration.js | 2 +- source/wrapper/package.json | 4 +- source/wrapper/scripts/deploy.js | 2 +- source/wrapper/scripts/verify.js | 2 +- source/wrapper/test/Wrapper.js | 2 +- tools/constants/LICENSE | 19 --- tools/constants/README.md | 36 ------ tools/constants/package.json | 26 ---- tools/constants/test/utils.ts | 14 --- tools/constants/tsconfig.json | 6 - tools/libraries/package.json | 4 +- tools/libraries/src/Registry.ts | 2 +- tools/libraries/src/Server.ts | 40 +++--- tools/libraries/test/Contract.test.ts | 2 +- tools/libraries/test/Server.test.ts | 17 +-- tools/libraries/test/test-utils.ts | 6 +- tools/merkle/LICENSE | 19 --- tools/merkle/README.md | 37 ------ tools/merkle/index.ts | 27 ---- tools/merkle/package.json | 42 ------- tools/merkle/test/merkle.ts | 28 ----- tools/merkle/tsconfig.json | 6 - tools/metadata/README.md | 2 +- tools/metadata/defaults.ts | 3 +- tools/metadata/index.ts | 10 +- tools/metadata/package.json | 3 +- tools/metadata/test/metadata.ts | 2 +- tools/metadata/tokenlists.ts | 2 +- tools/types/.npmignore | 8 -- tools/types/LICENSE | 19 --- tools/types/README.md | 30 ----- tools/types/index.ts | 3 - tools/types/package.json | 28 ----- tools/types/src/eip712.ts | 54 -------- tools/types/src/typescript.ts | 119 ------------------ tools/types/tsconfig.json | 6 - tools/utils/index.ts | 69 ++++++++-- tools/utils/package.json | 4 +- .../src/merkle.ts => utils/src/MerkleTree.ts} | 8 +- tools/utils/src/{pricing.ts => Pricing.ts} | 29 ++++- .../src/server.ts => utils/src/Server.ts} | 0 tools/utils/src/{swap.ts => Swap.ts} | 58 +++++++-- .../utils/src/{swapERC20.ts => SwapERC20.ts} | 69 ++++++++-- .../index.ts => utils/src/constants.ts} | 40 +++--- tools/utils/src/types.ts | 39 ++++++ tools/utils/test/utils.ts | 49 +++++++- yarn.lock | 119 +++--------------- 85 files changed, 455 insertions(+), 837 deletions(-) delete mode 100644 tools/constants/LICENSE delete mode 100644 tools/constants/README.md delete mode 100644 tools/constants/package.json delete mode 100644 tools/constants/test/utils.ts delete mode 100644 tools/constants/tsconfig.json delete mode 100644 tools/merkle/LICENSE delete mode 100644 tools/merkle/README.md delete mode 100644 tools/merkle/index.ts delete mode 100644 tools/merkle/package.json delete mode 100644 tools/merkle/test/merkle.ts delete mode 100644 tools/merkle/tsconfig.json delete mode 100644 tools/types/.npmignore delete mode 100644 tools/types/LICENSE delete mode 100644 tools/types/README.md delete mode 100644 tools/types/index.ts delete mode 100644 tools/types/package.json delete mode 100644 tools/types/src/eip712.ts delete mode 100644 tools/types/src/typescript.ts delete mode 100644 tools/types/tsconfig.json rename tools/{merkle/src/merkle.ts => utils/src/MerkleTree.ts} (95%) rename tools/utils/src/{pricing.ts => Pricing.ts} (87%) rename tools/{types/src/server.ts => utils/src/Server.ts} (100%) rename tools/utils/src/{swap.ts => Swap.ts} (75%) rename tools/utils/src/{swapERC20.ts => SwapERC20.ts} (84%) rename tools/{constants/index.ts => utils/src/constants.ts} (88%) create mode 100644 tools/utils/src/types.ts diff --git a/hardhat.config.js b/hardhat.config.js index d3c8bc1b9..2d655ad75 100644 --- a/hardhat.config.js +++ b/hardhat.config.js @@ -11,7 +11,7 @@ const { apiUrls, explorerUrls, explorerApiUrls, -} = require('@airswap/constants') +} = require('@airswap/utils') /** * @type import('hardhat/config').HardhatUserConfig diff --git a/scripts/owners-report.js b/scripts/owners-report.js index 21162c28b..d928b29ce 100644 --- a/scripts/owners-report.js +++ b/scripts/owners-report.js @@ -5,8 +5,8 @@ const { chainNames, ownerAddresses, apiUrls, -} = require('@airswap/constants') -const { ADDRESS_ZERO } = require('@airswap/constants') +} = require('@airswap/utils') +const { ADDRESS_ZERO } = require('@airswap/utils') const contracts = [ ['pool', 'Pool'], diff --git a/scripts/owners-update.js b/scripts/owners-update.js index f41658134..ab422829d 100644 --- a/scripts/owners-update.js +++ b/scripts/owners-update.js @@ -1,6 +1,6 @@ const Confirm = require('prompt-confirm') const { ethers } = require('hardhat') -const { chainNames, ChainIds, ownerAddresses } = require('@airswap/constants') +const { chainNames, ChainIds, ownerAddresses } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const CONFIRMATIONS = 2 diff --git a/scripts/receivers-report.js b/scripts/receivers-report.js index 3f8e3f4e9..095e2e125 100644 --- a/scripts/receivers-report.js +++ b/scripts/receivers-report.js @@ -5,9 +5,9 @@ const { chainNames, apiUrls, protocolFeeReceiverAddresses, -} = require('@airswap/constants') +} = require('@airswap/utils') const poolDeploys = require('@airswap/pool/deploys.js') -const { ADDRESS_ZERO } = require('@airswap/constants') +const { ADDRESS_ZERO } = require('@airswap/utils') const contracts = [ ['swap', 'Swap'], diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 2e3d14a62..af4c4b7ef 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,8 +31,7 @@ "@airswap/swap-erc20": "4.2.0" }, "devDependencies": { - "@airswap/constants": "4.2.0", - "@airswap/utils": "4.2.0", + "@airswap/utils": "4.2.1", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/batch-call/scripts/deploy.js b/source/batch-call/scripts/deploy.js index 9539ac414..1d699fd9b 100644 --- a/source/batch-call/scripts/deploy.js +++ b/source/batch-call/scripts/deploy.js @@ -3,7 +3,7 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { ChainIds, chainNames, chainLabels } = require('@airswap/constants') +const { ChainIds, chainNames, chainLabels } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const batchCallDeploys = require('../deploys.js') const batchCallBlocks = require('../deploys-blocks.js') diff --git a/source/batch-call/scripts/verify.js b/source/batch-call/scripts/verify.js index 6d0e4679c..cdb01c9f5 100644 --- a/source/batch-call/scripts/verify.js +++ b/source/batch-call/scripts/verify.js @@ -1,6 +1,6 @@ /* eslint-disable no-console */ const { ethers, run } = require('hardhat') -const { chainNames } = require('@airswap/constants') +const { chainNames } = require('@airswap/utils') const batchCallDeploys = require('../deploys.js') async function main() { diff --git a/source/batch-call/test/BatchCall.js b/source/batch-call/test/BatchCall.js index 77d50cfb2..721bb6665 100644 --- a/source/batch-call/test/BatchCall.js +++ b/source/batch-call/test/BatchCall.js @@ -13,7 +13,7 @@ const { createOrderERC20, createOrderERC20Signature, } = require('@airswap/utils') -const { TokenKinds } = require('@airswap/constants') +const { TokenKinds } = require('@airswap/utils') const CHAIN_ID = 31337 const PROTOCOL_FEE = '30' diff --git a/source/pool/package.json b/source/pool/package.json index 0890bbce1..3fbbdd3bb 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,10 +31,8 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/constants": "4.2.0", "@airswap/metadata": "4.1.17", - "@airswap/types": "4.2.0", - "@airswap/utils": "4.2.0", + "@airswap/utils": "4.2.1", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/scripts/balances.js b/source/pool/scripts/balances.js index 173cc73f9..1a02c50e4 100644 --- a/source/pool/scripts/balances.js +++ b/source/pool/scripts/balances.js @@ -1,6 +1,6 @@ const { ethers } = require('hardhat') const { getKnownTokens } = require('@airswap/metadata') -const { chainNames, ChainIds } = require('@airswap/constants') +const { chainNames, ChainIds } = require('@airswap/utils') const BatchCall = require('@airswap/batch-call/build/contracts/BatchCall.sol/BatchCall.json') const batchCallDeploys = require('@airswap/batch-call/deploys.js') const poolDeploys = require('../deploys.js') diff --git a/source/pool/scripts/deploy.js b/source/pool/scripts/deploy.js index 264a2f0d8..81c3b28e9 100644 --- a/source/pool/scripts/deploy.js +++ b/source/pool/scripts/deploy.js @@ -3,7 +3,7 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { chainLabels, chainNames, ChainIds } = require('@airswap/constants') +const { chainLabels, chainNames, ChainIds } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const poolDeploys = require('../deploys.js') const poolBlocks = require('../deploys-blocks.js') diff --git a/source/pool/scripts/migrate.js b/source/pool/scripts/migrate.js index 0bc28adcb..2df9753fd 100644 --- a/source/pool/scripts/migrate.js +++ b/source/pool/scripts/migrate.js @@ -1,6 +1,6 @@ const Confirm = require('prompt-confirm') const { ethers } = require('hardhat') -const { chainNames, ChainIds } = require('@airswap/constants') +const { chainNames, ChainIds } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const { Pool__factory } = require('../typechain/factories/contracts') diff --git a/source/pool/scripts/verify.js b/source/pool/scripts/verify.js index 4613111b2..413e98ed3 100644 --- a/source/pool/scripts/verify.js +++ b/source/pool/scripts/verify.js @@ -1,7 +1,7 @@ /* eslint-disable no-console */ const { ethers, run } = require('hardhat') const poolDeploys = require('../deploys.js') -const { chainNames } = require('@airswap/constants') +const { chainNames } = require('@airswap/utils') async function main() { await run('compile') diff --git a/source/pool/test/Pool.js b/source/pool/test/Pool.js index 73586076d..ecc0d1933 100644 --- a/source/pool/test/Pool.js +++ b/source/pool/test/Pool.js @@ -1,13 +1,17 @@ const { expect } = require('chai') -const { toAtomicString } = require('@airswap/utils') -const { generateTreeFromData, getRoot, getProof } = require('@airswap/merkle') +const { + toAtomicString, + generateMerkleTreeFromData, + getMerkleRoot, + getMerkleProof, +} = require('@airswap/utils') const { soliditySha3 } = require('web3-utils') const { ethers, waffle } = require('hardhat') const { deployMockContract } = waffle const IERC20 = require('@openzeppelin/contracts/build/contracts/IERC20.json') const STAKING = require('@airswap/staking/build/contracts/Staking.sol/Staking.json') -const { ADDRESS_ZERO } = require('@airswap/constants') +const { ADDRESS_ZERO } = require('@airswap/utils') function toWei(value, places) { return toAtomicString(value, places || 18) @@ -71,13 +75,13 @@ describe('Pool Unit', () => { ).deploy(CLAIM_SCALE, CLAIM_MAX) await pool.deployed() - tree = generateTreeFromData({ + tree = generateMerkleTreeFromData({ [alice.address]: ALICE_SCORE, [bob.address]: BOB_SCORE, [carol.address]: CAROL_SCORE, }) - newTree = generateTreeFromData({ + newTree = generateMerkleTreeFromData({ [alice.address]: ALICE_SCORE, [bob.address]: BOB_NEW_SCORE, [carol.address]: CAROL_SCORE, @@ -118,7 +122,7 @@ describe('Pool Unit', () => { describe('admin functions', async () => { it('enable a claim for a merkle root suceeds', async () => { - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.setAdmin(alice.address) expect(await pool.connect(alice).enable(TREE, root)).to.emit( pool, @@ -127,17 +131,17 @@ describe('Pool Unit', () => { }) it('enable a claim for a merkle root fails when not admin', async () => { - const root = getRoot(tree) + const root = getMerkleRoot(tree) await expect(pool.connect(bob).enable(TREE, root)).to.be.revertedWith( 'Unauthorized' ) }) it('enable a with the same tree overrwrites the previous root', async () => { - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.setAdmin(alice.address) await pool.connect(alice).enable(TREE, root) - const newRoot = getRoot(newTree) + const newRoot = getMerkleRoot(newTree) await expect(pool.connect(alice).enable(TREE, newRoot)).to.be.emit( pool, `Enable` @@ -151,9 +155,9 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( @@ -179,7 +183,7 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.connect(alice).enable(TREE, root) await expect( @@ -197,7 +201,7 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( @@ -225,9 +229,9 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( @@ -267,9 +271,9 @@ describe('Pool Unit', () => { score = 0 await pool.setAdmin(alice.address) - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( @@ -296,9 +300,12 @@ describe('Pool Unit', () => { await feeToken.mock.balanceOf.returns('100000') ;(await feeToken.mock.transfer.returns(true)) - (await pool.setAdmin(alice.address)) - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getProof(tree, soliditySha3(alice.address, ALICE_SCORE)) + const proof = getMerkleProof( + tree, + soliditySha3(alice.address, ALICE_SCORE) + ) const withdrawMinimum = 496 const amount = await pool @@ -331,11 +338,11 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const root = getRoot(tree) - const newRoot = getRoot(newTree) + const root = getMerkleRoot(tree) + const newRoot = getMerkleRoot(newTree) await pool.connect(alice).enable(TREE, root) await pool.connect(alice).enable(NEW_TREE, newRoot) - const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) await pool.connect(bob).withdraw( [ @@ -368,9 +375,12 @@ describe('Pool Unit', () => { describe('Verify', async () => { it('verification is valid', async () => { await pool.setAdmin(alice.address) - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getProof(tree, soliditySha3(alice.address, ALICE_SCORE)) + const proof = getMerkleProof( + tree, + soliditySha3(alice.address, ALICE_SCORE) + ) const isValid = await pool.verify(alice.address, root, ALICE_SCORE, proof) expect(isValid).to.be.equal(true) @@ -378,9 +388,12 @@ describe('Pool Unit', () => { it('verification is invalid with wrong participant', async () => { await pool.setAdmin(alice.address) - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getProof(tree, soliditySha3(alice.address, ALICE_SCORE)) + const proof = getMerkleProof( + tree, + soliditySha3(alice.address, ALICE_SCORE) + ) const isValid = await pool.verify(bob.address, root, ALICE_SCORE, proof) expect(isValid).to.be.equal(false) @@ -388,9 +401,12 @@ describe('Pool Unit', () => { it('verification is invalid with wrong scroe', async () => { await pool.setAdmin(alice.address) - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getProof(tree, soliditySha3(alice.address, ALICE_SCORE)) + const proof = getMerkleProof( + tree, + soliditySha3(alice.address, ALICE_SCORE) + ) const isValid = await pool.verify(alice.address, root, BOB_SCORE, proof) expect(isValid).to.be.equal(false) @@ -484,10 +500,10 @@ describe('Pool Unit', () => { await feeToken.mock.balanceOf.returns('100000') await await pool.connect(deployer).setAdmin(alice.address) - const root = getRoot(tree) + const root = getMerkleRoot(tree) await pool.connect(alice).enableAndSetClaimed(TREE, root, [bob.address]) - const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( [ @@ -507,7 +523,7 @@ describe('Pool Unit', () => { it('set claimed with non-owner reverts', async () => { await feeToken.mock.balanceOf.returns('100000') - const root = getRoot(tree) + const root = getMerkleRoot(tree) await expect( pool.connect(bob).enableAndSetClaimed(TREE, root, [bob.address]) ).to.be.revertedWith('Unauthorized') diff --git a/source/pool/test/PoolIntegration.js b/source/pool/test/PoolIntegration.js index d3face25d..9d7d8e0fc 100644 --- a/source/pool/test/PoolIntegration.js +++ b/source/pool/test/PoolIntegration.js @@ -1,6 +1,10 @@ const { expect } = require('chai') -const { toAtomicString } = require('@airswap/utils') -const { generateTreeFromData, getRoot, getProof } = require('@airswap/merkle') +const { + toAtomicString, + generateMerkleTreeFromData, + getMerkleRoot, + getMerkleProof, +} = require('@airswap/utils') const { soliditySha3 } = require('web3-utils') const { ethers } = require('hardhat') @@ -73,7 +77,7 @@ describe('Pool Integration', () => { await pool.setAdmin(deployer.address) - tree = generateTreeFromData({ + tree = generateMerkleTreeFromData({ [alice.address]: ALICE_SCORE, [bob.address]: BOB_SCORE, [carol.address]: CAROL_SCORE, @@ -82,12 +86,12 @@ describe('Pool Integration', () => { describe('withdraw increase the staker balance', async () => { it('transfers the claimed funds to the staker', async () => { - const root = getRoot(tree) + const root = getMerkleRoot(tree) expect(await pool.connect(deployer).enable(TREE_ID, root)).to.emit( pool, 'Enable' ) - const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) await pool.connect(bob).withdraw( [ { diff --git a/source/registry/package.json b/source/registry/package.json index 14e02e2a5..d820d8ec6 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,8 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/constants": "4.2.0", - "@airswap/utils": "4.2.0", + "@airswap/utils": "4.2.1", "prompt-confirm": "^2.0.4" } } diff --git a/source/registry/scripts/config.js b/source/registry/scripts/config.js index 78d9238c7..ac7734214 100644 --- a/source/registry/scripts/config.js +++ b/source/registry/scripts/config.js @@ -2,7 +2,7 @@ const { ChainIds, stakingTokenAddresses, ADDRESS_ZERO, -} = require('@airswap/constants') +} = require('@airswap/utils') const wrappedTokenAddresses = require('@airswap/wrapper/deploys-weth') module.exports = { diff --git a/source/registry/scripts/deploy.js b/source/registry/scripts/deploy.js index 77c821893..3fd842424 100644 --- a/source/registry/scripts/deploy.js +++ b/source/registry/scripts/deploy.js @@ -3,7 +3,7 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { ChainIds, chainLabels, chainNames } = require('@airswap/constants') +const { ChainIds, chainLabels, chainNames } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const registryDeploys = require('../deploys.js') const registryBlocks = require('../deploys-blocks.js') diff --git a/source/registry/scripts/verify.js b/source/registry/scripts/verify.js index 132d40abc..d26aec8f3 100644 --- a/source/registry/scripts/verify.js +++ b/source/registry/scripts/verify.js @@ -1,7 +1,7 @@ /* eslint-disable no-console */ const { ethers, run } = require('hardhat') const registryDeploys = require('../deploys.js') -const { chainNames } = require('@airswap/constants') +const { chainNames } = require('@airswap/utils') const config = require('./config.js') async function main() { diff --git a/source/staking/package.json b/source/staking/package.json index d92a9af17..42b9bd164 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.0", + "@airswap/utils": "4.2.1", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/scripts/config.js b/source/staking/scripts/config.js index 692b508d2..f5d364331 100644 --- a/source/staking/scripts/config.js +++ b/source/staking/scripts/config.js @@ -1,4 +1,4 @@ -const { ChainIds, stakingTokenAddresses } = require('@airswap/constants') +const { ChainIds, stakingTokenAddresses } = require('@airswap/utils') module.exports = { [ChainIds.MAINNET]: { name: 'Staked AST', diff --git a/source/staking/scripts/deploy.js b/source/staking/scripts/deploy.js index c51e49e0d..895ac2861 100644 --- a/source/staking/scripts/deploy.js +++ b/source/staking/scripts/deploy.js @@ -3,7 +3,7 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { chainNames, chainLabels, ChainIds } = require('@airswap/constants') +const { chainNames, chainLabels, ChainIds } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const stakingDeploys = require('../deploys.js') const stakingBlocks = require('../deploys-blocks.js') diff --git a/source/staking/scripts/verify.js b/source/staking/scripts/verify.js index cce4d78a0..fd65dafa5 100644 --- a/source/staking/scripts/verify.js +++ b/source/staking/scripts/verify.js @@ -1,7 +1,7 @@ /* eslint-disable no-console */ const { ethers, run } = require('hardhat') const stakingDeploys = require('../deploys.js') -const { chainNames } = require('@airswap/constants') +const { chainNames } = require('@airswap/utils') const config = require('./config.js') async function main() { diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index c9546e6c1..94aecacee 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -29,10 +29,8 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/constants": "4.2.0", "@airswap/staking": "4.0.5", - "@airswap/types": "4.2.0", - "@airswap/utils": "4.2.0", + "@airswap/utils": "4.2.1", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap-erc20/scripts/config.js b/source/swap-erc20/scripts/config.js index 53c9921cc..280e8754c 100644 --- a/source/swap-erc20/scripts/config.js +++ b/source/swap-erc20/scripts/config.js @@ -1,4 +1,4 @@ -const { ChainIds } = require('@airswap/constants') +const { ChainIds } = require('@airswap/utils') module.exports = { [ChainIds.MAINNET]: { diff --git a/source/swap-erc20/scripts/deploy.js b/source/swap-erc20/scripts/deploy.js index 28c58cf7e..e291f51d5 100644 --- a/source/swap-erc20/scripts/deploy.js +++ b/source/swap-erc20/scripts/deploy.js @@ -10,7 +10,7 @@ const { chainNames, protocolFeeReceiverAddresses, ADDRESS_ZERO, -} = require('@airswap/constants') +} = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const swapERC20Deploys = require('../deploys.js') const swapERC20Blocks = require('../deploys-blocks.js') diff --git a/source/swap-erc20/scripts/verify.js b/source/swap-erc20/scripts/verify.js index c178b3c04..349d7aac1 100644 --- a/source/swap-erc20/scripts/verify.js +++ b/source/swap-erc20/scripts/verify.js @@ -5,7 +5,7 @@ const { ChainIds, chainNames, protocolFeeReceiverAddresses, -} = require('@airswap/constants') +} = require('@airswap/utils') const swapERC20Deploys = require('../deploys.js') const config = require('./config.js') diff --git a/source/swap-erc20/test/SwapERC20.js b/source/swap-erc20/test/SwapERC20.js index 597dc9c12..bb312982d 100644 --- a/source/swap-erc20/test/SwapERC20.js +++ b/source/swap-erc20/test/SwapERC20.js @@ -1,5 +1,5 @@ const { expect } = require('chai') -const { ADDRESS_ZERO, SECONDS_IN_DAY } = require('@airswap/constants') +const { ADDRESS_ZERO, SECONDS_IN_DAY } = require('@airswap/utils') const { createOrderERC20, orderERC20ToParams, diff --git a/source/swap/package.json b/source/swap/package.json index cea3b0a6b..7dbcdd6fc 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,9 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/constants": "4.2.0", - "@airswap/types": "4.2.0", - "@airswap/utils": "4.2.0", + "@airswap/utils": "4.2.1", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/swap/scripts/config.js b/source/swap/scripts/config.js index 4903a8a0b..b36b93558 100644 --- a/source/swap/scripts/config.js +++ b/source/swap/scripts/config.js @@ -1,4 +1,4 @@ -const { ChainIds, TokenKinds } = require('@airswap/constants') +const { ChainIds, TokenKinds } = require('@airswap/utils') module.exports = { [ChainIds.MAINNET]: { diff --git a/source/swap/scripts/deploy-adapters.js b/source/swap/scripts/deploy-adapters.js index d46b476fc..de29cd44f 100644 --- a/source/swap/scripts/deploy-adapters.js +++ b/source/swap/scripts/deploy-adapters.js @@ -3,7 +3,7 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { chainNames, chainLabels, ChainIds } = require('@airswap/constants') +const { chainNames, chainLabels, ChainIds } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const adapterDeploys = require('../deploys-adapters.js') const adapterBlocks = require('../deploys-adapters-blocks.js') diff --git a/source/swap/scripts/deploy.js b/source/swap/scripts/deploy.js index c3a1407e8..523e2eebe 100644 --- a/source/swap/scripts/deploy.js +++ b/source/swap/scripts/deploy.js @@ -9,7 +9,7 @@ const { ChainIds, protocolFeeReceiverAddresses, ADDRESS_ZERO, -} = require('@airswap/constants') +} = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const poolDeploys = require('@airswap/pool/deploys.js') const swapDeploys = require('../deploys.js') diff --git a/source/swap/scripts/verify-adapters.js b/source/swap/scripts/verify-adapters.js index ee482299a..2d2035308 100644 --- a/source/swap/scripts/verify-adapters.js +++ b/source/swap/scripts/verify-adapters.js @@ -1,6 +1,6 @@ /* eslint-disable no-console */ const { ethers, run } = require('hardhat') -const { chainNames } = require('@airswap/constants') +const { chainNames } = require('@airswap/utils') const adapterDeploys = require('../deploys-adapters.js') async function main() { diff --git a/source/swap/scripts/verify.js b/source/swap/scripts/verify.js index e446a2eac..e1a1fa145 100644 --- a/source/swap/scripts/verify.js +++ b/source/swap/scripts/verify.js @@ -5,7 +5,7 @@ const { ChainIds, chainNames, protocolFeeReceiverAddresses, -} = require('@airswap/constants') +} = require('@airswap/utils') const swapDeploys = require('../deploys.js') const adapterDeploys = require('../deploys-adapters.js') const config = require('./config.js') diff --git a/source/swap/test/ERC1155Adapter.js b/source/swap/test/ERC1155Adapter.js index 0cab0f356..aa6ee2701 100644 --- a/source/swap/test/ERC1155Adapter.js +++ b/source/swap/test/ERC1155Adapter.js @@ -2,7 +2,7 @@ const { expect } = require('chai') const { ethers, waffle } = require('hardhat') const IERC1155 = require('@openzeppelin/contracts/build/contracts/IERC1155.json') const { deployMockContract } = waffle -const { ADDRESS_ZERO, TokenKinds } = require('@airswap/constants') +const { ADDRESS_ZERO, TokenKinds } = require('@airswap/utils') let snapshotId let adapter diff --git a/source/swap/test/ERC20Adapter.js b/source/swap/test/ERC20Adapter.js index 9d37547df..b9c0ac0e1 100644 --- a/source/swap/test/ERC20Adapter.js +++ b/source/swap/test/ERC20Adapter.js @@ -2,7 +2,7 @@ const { expect } = require('chai') const { ethers, waffle } = require('hardhat') const IERC20 = require('@openzeppelin/contracts/build/contracts/IERC20.json') const { deployMockContract } = waffle -const { ADDRESS_ZERO, TokenKinds } = require('@airswap/constants') +const { ADDRESS_ZERO, TokenKinds } = require('@airswap/utils') let snapshotId let adapter diff --git a/source/swap/test/ERC721Adapter.js b/source/swap/test/ERC721Adapter.js index 8424c545b..099a9c463 100644 --- a/source/swap/test/ERC721Adapter.js +++ b/source/swap/test/ERC721Adapter.js @@ -2,7 +2,7 @@ const { expect } = require('chai') const { ethers, waffle } = require('hardhat') const IERC721 = require('@openzeppelin/contracts/build/contracts/IERC721.json') const { deployMockContract } = waffle -const { ADDRESS_ZERO, TokenKinds } = require('@airswap/constants') +const { ADDRESS_ZERO, TokenKinds } = require('@airswap/utils') let snapshotId let adapter diff --git a/source/swap/test/Swap.js b/source/swap/test/Swap.js index 265d2b6dd..14c108e4e 100644 --- a/source/swap/test/Swap.js +++ b/source/swap/test/Swap.js @@ -6,7 +6,7 @@ const IERC20 = require('@openzeppelin/contracts/build/contracts/IERC20.json') const IERC721 = require('@openzeppelin/contracts/build/contracts/ERC721Royalty.json') const IERC1155 = require('@openzeppelin/contracts/build/contracts/IERC1155.json') const { createOrder, createOrderSignature } = require('@airswap/utils') -const { TokenKinds, ADDRESS_ZERO } = require('@airswap/constants') +const { TokenKinds, ADDRESS_ZERO } = require('@airswap/utils') const CHAIN_ID = 31337 const PROTOCOL_FEE = '30' diff --git a/source/swap/test/SwapIntegration.js b/source/swap/test/SwapIntegration.js index b52efe754..a40d22cff 100644 --- a/source/swap/test/SwapIntegration.js +++ b/source/swap/test/SwapIntegration.js @@ -1,7 +1,7 @@ const { expect } = require('chai') const { ethers } = require('hardhat') const { createOrder, createOrderSignature } = require('@airswap/utils') -const { TokenKinds, ADDRESS_ZERO } = require('@airswap/constants') +const { TokenKinds, ADDRESS_ZERO } = require('@airswap/utils') const ERC20PresetMinterPauser = require('@openzeppelin/contracts/build/contracts/ERC20PresetMinterPauser.json') const ERC1155PresetMinterPauser = require('@openzeppelin/contracts/build/contracts/ERC1155PresetMinterPauser.json') diff --git a/source/wrapper/package.json b/source/wrapper/package.json index ac96a746e..99926fbd7 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,9 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/constants": "4.2.0", - "@airswap/utils": "4.2.0", - "@airswap/types": "4.2.0", + "@airswap/utils": "4.2.1", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/source/wrapper/scripts/deploy.js b/source/wrapper/scripts/deploy.js index 9ec6d9954..220eecb38 100644 --- a/source/wrapper/scripts/deploy.js +++ b/source/wrapper/scripts/deploy.js @@ -7,7 +7,7 @@ const swapDeploys = require('@airswap/swap-erc20/deploys.js') const wrapperDeploys = require('../deploys.js') const wrapperBlocks = require('../deploys-blocks.js') const wethDeploys = require('../deploys-weth.js') -const { ChainIds, chainNames, chainLabels } = require('@airswap/constants') +const { ChainIds, chainNames, chainLabels } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') async function main() { diff --git a/source/wrapper/scripts/verify.js b/source/wrapper/scripts/verify.js index 594118571..f4416c395 100644 --- a/source/wrapper/scripts/verify.js +++ b/source/wrapper/scripts/verify.js @@ -3,7 +3,7 @@ const { ethers, run } = require('hardhat') const swapERC20Deploys = require('@airswap/swap-erc20/deploys.js') const wrapperDeploys = require('../deploys.js') const wethDeploys = require('../deploys-weth.js') -const { chainNames } = require('@airswap/constants') +const { chainNames } = require('@airswap/utils') async function main() { await run('compile') diff --git a/source/wrapper/test/Wrapper.js b/source/wrapper/test/Wrapper.js index 957e94fa6..be3c910df 100644 --- a/source/wrapper/test/Wrapper.js +++ b/source/wrapper/test/Wrapper.js @@ -6,7 +6,7 @@ const { } = require('@airswap/utils') const { ethers, waffle } = require('hardhat') const { deployMockContract } = waffle -const { ADDRESS_ZERO } = require('@airswap/constants') +const { ADDRESS_ZERO } = require('@airswap/utils') const IERC20 = require('@openzeppelin/contracts/build/contracts/IERC20.json') const IWETH = require('../build/contracts/interfaces/IWETH.sol/IWETH.json') diff --git a/tools/constants/LICENSE b/tools/constants/LICENSE deleted file mode 100644 index 25fb212c5..000000000 --- a/tools/constants/LICENSE +++ /dev/null @@ -1,19 +0,0 @@ -Copyright 2023 AirSwap - -Permission is hereby granted, free of charge, to any person obtaining a -copy of this software and associated documentation files (the "Software"), -to deal in the Software without restriction, including without limitation -the rights to use, copy, modify, merge, publish, distribute, sublicense, -and/or sell copies of the Software, and to permit persons to whom the -Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER -DEALINGS IN THE SOFTWARE. diff --git a/tools/constants/README.md b/tools/constants/README.md deleted file mode 100644 index 1d387302c..000000000 --- a/tools/constants/README.md +++ /dev/null @@ -1,36 +0,0 @@ -# Constants - -Helpful Constants for AirSwap Developers - -[![Discord](https://img.shields.io/discord/590643190281928738.svg)](https://discord.gg/ecQbV7H) -[![License](https://img.shields.io/badge/License-MIT-blue)](https://opensource.org/licenses/MIT) -![Twitter Follow](https://img.shields.io/twitter/follow/airswap?style=social) - -## Resources - -- About → https://about.airswap.io/ -- Website → https://www.airswap.io/ -- Twitter → https://twitter.com/airswap -- Chat → https://chat.airswap.io/ - -## Usage - -Add the package to your project: - -```console -yarn add @airswap/constants -``` - -Import into your application: - -```TypeScript -import { ChainIds, TokenKinds, protocols } from '@airswap/constants'; -``` - -## Commands - -| Command | Description | -| :------------- | :-------------------------------------- | -| `yarn` | Install dependencies | -| `yarn clean` | Delete the contract `build` folder | -| `yarn compile` | Compile all contracts to `build` folder | diff --git a/tools/constants/package.json b/tools/constants/package.json deleted file mode 100644 index bcb9ff5da..000000000 --- a/tools/constants/package.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "name": "@airswap/constants", - "version": "4.2.0", - "description": "AirSwap: Constants for Developers", - "repository": { - "type": "git", - "url": "https://github.com/airswap/airswap-protocols" - }, - "keywords": [ - "airswap" - ], - "license": "MIT", - "main": "build/index.js", - "files": [ - "/build" - ], - "scripts": { - "clean": "rm -rf ./build", - "compile": "yarn clean && tsc -b", - "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts", - "test:ci": "yarn test" - }, - "publishConfig": { - "access": "public" - } -} diff --git a/tools/constants/test/utils.ts b/tools/constants/test/utils.ts deleted file mode 100644 index 150e09eb5..000000000 --- a/tools/constants/test/utils.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { expect } from 'chai' -import { protocolInterfaces } from '../index' - -import { getInterfaceId } from '@airswap/utils' - -describe('Constants', async () => { - it('InterfaceIds are correct', async () => { - for (const interfaceId in protocolInterfaces) { - expect(getInterfaceId(protocolInterfaces[interfaceId])).to.be.equal( - interfaceId - ) - } - }) -}) diff --git a/tools/constants/tsconfig.json b/tools/constants/tsconfig.json deleted file mode 100644 index 433db29c9..000000000 --- a/tools/constants/tsconfig.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "./build" - } -} diff --git a/tools/libraries/package.json b/tools/libraries/package.json index ba2e7d9a6..73c82ce3b 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -27,15 +27,13 @@ }, "dependencies": { "@airswap/batch-call": "4.2.0", - "@airswap/constants": "4.2.0", "@airswap/jsonrpc-client-websocket": "0.0.1", "@airswap/registry": "4.2.0", "@airswap/pool": "4.1.4", "@airswap/staking": "4.0.5", "@airswap/swap": "4.2.0", "@airswap/swap-erc20": "4.2.0", - "@airswap/types": "4.2.0", - "@airswap/utils": "4.2.0", + "@airswap/utils": "4.2.1", "@airswap/wrapper": "4.1.5", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", diff --git a/tools/libraries/src/Registry.ts b/tools/libraries/src/Registry.ts index 23ce801cd..96d55e824 100644 --- a/tools/libraries/src/Registry.ts +++ b/tools/libraries/src/Registry.ts @@ -1,5 +1,5 @@ import { ethers } from 'ethers' -import { ServerOptions } from '@airswap/types' +import { ServerOptions } from '@airswap/utils' import { Registry__factory } from '@airswap/registry/typechain/factories/contracts' import registryDeploys from '@airswap/registry/deploys.js' import registryBlocks from '@airswap/registry/deploys-blocks.js' diff --git a/tools/libraries/src/Server.ts b/tools/libraries/src/Server.ts index c47e992d9..f52ef104d 100644 --- a/tools/libraries/src/Server.ts +++ b/tools/libraries/src/Server.ts @@ -12,24 +12,24 @@ import { } from '@airswap/jsonrpc-client-websocket' import { - parseUrl, - orderERC20PropsToStrings, - isValidOrderERC20, - isValidPricingERC20, -} from '@airswap/utils' -import { - FullOrder, - FullOrderERC20, + ChainIds, + ProtocolIds, + ServerOptions, OrderERC20, + FullOrderERC20, + FullOrder, Pricing, - ServerOptions, - SupportedProtocolInfo, OrderFilter, OrderResponse, Indexes, Direction, -} from '@airswap/types' -import { ChainIds, Protocols, protocolNames } from '@airswap/constants' + SupportedProtocolInfo, + protocolNames, + orderERC20PropsToStrings, + isValidOrderERC20, + isValidPricingERC20, + parseUrl, +} from '@airswap/utils' import { SwapERC20 } from './Contracts' @@ -294,10 +294,10 @@ export class Server extends TypedEmitter { /** * Protocols.Indexing */ - public async addOrder(order: FullOrder): Promise { + public async addOrder(order: FullOrder, tags = []): Promise { try { return Promise.resolve( - (await this.httpCall('addOrder', [order])) as boolean + (await this.httpCall('addOrder', [order, tags])) as boolean ) } catch (err) { return Promise.reject(err) @@ -305,7 +305,7 @@ export class Server extends TypedEmitter { } public async getOrders( - orderFilter: OrderFilter, + filter: OrderFilter, offset = 0, limit = DEFAULT_LIMIT, by = Indexes.NONCE, @@ -314,7 +314,7 @@ export class Server extends TypedEmitter { try { return Promise.resolve( (await this.httpCall('getOrders', [ - { ...this.toBigIntJson(orderFilter) }, + { ...this.toBigIntJson(filter) }, offset, limit, by, @@ -366,7 +366,7 @@ export class Server extends TypedEmitter { if (!clientOnly) { this.supportedProtocols = [ - { name: Protocols.RequestForQuoteERC20, version: '2.0.0' }, + { name: ProtocolIds.RequestForQuoteERC20, version: '2.0.0' }, ] this.isInitialized = true } @@ -448,11 +448,11 @@ export class Server extends TypedEmitter { } private requireRFQERC20Support() { - this.requireProtocolSupport(Protocols.RequestForQuoteERC20) + this.requireProtocolSupport(ProtocolIds.RequestForQuoteERC20) } private requireLastLookERC20Support() { - this.requireProtocolSupport(Protocols.LastLookERC20) + this.requireProtocolSupport(ProtocolIds.LastLookERC20) } private requireProtocolSupport(protocol: string) { @@ -527,7 +527,7 @@ export class Server extends TypedEmitter { this.validateInitializeParams(supportedProtocols) this.supportedProtocols = supportedProtocols const lastLookERC20Support = supportedProtocols.find( - (protocol) => protocol.name === Protocols.LastLookERC20 + (protocol) => protocol.name === ProtocolIds.LastLookERC20 ) if (lastLookERC20Support?.params?.senderServer) { this.senderServer = lastLookERC20Support.params.senderServer diff --git a/tools/libraries/test/Contract.test.ts b/tools/libraries/test/Contract.test.ts index c4bd725f3..0c7c922df 100644 --- a/tools/libraries/test/Contract.test.ts +++ b/tools/libraries/test/Contract.test.ts @@ -1,6 +1,6 @@ import { expect } from 'chai' import { WETH } from '../index' -import { ChainIds } from '@airswap/constants' +import { ChainIds } from '@airswap/utils' describe('Contract', () => { it('get address (WETH)', () => { diff --git a/tools/libraries/test/Server.test.ts b/tools/libraries/test/Server.test.ts index aac3767bd..5204e4739 100644 --- a/tools/libraries/test/Server.test.ts +++ b/tools/libraries/test/Server.test.ts @@ -12,8 +12,12 @@ import { isValidFullOrder, isValidFullOrderERC20, isValidPricingERC20, + ADDRESS_ZERO, + ChainIds, + ProtocolIds, + OrderERC20, + Levels, } from '@airswap/utils' -import { ADDRESS_ZERO, ChainIds, Protocols } from '@airswap/constants' import { Server } from '../index' import { @@ -23,7 +27,6 @@ import { MockSocketServer, nextEvent, } from './test-utils' -import { OrderERC20, Levels } from '@airswap/types' import { JsonRpcErrorCodes } from '@airswap/jsonrpc-client-websocket' addJSONRPCAssertions() @@ -57,7 +60,7 @@ function mockHttpServer(api) { let res switch (body['method']) { case 'getProtocols': - res = [Protocols.Discovery, Protocols.RequestForQuoteERC20] + res = [ProtocolIds.Discovery, ProtocolIds.RequestForQuoteERC20] break case 'getTokens': res = [USDC, USDT] @@ -148,8 +151,8 @@ describe('HTTPServer', () => { .it('Server getProtocols()', async () => { const server = await Server.at(URL) const result = await server.getProtocols() - expect(result[0]).to.be.equal(Protocols.Discovery) - expect(result[1]).to.be.equal(Protocols.RequestForQuoteERC20) + expect(result[0]).to.be.equal(ProtocolIds.Discovery) + expect(result[1]).to.be.equal(ProtocolIds.RequestForQuoteERC20) }) fancy .nock('https://' + URL, mockHttpServer) @@ -286,8 +289,8 @@ describe('WebSocketServer', () => { } mockServer.setNextMessageCallback(onResponse) }) - expect(server.supportsProtocol(Protocols.LastLookERC20)).to.equal(true) - expect(server.supportsProtocol(Protocols.RequestForQuoteERC20)).to.equal( + expect(server.supportsProtocol(ProtocolIds.LastLookERC20)).to.equal(true) + expect(server.supportsProtocol(ProtocolIds.RequestForQuoteERC20)).to.equal( false ) await correctInitializeResponse diff --git a/tools/libraries/test/test-utils.ts b/tools/libraries/test/test-utils.ts index 103bcdaa0..97cf5ffc5 100644 --- a/tools/libraries/test/test-utils.ts +++ b/tools/libraries/test/test-utils.ts @@ -6,7 +6,7 @@ import { } from '@airswap/jsonrpc-client-websocket' import mock from 'mock-require' import { WebSocket, Server as BaseMockSocketServer } from 'mock-socket' -import { Protocols } from '@airswap/constants' +import { ProtocolIds } from '@airswap/utils' export function addJSONRPCAssertions(): void { chai.Assertion.addMethod( @@ -123,13 +123,13 @@ export class MockSocketServer extends BaseMockSocketServer { if (this._initOptions) { if (this._initOptions.lastLook) protocols.push({ - name: Protocols.LastLookERC20, + name: ProtocolIds.LastLookERC20, version: this._initOptions.lastLook, params: this._initOptions.params, }) if (this._initOptions.rfq) protocols.push({ - name: Protocols.RequestForQuoteERC20, + name: ProtocolIds.RequestForQuoteERC20, version: this._initOptions.rfq, params: this._initOptions.params, }) diff --git a/tools/merkle/LICENSE b/tools/merkle/LICENSE deleted file mode 100644 index 25fb212c5..000000000 --- a/tools/merkle/LICENSE +++ /dev/null @@ -1,19 +0,0 @@ -Copyright 2023 AirSwap - -Permission is hereby granted, free of charge, to any person obtaining a -copy of this software and associated documentation files (the "Software"), -to deal in the Software without restriction, including without limitation -the rights to use, copy, modify, merge, publish, distribute, sublicense, -and/or sell copies of the Software, and to permit persons to whom the -Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER -DEALINGS IN THE SOFTWARE. diff --git a/tools/merkle/README.md b/tools/merkle/README.md deleted file mode 100644 index 067be1a04..000000000 --- a/tools/merkle/README.md +++ /dev/null @@ -1,37 +0,0 @@ -# Merkle - -Merkle Tree Utilities - -[![Discord](https://img.shields.io/discord/590643190281928738.svg)](https://discord.gg/ecQbV7H) -[![License](https://img.shields.io/badge/License-MIT-blue)](https://opensource.org/licenses/MIT) -![Twitter Follow](https://img.shields.io/twitter/follow/airswap?style=social) - -## Resources - -- About → https://about.airswap.io/ -- Website → https://www.airswap.io/ -- Twitter → https://twitter.com/airswap -- Chat → https://chat.airswap.io/ - -## Usage - -Add the package to your project: - -```console -yarn add @airswap/merkle -``` - -Import into your application: - -```TypeScript -import { generateTreeFromData, generateTreeFromElements, getRoot, getProof } from '@airswap/merkle'; -``` - -## Commands - -| Command | Description | -| :------------- | :-------------------------------------- | -| `yarn` | Install dependencies | -| `yarn clean` | Delete the contract `build` folder | -| `yarn compile` | Compile all contracts to `build` folder | -| `yarn test` | Run all tests in the `test` folder | diff --git a/tools/merkle/index.ts b/tools/merkle/index.ts deleted file mode 100644 index 1edbc58b8..000000000 --- a/tools/merkle/index.ts +++ /dev/null @@ -1,27 +0,0 @@ -/* eslint-disable @typescript-eslint/no-non-null-assertion */ -export * from './src/merkle' - -import { soliditySha3 } from 'web3-utils' -import { MerkleTree } from './src/merkle' - -export function generateTreeFromElements(elements: Array): MerkleTree { - return new MerkleTree(elements) -} - -export function generateTreeFromData(data: { - [id: string]: string -}): MerkleTree { - const elements: string[] = [] - for (const idx in data) { - elements.push(soliditySha3(idx, data[idx])!) - } - return new MerkleTree(elements) -} - -export function getRoot(tree: MerkleTree): string { - return tree.getHexRoot() -} - -export function getProof(tree: MerkleTree, element: string): Array { - return tree.getHexProof(element) -} diff --git a/tools/merkle/package.json b/tools/merkle/package.json deleted file mode 100644 index b45f19acb..000000000 --- a/tools/merkle/package.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "name": "@airswap/merkle", - "version": "0.0.3", - "description": "Merkle Tree Tools Adapted from OpenZeppelin", - "contributors": [ - "Don Mosites" - ], - "repository": { - "type": "git", - "url": "https://github.com/airswap/airswap-protocols" - }, - "homepage": "https://github.com/airswap/airswap-protocols/tree/main/tools/merkle", - "keywords": [ - "airswap" - ], - "license": "MIT", - "main": "build/index.js", - "files": [ - "/build" - ], - "scripts": { - "clean": "rm -rf ./build", - "compile": "yarn clean && tsc -b", - "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts", - "test:ci": "yarn test" - }, - "dependencies": { - "@types/ethereumjs-util": "^6.1.0", - "ethereumjs-util": "^7.0.7", - "web3-utils": "^1.3.1" - }, - "devDependencies": { - "@types/mocha": "^9.0.0", - "chai": "^4.3.4", - "mocha": "^9.1.3", - "ts-node": "^10.4.0", - "typescript": "^4.5.2" - }, - "publishConfig": { - "access": "public" - } -} diff --git a/tools/merkle/test/merkle.ts b/tools/merkle/test/merkle.ts deleted file mode 100644 index f924c26c2..000000000 --- a/tools/merkle/test/merkle.ts +++ /dev/null @@ -1,28 +0,0 @@ -/* eslint-disable @typescript-eslint/no-non-null-assertion */ -import { expect } from 'chai' -import { soliditySha3 } from 'web3-utils' -import { generateTreeFromData, getRoot, getProof } from '../index' - -describe('Merkle', async () => { - let tree: any - const treeRoot = - '0xad519504d6845f9f2529e80a2247d751af56af868ed9f23398705a1ec1bd9fc4' - const proof = [ - '0xc361555652533965d9a3cda90060cb77c14bbaec689e062a4ca8ce8976836719', - '0xe2ad42ca8c17510e58dca1ba6f472caafa90b9fee56f679b0e000881096562f6', - ] - - it('Creates and validates tree', async () => { - tree = generateTreeFromData({ - a: '1', - b: '2', - c: '3', - }) - expect(getRoot(tree)).to.equal(treeRoot) - }) - - it('Validates proof', async () => { - const element: string = soliditySha3('a', '1')! - expect(getProof(tree, element).join()).to.equal(proof.join()) - }) -}) diff --git a/tools/merkle/tsconfig.json b/tools/merkle/tsconfig.json deleted file mode 100644 index 433db29c9..000000000 --- a/tools/merkle/tsconfig.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "./build" - } -} diff --git a/tools/metadata/README.md b/tools/metadata/README.md index 9912e57d8..492f17baa 100644 --- a/tools/metadata/README.md +++ b/tools/metadata/README.md @@ -25,7 +25,7 @@ Import into your application: ```TypeScript import { getKnownTokens } from '@airswap/metadata' -import { ChainIds } from '@airswap/constants' +import { ChainIds } from '@airswap/utils' const { errors, tokens } = await getKnownTokens(ChainIds.MAINNET) ``` diff --git a/tools/metadata/defaults.ts b/tools/metadata/defaults.ts index a28c0cd33..3b099101f 100644 --- a/tools/metadata/defaults.ts +++ b/tools/metadata/defaults.ts @@ -1,5 +1,4 @@ -import { TokenInfo } from '@airswap/types' -import { ChainIds } from '@airswap/constants' +import { ChainIds, TokenInfo } from '@airswap/utils' const TEST_TOKEN_DECIMALS = 6 diff --git a/tools/metadata/index.ts b/tools/metadata/index.ts index f41311724..d6632d2d1 100644 --- a/tools/metadata/index.ts +++ b/tools/metadata/index.ts @@ -4,18 +4,14 @@ import { CollectionTokenInfo, CollectionTokenMetadata, CollectionTokenAttribute, -} from '@airswap/types' -import tokenlists from './tokenlists' -import defaults from './defaults' -import { TokenKinds, chainCurrencies, chainNames, stakingTokenAddresses, -} from '@airswap/constants' -// @ts-ignore +} from '@airswap/utils' +import tokenlists from './tokenlists' +import defaults from './defaults' import wethDeploys from '@airswap/wrapper/deploys-weth.js' -// @ts-ignore import validUrl from 'valid-url' const AIRSWAP_LOGO_URI = diff --git a/tools/metadata/package.json b/tools/metadata/package.json index 1054f3d5d..1268d7496 100644 --- a/tools/metadata/package.json +++ b/tools/metadata/package.json @@ -20,8 +20,7 @@ "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/constants": "4.2.0", - "@airswap/types": "4.2.0", + "@airswap/utils": "4.2.1", "@airswap/wrapper": "4.1.5", "@openzeppelin/contracts": "^4.8.3", "@uniswap/token-lists": "^1.0.0-beta.24", diff --git a/tools/metadata/test/metadata.ts b/tools/metadata/test/metadata.ts index 0c3ba1374..8a2c1c5b3 100644 --- a/tools/metadata/test/metadata.ts +++ b/tools/metadata/test/metadata.ts @@ -1,6 +1,6 @@ import { expect } from 'chai' import { getKnownTokens, findTokenByAddress } from '../index' -import { ChainIds, ADDRESS_ZERO } from '@airswap/constants' +import { ChainIds, ADDRESS_ZERO } from '@airswap/utils' describe('Metadata: Ethereum', async () => { let result: any diff --git a/tools/metadata/tokenlists.ts b/tools/metadata/tokenlists.ts index fd237583d..f5b3974b1 100644 --- a/tools/metadata/tokenlists.ts +++ b/tools/metadata/tokenlists.ts @@ -1,4 +1,4 @@ -import { ChainIds } from '@airswap/constants' +import { ChainIds } from '@airswap/utils' export default { [ChainIds.MAINNET]: [ diff --git a/tools/types/.npmignore b/tools/types/.npmignore deleted file mode 100644 index 1e7700438..000000000 --- a/tools/types/.npmignore +++ /dev/null @@ -1,8 +0,0 @@ -node_modules -yarn-error.log -lerna-debug.log -.DS_Store -*.swp -*.orig -coverage.json -coverage diff --git a/tools/types/LICENSE b/tools/types/LICENSE deleted file mode 100644 index 25fb212c5..000000000 --- a/tools/types/LICENSE +++ /dev/null @@ -1,19 +0,0 @@ -Copyright 2023 AirSwap - -Permission is hereby granted, free of charge, to any person obtaining a -copy of this software and associated documentation files (the "Software"), -to deal in the Software without restriction, including without limitation -the rights to use, copy, modify, merge, publish, distribute, sublicense, -and/or sell copies of the Software, and to permit persons to whom the -Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER -DEALINGS IN THE SOFTWARE. diff --git a/tools/types/README.md b/tools/types/README.md deleted file mode 100644 index f2aa75546..000000000 --- a/tools/types/README.md +++ /dev/null @@ -1,30 +0,0 @@ -# Types - -[AirSwap](https://www.airswap.io/) is a peer-to-peer trading network for Ethereum tokens. This repository contains a library of Swap Protocol types. - -[![Discord](https://img.shields.io/discord/590643190281928738.svg)](https://discord.gg/ecQbV7H) -[![License](https://img.shields.io/badge/License-MIT-blue)](https://opensource.org/licenses/MIT) -![Twitter Follow](https://img.shields.io/twitter/follow/airswap?style=social) - -## Resources - -- About → https://about.airswap.io/ -- Website → https://www.airswap.io/ -- Twitter → https://twitter.com/airswap -- Chat → https://chat.airswap.io/ - -## Commands - -| Command | Description | -| :-------------- | :-------------------------------------------- | -| `yarn` | Install dependencies | -| `yarn clean` | Delete the contract `build` folder | -| `yarn compile` | Compile all contracts to `build` folder | -| `yarn coverage` | Run solidity-coverage to report test coverage | -| `yarn hint` | Run a syntax linter for all Solidity code | -| `yarn lint` | Run a syntax linter for all JavaScript code | -| `yarn test` | Run all contract tests in `test` folder | - -## Running Tests - -:bulb: Prior to testing locally, run `yarn compile` in the `airswap-protocols` project root to build required artifacts. diff --git a/tools/types/index.ts b/tools/types/index.ts deleted file mode 100644 index eeb07ef9a..000000000 --- a/tools/types/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export * from './src/eip712' -export * from './src/typescript' -export * from './src/server' diff --git a/tools/types/package.json b/tools/types/package.json deleted file mode 100644 index 881ddb9f9..000000000 --- a/tools/types/package.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "name": "@airswap/types", - "version": "4.2.0", - "description": "AirSwap: Types for Developers", - "repository": { - "type": "git", - "url": "https://github.com/airswap/airswap-protocols" - }, - "keywords": [ - "airswap" - ], - "license": "MIT", - "main": "build/index.js", - "types": "build/index.d.ts", - "files": [ - "/build" - ], - "scripts": { - "clean": "rm -rf ./build", - "compile": "yarn clean && tsc -b" - }, - "dependencies": { - "@uniswap/token-lists": "^1.0.0-beta.31" - }, - "publishConfig": { - "access": "public" - } -} diff --git a/tools/types/src/eip712.ts b/tools/types/src/eip712.ts deleted file mode 100644 index 9a353b686..000000000 --- a/tools/types/src/eip712.ts +++ /dev/null @@ -1,54 +0,0 @@ -export function stringifyEIP712Type( - types: { [key: string]: { type: string; name: string }[] }, - primaryType: string -): string { - return types[primaryType].reduce((str, value, index, values) => { - const isEnd = index !== values.length - 1 - return str + `${value.type} ${value.name}${isEnd ? ',' : ')'}` - }, `${primaryType}(`) -} - -export const EIP712SwapERC20 = { - EIP712Domain: [ - { name: 'name', type: 'string' }, - { name: 'version', type: 'string' }, - { name: 'chainId', type: 'uint256' }, - { name: 'verifyingContract', type: 'address' }, - ], - OrderERC20: [ - { name: 'nonce', type: 'uint256' }, - { name: 'expiry', type: 'uint256' }, - { name: 'signerWallet', type: 'address' }, - { name: 'signerToken', type: 'address' }, - { name: 'signerAmount', type: 'uint256' }, - { name: 'protocolFee', type: 'uint256' }, - { name: 'senderWallet', type: 'address' }, - { name: 'senderToken', type: 'address' }, - { name: 'senderAmount', type: 'uint256' }, - ], -} - -export const EIP712Swap = { - EIP712Domain: [ - { name: 'name', type: 'string' }, - { name: 'version', type: 'string' }, - { name: 'chainId', type: 'uint256' }, - { name: 'verifyingContract', type: 'address' }, - ], - Order: [ - { name: 'nonce', type: 'uint256' }, - { name: 'expiry', type: 'uint256' }, - { name: 'protocolFee', type: 'uint256' }, - { name: 'signer', type: 'Party' }, - { name: 'sender', type: 'Party' }, - { name: 'affiliateWallet', type: 'address' }, - { name: 'affiliateAmount', type: 'uint256' }, - ], - Party: [ - { name: 'wallet', type: 'address' }, - { name: 'token', type: 'address' }, - { name: 'kind', type: 'bytes4' }, - { name: 'id', type: 'uint256' }, - { name: 'amount', type: 'uint256' }, - ], -} diff --git a/tools/types/src/typescript.ts b/tools/types/src/typescript.ts deleted file mode 100644 index eb4012fc0..000000000 --- a/tools/types/src/typescript.ts +++ /dev/null @@ -1,119 +0,0 @@ -export type Settlement = { - chainId: number - swapContract: string -} - -export type Signature = { - v: string - r: string - s: string -} - -export type OrderParty = { - wallet: string - token: string - kind: string - id: string - amount: string -} - -export type UnsignedOrder = { - nonce: string - expiry: string - protocolFee: string - signer: OrderParty - sender: OrderParty - affiliateWallet: string - affiliateAmount: string -} - -export type Order = UnsignedOrder & Signature - -export type FullOrder = UnsignedOrder & Signature & Settlement - -export type UnsignedOrderERC20 = { - nonce: string - expiry: string - signerWallet: string - signerToken: string - signerAmount: string - protocolFee: string - senderWallet: string - senderToken: string - senderAmount: string -} - -export type OrderERC20 = { - nonce: string - expiry: string - signerWallet: string - signerToken: string - signerAmount: string - senderToken: string - senderAmount: string -} & Signature - -export type FullOrderERC20 = UnsignedOrderERC20 & Signature & Settlement - -export type SwapERC20 = { - nonce: string - signerWallet: string -} - -export type FullSwapERC20 = { - signerToken: string - signerAmount: string - senderWallet: string - senderToken: string - senderAmount: string - feeAmount: string -} & SwapERC20 - -export type Levels = [string, string][] - -export type Formula = string - -type LevelsOrFomulae = - | { - bid: Levels - ask: Levels - } - | { - bid: Formula - ask: Formula - } - -export type Pricing = { - baseToken: string - quoteToken: string - minimum?: string -} & LevelsOrFomulae - -export type Token = { - address: string - symbol: string - decimals: number -} - -export type { TokenInfo } from '@uniswap/token-lists' - -export interface CollectionTokenAttribute { - label: string - value: string | number -} - -export type CollectionTokenMetadata = { - name?: string - image?: string - description?: string - attributes?: CollectionTokenAttribute[] - createdBy?: string -} - -export type CollectionTokenInfo = { - chainId: number - kind: string - address: string - id: string - uri: string -} & CollectionTokenMetadata diff --git a/tools/types/tsconfig.json b/tools/types/tsconfig.json deleted file mode 100644 index 433db29c9..000000000 --- a/tools/types/tsconfig.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "./build" - } -} diff --git a/tools/utils/index.ts b/tools/utils/index.ts index db383cff8..15142249d 100644 --- a/tools/utils/index.ts +++ b/tools/utils/index.ts @@ -1,10 +1,16 @@ import * as url from 'url' import { ethers } from 'ethers' -import { explorerUrls } from '@airswap/constants' +import { explorerUrls } from './src/constants' +import { soliditySha3 } from 'web3-utils' +import { MerkleTree } from './src/MerkleTree' -export * from './src/pricing' -export * from './src/swap' -export * from './src/swapERC20' +export * from './src/constants' +export * from './src/MerkleTree' +export * from './src/Pricing' +export * from './src/Server' +export * from './src/Swap' +export * from './src/SwapERC20' +export * from './src/types' export function getReceiptUrl(chainId: number, hash: string): string { return `${explorerUrls[chainId]}/tx/${hash}` @@ -25,15 +31,6 @@ export function parseCheckResult(errors: Array) { return res } -export function getTimestamp(): string { - return Math.round(Date.now() / 1000).toString() -} - -export function numberToBytes32(number: number): string { - const hexString = number.toString(16) - return `0x${hexString.padStart(64, '0')}` -} - export function getInterfaceId(functions: string[]): string { const _interface = new ethers.utils.Interface(functions) const interfaceId = ethers.utils.arrayify( @@ -50,6 +47,43 @@ export function getInterfaceId(functions: string[]): string { return ethers.utils.hexlify(interfaceId) } +export function stringifyEIP712Type( + types: { [key: string]: { type: string; name: string }[] }, + primaryType: string +): string { + return types[primaryType].reduce((str, value, index, values) => { + const isEnd = index !== values.length - 1 + return str + `${value.type} ${value.name}${isEnd ? ',' : ')'}` + }, `${primaryType}(`) +} + +export function generateMerkleTreeFromElements( + elements: Array +): MerkleTree { + return new MerkleTree(elements) +} + +export function generateMerkleTreeFromData(data: { + [id: string]: string +}): MerkleTree { + const elements: any[] = [] + for (const idx in data) { + elements.push(soliditySha3(idx, data[idx])) + } + return new MerkleTree(elements) +} + +export function getMerkleRoot(tree: MerkleTree): string { + return tree.getHexRoot() +} + +export function getMerkleProof( + tree: MerkleTree, + element: string +): Array { + return tree.getHexProof(element) +} + export function parseUrl(locator: string): url.UrlWithStringQuery { if (!/(http|ws)s?:\/\//.test(locator)) { locator = `https://${locator}` @@ -69,3 +103,12 @@ export function lowerCaseAddresses(obj: any): any { } return obj } + +export function getTimestamp(): string { + return Math.round(Date.now() / 1000).toString() +} + +export function numberToBytes32(number: number): string { + const hexString = number.toString(16) + return `0x${hexString.padStart(64, '0')}` +} diff --git a/tools/utils/package.json b/tools/utils/package.json index 99406490b..8e5274083 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.0", + "version": "4.2.1", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", @@ -21,8 +21,6 @@ "test:ci": "yarn test" }, "dependencies": { - "@airswap/constants": "4.2.0", - "@airswap/types": "4.2.0", "@metamask/eth-sig-util": "^5.0.2", "bignumber.js": "^9.0.1", "ethereumjs-util": "^7.1.5", diff --git a/tools/merkle/src/merkle.ts b/tools/utils/src/MerkleTree.ts similarity index 95% rename from tools/merkle/src/merkle.ts rename to tools/utils/src/MerkleTree.ts index ba309cc02..9cf2f6ce0 100644 --- a/tools/merkle/src/merkle.ts +++ b/tools/utils/src/MerkleTree.ts @@ -65,15 +65,15 @@ export class MerkleTree { return keccak256(this.sortAndConcat(first, second)) } - public getRoot(): Buffer { + public getMerkleRoot(): Buffer { return this.layers[this.layers.length - 1][0] } public getHexRoot(): string { - return bufferToHex(this.getRoot()) + return bufferToHex(this.getMerkleRoot()) } - public getProof(el: Buffer): Array { + public getMerkleProof(el: Buffer): Array { let idx = this.bufIndexOf(el, this.elements) if (idx === -1) { @@ -97,7 +97,7 @@ export class MerkleTree { public getHexProof(_el: string): Array { const el = Buffer.from(hexToBytes(_el)) - const proof = this.getProof(el) + const proof = this.getMerkleProof(el) return this.bufArrToHexArr(proof) } diff --git a/tools/utils/src/pricing.ts b/tools/utils/src/Pricing.ts similarity index 87% rename from tools/utils/src/pricing.ts rename to tools/utils/src/Pricing.ts index 0dfe3b39f..647a101e9 100644 --- a/tools/utils/src/pricing.ts +++ b/tools/utils/src/Pricing.ts @@ -1,7 +1,25 @@ import BigNumber from 'bignumber.js' import { ethers } from 'ethers' -import { Levels, Formula, Pricing } from '@airswap/types' +export type Levels = [string, string][] + +export type Formula = string + +type LevelsOrFomulae = + | { + bid: Levels + ask: Levels + } + | { + bid: Formula + ask: Formula + } + +export type Pricing = { + baseToken: string + quoteToken: string + minimum?: string +} & LevelsOrFomulae export function isValidPricingERC20(pricing: Pricing[]): boolean { if (!pricing || !pricing.length) return false @@ -28,7 +46,7 @@ export function isValidPricingERC20Pair(pricing: Pricing): boolean { ) } -export function getCostFromPricing( +export function getPriceForAmount( side: 'buy' | 'sell', amount: string, baseToken: string, @@ -38,7 +56,10 @@ export function getCostFromPricing( for (const i in pricing) { if (pricing[i].baseToken.toLowerCase() === baseToken.toLowerCase()) { if (pricing[i].quoteToken.toLowerCase() === quoteToken.toLowerCase()) { - if (pricing[i].minimum && BigNumber(amount).lt(pricing[i].minimum)) { + if ( + pricing[i].minimum && + BigNumber(amount).lt(pricing[i].minimum || 0) + ) { throw new Error( `Requested amount ${amount} does not meet minimum ${pricing[i].minimum}` ) @@ -56,8 +77,6 @@ export function getCostFromPricing( ) } -export const getPriceForAmount = getCostFromPricing - export function calculateCost(amount: string, pricing: Formula | Levels) { // TODO: Formula support if (typeof pricing !== 'string') { diff --git a/tools/types/src/server.ts b/tools/utils/src/Server.ts similarity index 100% rename from tools/types/src/server.ts rename to tools/utils/src/Server.ts diff --git a/tools/utils/src/swap.ts b/tools/utils/src/Swap.ts similarity index 75% rename from tools/utils/src/swap.ts rename to tools/utils/src/Swap.ts index d67b952fa..1221a89b3 100644 --- a/tools/utils/src/swap.ts +++ b/tools/utils/src/Swap.ts @@ -13,16 +13,56 @@ import { ADDRESS_ZERO, DOMAIN_VERSION_SWAP, DOMAIN_NAME_SWAP, -} from '@airswap/constants' +} from './constants' -import { - UnsignedOrder, - OrderParty, - Signature, - EIP712Swap, - Order, - FullOrder, -} from '@airswap/types' +import { Signature, Settlement } from './types' + +export const EIP712Swap = { + EIP712Domain: [ + { name: 'name', type: 'string' }, + { name: 'version', type: 'string' }, + { name: 'chainId', type: 'uint256' }, + { name: 'verifyingContract', type: 'address' }, + ], + Order: [ + { name: 'nonce', type: 'uint256' }, + { name: 'expiry', type: 'uint256' }, + { name: 'protocolFee', type: 'uint256' }, + { name: 'signer', type: 'Party' }, + { name: 'sender', type: 'Party' }, + { name: 'affiliateWallet', type: 'address' }, + { name: 'affiliateAmount', type: 'uint256' }, + ], + Party: [ + { name: 'wallet', type: 'address' }, + { name: 'token', type: 'address' }, + { name: 'kind', type: 'bytes4' }, + { name: 'id', type: 'uint256' }, + { name: 'amount', type: 'uint256' }, + ], +} + +export type OrderParty = { + wallet: string + token: string + kind: string + id: string + amount: string +} + +export type UnsignedOrder = { + nonce: string + expiry: string + protocolFee: string + signer: OrderParty + sender: OrderParty + affiliateWallet: string + affiliateAmount: string +} + +export type Order = UnsignedOrder & Signature + +export type FullOrder = UnsignedOrder & Signature & Settlement const defaultParty: OrderParty = { wallet: ADDRESS_ZERO, diff --git a/tools/utils/src/swapERC20.ts b/tools/utils/src/SwapERC20.ts similarity index 84% rename from tools/utils/src/swapERC20.ts rename to tools/utils/src/SwapERC20.ts index 1ce24b1c9..f11635266 100644 --- a/tools/utils/src/swapERC20.ts +++ b/tools/utils/src/SwapERC20.ts @@ -16,16 +16,67 @@ import { ADDRESS_ZERO, DOMAIN_VERSION_SWAP_ERC20, DOMAIN_NAME_SWAP_ERC20, -} from '@airswap/constants' +} from './constants' -import { - UnsignedOrderERC20, - OrderERC20, - FullOrderERC20, - Signature, - EIP712SwapERC20, - FullSwapERC20, -} from '@airswap/types' +import { Signature, Settlement } from './types' + +export const EIP712SwapERC20 = { + EIP712Domain: [ + { name: 'name', type: 'string' }, + { name: 'version', type: 'string' }, + { name: 'chainId', type: 'uint256' }, + { name: 'verifyingContract', type: 'address' }, + ], + OrderERC20: [ + { name: 'nonce', type: 'uint256' }, + { name: 'expiry', type: 'uint256' }, + { name: 'signerWallet', type: 'address' }, + { name: 'signerToken', type: 'address' }, + { name: 'signerAmount', type: 'uint256' }, + { name: 'protocolFee', type: 'uint256' }, + { name: 'senderWallet', type: 'address' }, + { name: 'senderToken', type: 'address' }, + { name: 'senderAmount', type: 'uint256' }, + ], +} + +export type UnsignedOrderERC20 = { + nonce: string + expiry: string + signerWallet: string + signerToken: string + signerAmount: string + protocolFee: string + senderWallet: string + senderToken: string + senderAmount: string +} + +export type OrderERC20 = { + nonce: string + expiry: string + signerWallet: string + signerToken: string + signerAmount: string + senderToken: string + senderAmount: string +} & Signature + +export type FullOrderERC20 = UnsignedOrderERC20 & Signature & Settlement + +export type SwapERC20 = { + nonce: string + signerWallet: string +} + +export type FullSwapERC20 = { + signerToken: string + signerAmount: string + senderWallet: string + senderToken: string + senderAmount: string + feeAmount: string +} & SwapERC20 export function createOrderERC20({ nonce = Date.now().toString(), diff --git a/tools/constants/index.ts b/tools/utils/src/constants.ts similarity index 88% rename from tools/constants/index.ts rename to tools/utils/src/constants.ts index cc9863b33..ed271ec80 100644 --- a/tools/constants/index.ts +++ b/tools/utils/src/constants.ts @@ -222,28 +222,36 @@ export const protocolFeeReceiverAddresses: Record = { [ChainIds.MAINNET]: '0xaD30f7EEBD9Bd5150a256F47DA41d4403033CdF0', } -export enum Protocols { +export enum ProtocolIds { Discovery = '0xf3713ede', RequestForQuoteERC20 = '0x02ad05d3', LastLookERC20 = '0x395ca9f1', - IndexingERC20 = '0xaf0c1ff7', - Indexing = '0x6d401808', + IndexingERC20 = '0x85ccc7d5', + Indexing = '0x9498325a', +} + +export const protocolNames: Record = { + [ProtocolIds.Discovery]: 'Discovery', + [ProtocolIds.RequestForQuoteERC20]: 'Request for Quote (ERC20)', + [ProtocolIds.LastLookERC20]: 'Last Look (ERC20)', + [ProtocolIds.IndexingERC20]: 'Indexing (ERC20)', + [ProtocolIds.Indexing]: 'Indexing', } export const protocolInterfaces: Record = { - [Protocols.Discovery]: [ + [ProtocolIds.Discovery]: [ 'function getProtocols()', 'function setProtocols(array((string interfaceId,(string chainId,string swapContractAddress,string walletAddress))))', 'function getTokens()', 'function setTokens(array(string tokenContractAddress))', ], - [Protocols.RequestForQuoteERC20]: [ + [ProtocolIds.RequestForQuoteERC20]: [ 'function getSignerSideOrderERC20(string chainId,string swapContractAddress,string senderAmount,string signerToken,string senderToken,string senderWallet,string minExpiry,string proxyingFor)', 'function getSenderSideOrderERC20(string chainId,string swapContractAddress,string signerAmount,string signerToken,string senderToken,string senderWallet,string minExpiry,string proxyingFor)', 'function getPricingERC20(array((string baseToken,string quoteToken)),string minExpiry)', 'function getAllPricingERC20(string minExpiry)', ], - [Protocols.LastLookERC20]: [ + [ProtocolIds.LastLookERC20]: [ 'function subscribePricingERC20(array((string baseToken,string quoteToken)))', 'function subscribeAllPricingERC20()', 'function unsubscribePricingERC20(array((string baseToken,string quoteToken)))', @@ -251,24 +259,16 @@ export const protocolInterfaces: Record = { 'function setPricingERC20(array(string baseToken,string quoteToken,string minimum,array(array((string level,string price))),array(array((string level,string price)))))', 'function considerOrderERC20(string chainId,string swapContractAddress,string nonce,string expiry,string signerWallet,string signerToken,string signerAmount,string senderToken,string senderAmount,string v,string r,string s)', ], - [Protocols.IndexingERC20]: [ - 'function addOrderERC20(string chainId,string swapContractAddress,string nonce,string expiry,string signerWallet,string signerToken,string signerAmount,string senderToken,string senderAmount,string v,string r,string s)', - 'function getOrdersERC20((string chainId,string signerWallet,string signerToken,string senderWallet,string senderToken),string sortField,string sortOrder,string offset,string limit)', + [ProtocolIds.IndexingERC20]: [ + 'function addOrderERC20((string chainId,string swapContractAddress,string nonce,string expiry,string signerWallet,string signerToken,string signerAmount,string senderToken,string senderAmount,string v,string r,string s),bytes[] tags)', + 'function getOrdersERC20((string chainId,string signerWallet,string signerToken,string senderWallet,string senderToken,bytes[] tags),string offset,string limit,string by,string direction)', ], - [Protocols.Indexing]: [ - 'function addOrder(string chainId,string swapContractAddress,uint256 nonce,uint256 expiry,uint256 protocolFee,(address wallet,address token,bytes4 kind,uint256 id,uint256 amount),(address wallet,address token,bytes4 kind,uint256 id,uint256 amount),address affiliateWallet,uint256 affiliateAmount)', - 'function getOrders((string chainId,string signerWallet,string signerToken,string signerId,string senderWallet,string senderToken),string sortField,string sortOrder,string offset,string limit)', + [ProtocolIds.Indexing]: [ + 'function addOrder((string chainId,string swapContractAddress,uint256 nonce,uint256 expiry,uint256 protocolFee,(address wallet,address token,bytes4 kind,uint256 id,uint256 amount),(address wallet,address token,bytes4 kind,uint256 id,uint256 amount),address affiliateWallet,uint256 affiliateAmount),bytes[] tags)', + 'function getOrders((string chainId,string signerWallet,string signerToken,string signerId,string senderWallet,string senderToken,bytes[] tags),string offset,string limit,string by,string direction)', ], } -export const protocolNames: Record = { - [Protocols.Discovery]: 'Discovery', - [Protocols.RequestForQuoteERC20]: 'Request for Quote (ERC20)', - [Protocols.LastLookERC20]: 'Last Look (ERC20)', - [Protocols.IndexingERC20]: 'Indexing (ERC20)', - [Protocols.Indexing]: 'Indexing', -} - export enum TokenKinds { ERC20 = '0x36372b07', ERC721 = '0x80ac58cd', diff --git a/tools/utils/src/types.ts b/tools/utils/src/types.ts new file mode 100644 index 000000000..00f26dbab --- /dev/null +++ b/tools/utils/src/types.ts @@ -0,0 +1,39 @@ +export type Settlement = { + chainId: number + swapContract: string +} + +export type Signature = { + v: string + r: string + s: string +} + +export type Token = { + address: string + symbol: string + decimals: number +} + +export type { TokenInfo } from '@uniswap/token-lists' + +export interface CollectionTokenAttribute { + label: string + value: string | number +} + +export type CollectionTokenMetadata = { + name?: string + image?: string + description?: string + attributes?: CollectionTokenAttribute[] + createdBy?: string +} + +export type CollectionTokenInfo = { + chainId: number + kind: string + address: string + id: string + uri: string +} & CollectionTokenMetadata diff --git a/tools/utils/test/utils.ts b/tools/utils/test/utils.ts index 2684b26b2..700fa6447 100644 --- a/tools/utils/test/utils.ts +++ b/tools/utils/test/utils.ts @@ -1,13 +1,17 @@ import { assert, expect } from 'chai' import { ethers } from 'ethers' +import { Levels, FullOrderERC20, UnsignedOrderERC20 } from '@airswap/utils' + +import { soliditySha3 } from 'web3-utils' import { - ADDRESS_ZERO, - SECONDS_IN_DAY, - protocolInterfaces, -} from '@airswap/constants' -import { Levels, FullOrderERC20, UnsignedOrderERC20 } from '@airswap/types' + generateMerkleTreeFromData, + getMerkleRoot, + getMerkleProof, +} from '../index' import { + ADDRESS_ZERO, + SECONDS_IN_DAY, isValidPricingERC20, isValidFullOrderERC20, isValidOrderERC20, @@ -18,12 +22,23 @@ import { calculateCostFromLevels, getInterfaceId, getFullSwapERC20, + protocolInterfaces, } from '../index' const signerPrivateKey = '0x4934d4ff925f39f91e3729fbce52ef12f25fdf93e014e291350f7d314c1a096b' const wallet = new ethers.Wallet(signerPrivateKey) +describe('Protocols', async () => { + it('InterfaceIds are correct', async () => { + for (const interfaceId in protocolInterfaces) { + expect(getInterfaceId(protocolInterfaces[interfaceId])).to.be.equal( + interfaceId + ) + } + }) +}) + describe('Utils', async () => { let unsignedOrder: UnsignedOrderERC20 before(async () => { @@ -213,3 +228,27 @@ describe('Utils', async () => { }) }) }) + +describe('Merkle', async () => { + let tree: any + const treeRoot = + '0xad519504d6845f9f2529e80a2247d751af56af868ed9f23398705a1ec1bd9fc4' + const proof = [ + '0xc361555652533965d9a3cda90060cb77c14bbaec689e062a4ca8ce8976836719', + '0xe2ad42ca8c17510e58dca1ba6f472caafa90b9fee56f679b0e000881096562f6', + ] + + it('Creates and validates tree', async () => { + tree = generateMerkleTreeFromData({ + a: '1', + b: '2', + c: '3', + }) + expect(getMerkleRoot(tree)).to.equal(treeRoot) + }) + + it('Validates proof', async () => { + const element: any = soliditySha3('a', '1') + expect(getMerkleProof(tree, element).join()).to.equal(proof.join()) + }) +}) diff --git a/yarn.lock b/yarn.lock index 11a57c5d9..6de59e506 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1796,13 +1796,6 @@ dependencies: "@types/node" "*" -"@types/ethereumjs-util@^6.1.0": - version "6.1.0" - resolved "https://registry.yarnpkg.com/@types/ethereumjs-util/-/ethereumjs-util-6.1.0.tgz#9dabd7302ec9728a7d99be15f4143977c33cd5ac" - integrity sha512-5N0RJldhKCKwDksdnuNHbEJuwO5pjEdtwdHj/kZLxaS84s5R1NLgYfAuDF/VZ4whYABJJvv+o0O8TXLm+F/Byw== - dependencies: - ethereumjs-util "*" - "@types/form-data@0.0.33": version "0.0.33" resolved "https://registry.yarnpkg.com/@types/form-data/-/form-data-0.0.33.tgz#c9ac85b2a5fd18435b8c85d9ecb50e6d6c893ff8" @@ -1874,11 +1867,6 @@ resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-10.0.1.tgz#2f4f65bb08bc368ac39c96da7b2f09140b26851b" integrity sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q== -"@types/mocha@^9.0.0": - version "9.1.1" - resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-9.1.1.tgz#e7c4f1001eefa4b8afbd1eee27a237fee3bf29c4" - integrity sha512-Z61JK7DKDtdKTWwLeElSEBcWGRLY8g95ic5FoQqI9CMx0ns/Ghep3B4DfcEimiKMvtamNVULVNKEsiwV3aQmXw== - "@types/mock-require@^2.0.0": version "2.0.1" resolved "https://registry.yarnpkg.com/@types/mock-require/-/mock-require-2.0.1.tgz#1546819af1d8d5b124f5f70aff130cc77c53573e" @@ -2076,17 +2064,12 @@ "@typescript-eslint/types" "5.58.0" eslint-visitor-keys "^3.3.0" -"@ungap/promise-all-settled@1.1.2": - version "1.1.2" - resolved "https://registry.yarnpkg.com/@ungap/promise-all-settled/-/promise-all-settled-1.1.2.tgz#aa58042711d6e3275dd37dc597e5d31e8c290a44" - integrity sha512-sL/cEvJWAnClXw0wHk85/2L0G6Sj8UB0Ctc1TEMbKSsmpRosqhwj9gWgFRZSrBr2f9tiXISwNhCPmlfqUqyb9Q== - "@uniswap/lib@1.1.1": version "1.1.1" resolved "https://registry.yarnpkg.com/@uniswap/lib/-/lib-1.1.1.tgz#0afd29601846c16e5d082866cbb24a9e0758e6bc" integrity sha512-2yK7sLpKIT91TiS5sewHtOa7YuM8IuBXVl4GZv2jZFys4D2sY7K5vZh6MqD25TPA95Od+0YzCVq6cTF2IKrOmg== -"@uniswap/token-lists@^1.0.0-beta.24", "@uniswap/token-lists@^1.0.0-beta.31": +"@uniswap/token-lists@^1.0.0-beta.24": version "1.0.0-beta.31" resolved "https://registry.yarnpkg.com/@uniswap/token-lists/-/token-lists-1.0.0-beta.31.tgz#ff3852bd505ec7b4c276625c762ea79a93a919ec" integrity sha512-BQVoelKCRf64IToPEs1wxiXOnhr/ukwPOF78XG11PrTAOL4F8umjYKFb8ZPv1/dIJsPaC7GhLSriEqyp94SasQ== @@ -3150,7 +3133,7 @@ cbor@^8.1.0: dependencies: nofilter "^3.1.0" -chai@^4.3.4, chai@^4.3.6: +chai@^4.3.6: version "4.3.7" resolved "https://registry.yarnpkg.com/chai/-/chai-4.3.7.tgz#ec63f6df01829088e8bf55fca839bcd464a8ec51" integrity sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A== @@ -3737,13 +3720,6 @@ debug@4, debug@4.3.4, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, de dependencies: ms "2.1.2" -debug@4.3.3: - version "4.3.3" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.3.tgz#04266e0b70a98d4462e6e288e38259213332b664" - integrity sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q== - dependencies: - ms "2.1.2" - debug@^3.0.1, debug@^3.1.0: version "3.2.7" resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.7.tgz#72580b7e9145fb39b6676f9c5e5fb100b934179a" @@ -4456,17 +4432,6 @@ ethereumjs-abi@0.6.8, ethereumjs-abi@^0.6.8: bn.js "^4.11.8" ethereumjs-util "^6.0.0" -ethereumjs-util@*, ethereumjs-util@^7.0.7, ethereumjs-util@^7.1.0, ethereumjs-util@^7.1.1, ethereumjs-util@^7.1.3, ethereumjs-util@^7.1.4, ethereumjs-util@^7.1.5: - version "7.1.5" - resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-7.1.5.tgz#9ecf04861e4fbbeed7465ece5f23317ad1129181" - integrity sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg== - dependencies: - "@types/bn.js" "^5.1.0" - bn.js "^5.1.2" - create-hash "^1.1.2" - ethereum-cryptography "^0.1.3" - rlp "^2.2.4" - ethereumjs-util@7.1.3: version "7.1.3" resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-7.1.3.tgz#b55d7b64dde3e3e45749e4c41288238edec32d23" @@ -4491,6 +4456,17 @@ ethereumjs-util@^6.0.0, ethereumjs-util@^6.2.1: ethjs-util "0.1.6" rlp "^2.2.3" +ethereumjs-util@^7.1.0, ethereumjs-util@^7.1.1, ethereumjs-util@^7.1.3, ethereumjs-util@^7.1.4, ethereumjs-util@^7.1.5: + version "7.1.5" + resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-7.1.5.tgz#9ecf04861e4fbbeed7465ece5f23317ad1129181" + integrity sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg== + dependencies: + "@types/bn.js" "^5.1.0" + bn.js "^5.1.2" + create-hash "^1.1.2" + ethereum-cryptography "^0.1.3" + rlp "^2.2.4" + ethers@^4.0.40: version "4.0.49" resolved "https://registry.yarnpkg.com/ethers/-/ethers-4.0.49.tgz#0eb0e9161a0c8b4761be547396bbe2fb121a8894" @@ -7198,13 +7174,6 @@ minimatch@3.0.5: dependencies: brace-expansion "^1.1.7" -minimatch@4.2.1: - version "4.2.1" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-4.2.1.tgz#40d9d511a46bdc4e563c22c3080cde9c0d8299b4" - integrity sha512-9Uq1ChtSZO+Mxa/CL1eGizn2vRn3MlLgzhT0Iz8zaY8NdvxvB0d5QdPFmCKf7JKA9Lerx5vRrnwO03jsSfGG9g== - dependencies: - brace-expansion "^1.1.7" - minimatch@5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.0.1.tgz#fb9022f7528125187c92bd9e9b6366be1cf3415b" @@ -7433,36 +7402,6 @@ mocha@^7.1.1: yargs-parser "13.1.2" yargs-unparser "1.6.0" -mocha@^9.1.3: - version "9.2.2" - resolved "https://registry.yarnpkg.com/mocha/-/mocha-9.2.2.tgz#d70db46bdb93ca57402c809333e5a84977a88fb9" - integrity sha512-L6XC3EdwT6YrIk0yXpavvLkn8h+EU+Y5UcCHKECyMbdUIxyMuZj4bX4U9e1nvnvUUvQVsV2VHQr5zLdcUkhW/g== - dependencies: - "@ungap/promise-all-settled" "1.1.2" - ansi-colors "4.1.1" - browser-stdout "1.3.1" - chokidar "3.5.3" - debug "4.3.3" - diff "5.0.0" - escape-string-regexp "4.0.0" - find-up "5.0.0" - glob "7.2.0" - growl "1.10.5" - he "1.2.0" - js-yaml "4.1.0" - log-symbols "4.1.0" - minimatch "4.2.1" - ms "2.1.3" - nanoid "3.3.1" - serialize-javascript "6.0.0" - strip-json-comments "3.1.1" - supports-color "8.1.1" - which "2.0.2" - workerpool "6.2.0" - yargs "16.2.0" - yargs-parser "20.2.4" - yargs-unparser "2.0.0" - mock-require@^3.0.3: version "3.0.3" resolved "https://registry.yarnpkg.com/mock-require/-/mock-require-3.0.3.tgz#ccd544d9eae81dd576b3f219f69ec867318a1946" @@ -7537,11 +7476,6 @@ mute-stream@~1.0.0: resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-1.0.0.tgz#e31bd9fe62f0aed23520aa4324ea6671531e013e" integrity sha512-avsJQhyd+680gKXyG/sQc0nXaC6rBkPOfyHYcFb9+hdkqQkR9bdnkJ0AMZhke0oesPqIO+mFFJ+IdBc7mst4IA== -nanoid@3.3.1: - version "3.3.1" - resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.1.tgz#6347a18cac88af88f58af0b3594b723d5e99bb35" - integrity sha512-n6Vs/3KGyxPQd6uO0eH4Bv0ojGSUvuLlIHtC3Y0kEO23YRge8H9x1GCzLn28YX0H66pMkxuaeESFq4tKISKwdw== - nanoid@3.3.3: version "3.3.3" resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.3.tgz#fd8e8b7aa761fe807dba2d1b98fb7241bb724a25" @@ -10012,7 +9946,7 @@ ts-essentials@^7.0.1: resolved "https://registry.yarnpkg.com/ts-essentials/-/ts-essentials-7.0.3.tgz#686fd155a02133eedcc5362dc8b5056cde3e5a38" integrity sha512-8+gr5+lqO3G84KdiTSMRLtuyJ+nTBVRKuCrK4lidMPdVeEp0uqC875uE5NMcaA7YYMN7XsNiFQuMvasF8HT/xQ== -ts-node@^10.4.0, ts-node@^10.9.1: +ts-node@^10.9.1: version "10.9.1" resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-10.9.1.tgz#e73de9102958af9e1f0b168a6ff320e25adcff4b" integrity sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw== @@ -10223,11 +10157,6 @@ typedarray@^0.0.6: resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.2.2.tgz#5ebb5e5a5b75f085f22bc3f8460fba308310fa78" integrity sha512-mI4WrpHsbCIcwT9cF4FZvr80QUeKvsUsUvKDoR+X/7XHQH98xYD8YHZg7ANtz2GtZt/CBq2QJ0thkGJMHfqc1w== -typescript@^4.5.2: - version "4.9.5" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.9.5.tgz#095979f9bcc0d09da324d58d03ce8f8374cbe65a" - integrity sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g== - typescript@^5.0.4: version "5.0.4" resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.0.4.tgz#b217fd20119bd61a94d4011274e0ab369058da3b" @@ -10455,19 +10384,6 @@ wcwidth@^1.0.0, wcwidth@^1.0.1: dependencies: defaults "^1.0.3" -web3-utils@^1.3.1: - version "1.10.0" - resolved "https://registry.yarnpkg.com/web3-utils/-/web3-utils-1.10.0.tgz#ca4c1b431a765c14ac7f773e92e0fd9377ccf578" - integrity sha512-kSaCM0uMcZTNUSmn5vMEhlo02RObGNRRCkdX0V9UTAU0+lrvn0HSaudyCo6CQzuXUsnuY2ERJGCGPfeWmv19Rg== - dependencies: - bn.js "^5.2.1" - ethereum-bloom-filters "^1.0.6" - ethereumjs-util "^7.1.0" - ethjs-unit "0.1.6" - number-to-bn "1.7.0" - randombytes "^2.1.0" - utf8 "3.0.0" - web3-utils@^1.3.6: version "1.9.0" resolved "https://registry.yarnpkg.com/web3-utils/-/web3-utils-1.9.0.tgz#7c5775a47586cefb4ad488831be8f6627be9283d" @@ -10541,7 +10457,7 @@ which@1.3.1, which@^1.1.1, which@^1.3.1: dependencies: isexe "^2.0.0" -which@2.0.2, which@^2.0.1, which@^2.0.2: +which@^2.0.1, which@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/which/-/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1" integrity sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA== @@ -10595,11 +10511,6 @@ wordwrapjs@^4.0.0: reduce-flatten "^2.0.0" typical "^5.2.0" -workerpool@6.2.0: - version "6.2.0" - resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.2.0.tgz#827d93c9ba23ee2019c3ffaff5c27fccea289e8b" - integrity sha512-Rsk5qQHJ9eowMH28Jwhe8HEbmdYDX4lwoMWshiCXugjtHqMD9ZbiqSDLxcsfdqsETPzVUtX5s1Z5kStiIM6l4A== - workerpool@6.2.1: version "6.2.1" resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.2.1.tgz#46fc150c17d826b86a008e5a4508656777e9c343" From 9e2dc2151af31af0df3122d3c1db82cbe8b5d583 Mon Sep 17 00:00:00 2001 From: don mosites Date: Mon, 29 Jan 2024 10:37:52 +0100 Subject: [PATCH 04/43] update addOrder; OrderFilter (#1277) --- tools/libraries/package.json | 2 +- tools/libraries/src/Server.ts | 7 +++++-- tools/utils/src/Server.ts | 8 +++----- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 73c82ce3b..69a41b519 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.1", + "version": "4.2.2", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", diff --git a/tools/libraries/src/Server.ts b/tools/libraries/src/Server.ts index f52ef104d..34ea779b5 100644 --- a/tools/libraries/src/Server.ts +++ b/tools/libraries/src/Server.ts @@ -259,10 +259,13 @@ export class Server extends TypedEmitter { /** * Protocols.IndexingERC20 */ - public async addOrderERC20(fullOrder: FullOrderERC20): Promise { + public async addOrderERC20( + order: FullOrderERC20, + tags = [] + ): Promise { try { return Promise.resolve( - (await this.httpCall('addOrderERC20', [fullOrder])) as boolean + (await this.httpCall('addOrderERC20', [order, tags])) as boolean ) } catch (err) { return Promise.reject(err) diff --git a/tools/utils/src/Server.ts b/tools/utils/src/Server.ts index 57641920c..3fb5e0130 100644 --- a/tools/utils/src/Server.ts +++ b/tools/utils/src/Server.ts @@ -10,18 +10,16 @@ export type SupportedProtocolInfo = { params?: any } -export type OrderERC20Filter = { +export type OrderFilter = { chainId?: number signerWallet?: string signerToken?: string + signerId?: string senderWallet?: string senderToken?: string + tags?: string[] } -export type OrderFilter = { - signerId?: string -} & OrderERC20Filter - export type OrderResponse = { orders: OrderType[] offset: number From a44e1baa3479887ab50b3482328795b81d38d213 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Mon, 29 Jan 2024 11:00:03 +0100 Subject: [PATCH 05/43] add web3-utils to utils; publish --- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 2 +- tools/metadata/package.json | 2 +- tools/utils/package.json | 5 +++-- 10 files changed, 12 insertions(+), 11 deletions(-) diff --git a/source/batch-call/package.json b/source/batch-call/package.json index af4c4b7ef..2af7abb76 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,7 +31,7 @@ "@airswap/swap-erc20": "4.2.0" }, "devDependencies": { - "@airswap/utils": "4.2.1", + "@airswap/utils": "4.2.2", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index 3fbbdd3bb..6b789a02c 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -32,7 +32,7 @@ }, "devDependencies": { "@airswap/metadata": "4.1.17", - "@airswap/utils": "4.2.1", + "@airswap/utils": "4.2.2", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/registry/package.json b/source/registry/package.json index d820d8ec6..3ea07a141 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.1", + "@airswap/utils": "4.2.2", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index 42b9bd164..1cc67171a 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.1", + "@airswap/utils": "4.2.2", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index 94aecacee..834bf1f35 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -30,7 +30,7 @@ }, "devDependencies": { "@airswap/staking": "4.0.5", - "@airswap/utils": "4.2.1", + "@airswap/utils": "4.2.2", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index 7dbcdd6fc..7fce1a52a 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.1", + "@airswap/utils": "4.2.2", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 99926fbd7..13a009dab 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.1", + "@airswap/utils": "4.2.2", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 69a41b519..a33b74cea 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -33,7 +33,7 @@ "@airswap/staking": "4.0.5", "@airswap/swap": "4.2.0", "@airswap/swap-erc20": "4.2.0", - "@airswap/utils": "4.2.1", + "@airswap/utils": "4.2.2", "@airswap/wrapper": "4.1.5", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", diff --git a/tools/metadata/package.json b/tools/metadata/package.json index 1268d7496..0e65890c9 100644 --- a/tools/metadata/package.json +++ b/tools/metadata/package.json @@ -20,7 +20,7 @@ "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/utils": "4.2.1", + "@airswap/utils": "4.2.2", "@airswap/wrapper": "4.1.5", "@openzeppelin/contracts": "^4.8.3", "@uniswap/token-lists": "^1.0.0-beta.24", diff --git a/tools/utils/package.json b/tools/utils/package.json index 8e5274083..a3c3a2673 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.1", + "version": "4.2.2", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", @@ -25,7 +25,8 @@ "bignumber.js": "^9.0.1", "ethereumjs-util": "^7.1.5", "ethers": "^5.6.9", - "lz-string": "^1.5.0" + "lz-string": "^1.5.0", + "web3-utils": "^1.3.6" }, "devDependencies": { "@openzeppelin/contracts": "^4.8.3" From b4155dd9744c7673003ed61ecbf88c987f67a07e Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Mon, 29 Jan 2024 11:01:17 +0100 Subject: [PATCH 06/43] publish libraries with latest utils --- tools/libraries/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/libraries/package.json b/tools/libraries/package.json index a33b74cea..b2411b722 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.2", + "version": "4.2.3", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", From 148557b95f68343b1ab2fde9e22d3cee6c291a6b Mon Sep 17 00:00:00 2001 From: don mosites Date: Mon, 29 Jan 2024 17:07:22 +0100 Subject: [PATCH 07/43] merge metadata into utils; remove merkle; update readme, copyrights (#1278) * merge metadata into utils; remove merkle; update readme, copyrights * remove unused import * package version updates * rename files with new casing --- LICENSE | 2 +- README.md | 22 +- source/batch-call/package.json | 2 +- source/pool/LICENSE | 2 +- source/pool/package.json | 4 +- source/pool/scripts/balances.js | 3 +- source/pool/test/Pool.js | 76 +++--- source/pool/test/PoolIntegration.js | 14 +- source/registry/LICENSE | 2 +- source/registry/package.json | 2 +- source/staking/LICENSE | 2 +- source/staking/package.json | 2 +- source/swap-erc20/LICENSE | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/LICENSE | 2 +- source/wrapper/package.json | 2 +- tools/libraries/LICENSE | 2 +- tools/libraries/package.json | 4 +- tools/metadata/.npmignore | 4 - tools/metadata/LICENSE | 19 -- tools/metadata/README.md | 39 --- tools/metadata/defaults.ts | 22 -- tools/metadata/package.json | 33 --- tools/metadata/tsconfig.json | 7 - tools/utils/LICENSE | 2 +- tools/utils/index.ts | 40 +-- tools/utils/package.json | 8 +- tools/utils/src/MerkleTree.ts | 151 ----------- .../index.ts => utils/src/metadata.ts} | 23 +- tools/utils/src/{Pricing.ts => pricing.ts} | 0 tools/utils/src/{Server.ts => server.ts} | 0 .../utils/src/{SwapERC20.ts => swap-erc20.ts} | 0 tools/utils/src/{Swap.ts => swap.ts} | 0 tools/{metadata => utils/src}/tokenlists.ts | 0 tools/{metadata => utils}/test/metadata.ts | 8 +- tools/utils/test/utils.ts | 33 +-- yarn.lock | 252 +++++++++++------- 38 files changed, 262 insertions(+), 528 deletions(-) delete mode 100644 tools/metadata/.npmignore delete mode 100644 tools/metadata/LICENSE delete mode 100644 tools/metadata/README.md delete mode 100644 tools/metadata/defaults.ts delete mode 100644 tools/metadata/package.json delete mode 100644 tools/metadata/tsconfig.json delete mode 100644 tools/utils/src/MerkleTree.ts rename tools/{metadata/index.ts => utils/src/metadata.ts} (94%) rename tools/utils/src/{Pricing.ts => pricing.ts} (100%) rename tools/utils/src/{Server.ts => server.ts} (100%) rename tools/utils/src/{SwapERC20.ts => swap-erc20.ts} (100%) rename tools/utils/src/{Swap.ts => swap.ts} (100%) rename tools/{metadata => utils/src}/tokenlists.ts (100%) rename tools/{metadata => utils}/test/metadata.ts (86%) diff --git a/LICENSE b/LICENSE index 25fb212c5..f963da81e 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright 2023 AirSwap +Copyright 2024 AirSwap Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/README.md b/README.md index 2b2afc4b5..f391ef642 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ ## Resources - Discord → https://chat.airswap.io/ -- Twitter → https://twitter.com/airswap +- X → https://x.com/airswap - Website → https://www.airswap.io/ - About → https://about.airswap.io/ @@ -18,22 +18,20 @@ | Package | Version | Description | | :------------------------------------------------------ | :------------------------------------------------------------------------------------------------------------------------ | :---------------------------- | +| [`@airswap/registry`](/source/registry) | [![npm](https://img.shields.io/npm/v/@airswap/registry)](https://www.npmjs.com/package/@airswap/registry) | Server Registry | | [`@airswap/swap`](/source/swap) | [![npm](https://img.shields.io/npm/v/@airswap/swap)](https://www.npmjs.com/package/@airswap/swap) | Atomic Token Swap | | [`@airswap/swap-erc20`](/source/swap-erc20) | [![npm](https://img.shields.io/npm/v/@airswap/swap-erc20)](https://www.npmjs.com/package/@airswap/swap-erc20) | Atomic Token Swap (ERC20) | -| [`@airswap/registry`](/source/registry) | [![npm](https://img.shields.io/npm/v/@airswap/registry)](https://www.npmjs.com/package/@airswap/registry) | Server Discovery | -| [`@airswap/indexer-registry`](/source/indexer-registry) | [![npm](https://img.shields.io/npm/v/@airswap/indexer-registry)](https://www.npmjs.com/package/@airswap/indexer-registry) | Indexer Discovery | -| [`@airswap/staking`](/source/staking) | [![npm](https://img.shields.io/npm/v/@airswap/staking)](https://www.npmjs.com/package/@airswap/staking) | Staking for Participants | -| [`@airswap/pool`](/source/pool) | [![npm](https://img.shields.io/npm/v/@airswap/pool)](https://www.npmjs.com/package/@airswap/pool) | Rewards Pool for Participants | +| [`@airswap/wrapper`](/source/wrapper) | [![npm](https://img.shields.io/npm/v/@airswap/wrapper)](https://www.npmjs.com/package/@airswap/wrapper) | Wrapper for Native Tokens | +| [`@airswap/staking`](/source/staking) | [![npm](https://img.shields.io/npm/v/@airswap/staking)](https://www.npmjs.com/package/@airswap/staking) | Staking for Members | +| [`@airswap/pool`](/source/pool) | [![npm](https://img.shields.io/npm/v/@airswap/pool)](https://www.npmjs.com/package/@airswap/pool) | Rewards Pool for Members | +| [`@airswap/batch-call`](/source/batch-call) | [![npm](https://img.shields.io/npm/v/@airswap/batch-call)](https://www.npmjs.com/package/@airswap/batch-call) | Batch Token and Order Calls | ## Tools | Package | Version | Description | | :-------------------------------------- | :---------------------------------------------------------------------------------------------------------- | :---------------------------- | | [`@airswap/libraries`](tools/libraries) | [![npm](https://img.shields.io/npm/v/@airswap/libraries)](https://www.npmjs.com/package/@airswap/libraries) | Libraries for Developers | -| [`@airswap/metadata`](tools/metadata) | [![npm](https://img.shields.io/npm/v/@airswap/metadata)](https://www.npmjs.com/package/@airswap/metadata) | Token Metadata for Developers | -| [`@airswap/utils`](/tools/utils) | [![npm](https://img.shields.io/npm/v/@airswap/utils)](https://www.npmjs.com/package/@airswap/utils) | Utilities for Developers | -| [`@airswap/types`](/tools/types) | [![npm](https://img.shields.io/npm/v/@airswap/types)](https://www.npmjs.com/package/@airswap/types) | Types for Developers | -| [`@airswap/constants`](tools/constants) | [![npm](https://img.shields.io/npm/v/@airswap/constants)](https://www.npmjs.com/package/@airswap/constants) | Constants for Developers | +| [`@airswap/utils`](/tools/utils) | [![npm](https://img.shields.io/npm/v/@airswap/utils)](https://www.npmjs.com/package/@airswap/utils) | Utils for Developers | ## Commands @@ -53,12 +51,6 @@ Branch from Develop; Merge Feature → Develop → Beta → Main Flow for tool updates (not contracts): Branch from Main; Merge Feature → Main → Develop -## Versioning - -- Major versions include breaking changes. -- Minor versions do not include breaking changes and may include additional functionality. -- Dependencies on fellow @airswap packages should use caret semver. - ## Process **Regular development process for a complete release** diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 2af7abb76..c00bf11dd 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,7 +31,7 @@ "@airswap/swap-erc20": "4.2.0" }, "devDependencies": { - "@airswap/utils": "4.2.2", + "@airswap/utils": "4.2.3", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/LICENSE b/source/pool/LICENSE index 25fb212c5..f963da81e 100644 --- a/source/pool/LICENSE +++ b/source/pool/LICENSE @@ -1,4 +1,4 @@ -Copyright 2023 AirSwap +Copyright 2024 AirSwap Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/source/pool/package.json b/source/pool/package.json index 6b789a02c..0bc4b9be2 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,8 +31,8 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/metadata": "4.1.17", - "@airswap/utils": "4.2.2", + "@airswap/utils": "4.2.3", + "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/scripts/balances.js b/source/pool/scripts/balances.js index 1a02c50e4..faa62119b 100644 --- a/source/pool/scripts/balances.js +++ b/source/pool/scripts/balances.js @@ -1,6 +1,5 @@ const { ethers } = require('hardhat') -const { getKnownTokens } = require('@airswap/metadata') -const { chainNames, ChainIds } = require('@airswap/utils') +const { getKnownTokens, chainNames, ChainIds } = require('@airswap/utils') const BatchCall = require('@airswap/batch-call/build/contracts/BatchCall.sol/BatchCall.json') const batchCallDeploys = require('@airswap/batch-call/deploys.js') const poolDeploys = require('../deploys.js') diff --git a/source/pool/test/Pool.js b/source/pool/test/Pool.js index ecc0d1933..551180487 100644 --- a/source/pool/test/Pool.js +++ b/source/pool/test/Pool.js @@ -1,10 +1,6 @@ const { expect } = require('chai') -const { - toAtomicString, - generateMerkleTreeFromData, - getMerkleRoot, - getMerkleProof, -} = require('@airswap/utils') +const { toAtomicString } = require('@airswap/utils') +const { generateTreeFromData, getRoot, getProof } = require('@airswap/merkle') const { soliditySha3 } = require('web3-utils') const { ethers, waffle } = require('hardhat') @@ -75,13 +71,13 @@ describe('Pool Unit', () => { ).deploy(CLAIM_SCALE, CLAIM_MAX) await pool.deployed() - tree = generateMerkleTreeFromData({ + tree = generateTreeFromData({ [alice.address]: ALICE_SCORE, [bob.address]: BOB_SCORE, [carol.address]: CAROL_SCORE, }) - newTree = generateMerkleTreeFromData({ + newTree = generateTreeFromData({ [alice.address]: ALICE_SCORE, [bob.address]: BOB_NEW_SCORE, [carol.address]: CAROL_SCORE, @@ -122,7 +118,7 @@ describe('Pool Unit', () => { describe('admin functions', async () => { it('enable a claim for a merkle root suceeds', async () => { - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.setAdmin(alice.address) expect(await pool.connect(alice).enable(TREE, root)).to.emit( pool, @@ -131,17 +127,17 @@ describe('Pool Unit', () => { }) it('enable a claim for a merkle root fails when not admin', async () => { - const root = getMerkleRoot(tree) + const root = getRoot(tree) await expect(pool.connect(bob).enable(TREE, root)).to.be.revertedWith( 'Unauthorized' ) }) it('enable a with the same tree overrwrites the previous root', async () => { - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.setAdmin(alice.address) await pool.connect(alice).enable(TREE, root) - const newRoot = getMerkleRoot(newTree) + const newRoot = getRoot(newTree) await expect(pool.connect(alice).enable(TREE, newRoot)).to.be.emit( pool, `Enable` @@ -155,9 +151,9 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( @@ -183,7 +179,7 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.connect(alice).enable(TREE, root) await expect( @@ -201,7 +197,7 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( @@ -229,9 +225,9 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( @@ -271,9 +267,9 @@ describe('Pool Unit', () => { score = 0 await pool.setAdmin(alice.address) - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( @@ -300,12 +296,9 @@ describe('Pool Unit', () => { await feeToken.mock.balanceOf.returns('100000') ;(await feeToken.mock.transfer.returns(true)) - (await pool.setAdmin(alice.address)) - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getMerkleProof( - tree, - soliditySha3(alice.address, ALICE_SCORE) - ) + const proof = getProof(tree, soliditySha3(alice.address, ALICE_SCORE)) const withdrawMinimum = 496 const amount = await pool @@ -338,11 +331,11 @@ describe('Pool Unit', () => { await feeToken.mock.transfer.returns(true) await pool.setAdmin(alice.address) - const root = getMerkleRoot(tree) - const newRoot = getMerkleRoot(newTree) + const root = getRoot(tree) + const newRoot = getRoot(newTree) await pool.connect(alice).enable(TREE, root) await pool.connect(alice).enable(NEW_TREE, newRoot) - const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) await pool.connect(bob).withdraw( [ @@ -375,12 +368,9 @@ describe('Pool Unit', () => { describe('Verify', async () => { it('verification is valid', async () => { await pool.setAdmin(alice.address) - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getMerkleProof( - tree, - soliditySha3(alice.address, ALICE_SCORE) - ) + const proof = getProof(tree, soliditySha3(alice.address, ALICE_SCORE)) const isValid = await pool.verify(alice.address, root, ALICE_SCORE, proof) expect(isValid).to.be.equal(true) @@ -388,12 +378,9 @@ describe('Pool Unit', () => { it('verification is invalid with wrong participant', async () => { await pool.setAdmin(alice.address) - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getMerkleProof( - tree, - soliditySha3(alice.address, ALICE_SCORE) - ) + const proof = getProof(tree, soliditySha3(alice.address, ALICE_SCORE)) const isValid = await pool.verify(bob.address, root, ALICE_SCORE, proof) expect(isValid).to.be.equal(false) @@ -401,12 +388,9 @@ describe('Pool Unit', () => { it('verification is invalid with wrong scroe', async () => { await pool.setAdmin(alice.address) - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.connect(alice).enable(TREE, root) - const proof = getMerkleProof( - tree, - soliditySha3(alice.address, ALICE_SCORE) - ) + const proof = getProof(tree, soliditySha3(alice.address, ALICE_SCORE)) const isValid = await pool.verify(alice.address, root, BOB_SCORE, proof) expect(isValid).to.be.equal(false) @@ -500,10 +484,10 @@ describe('Pool Unit', () => { await feeToken.mock.balanceOf.returns('100000') await await pool.connect(deployer).setAdmin(alice.address) - const root = getMerkleRoot(tree) + const root = getRoot(tree) await pool.connect(alice).enableAndSetClaimed(TREE, root, [bob.address]) - const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) await expect( pool.connect(bob).withdraw( [ @@ -523,7 +507,7 @@ describe('Pool Unit', () => { it('set claimed with non-owner reverts', async () => { await feeToken.mock.balanceOf.returns('100000') - const root = getMerkleRoot(tree) + const root = getRoot(tree) await expect( pool.connect(bob).enableAndSetClaimed(TREE, root, [bob.address]) ).to.be.revertedWith('Unauthorized') diff --git a/source/pool/test/PoolIntegration.js b/source/pool/test/PoolIntegration.js index 9d7d8e0fc..d3face25d 100644 --- a/source/pool/test/PoolIntegration.js +++ b/source/pool/test/PoolIntegration.js @@ -1,10 +1,6 @@ const { expect } = require('chai') -const { - toAtomicString, - generateMerkleTreeFromData, - getMerkleRoot, - getMerkleProof, -} = require('@airswap/utils') +const { toAtomicString } = require('@airswap/utils') +const { generateTreeFromData, getRoot, getProof } = require('@airswap/merkle') const { soliditySha3 } = require('web3-utils') const { ethers } = require('hardhat') @@ -77,7 +73,7 @@ describe('Pool Integration', () => { await pool.setAdmin(deployer.address) - tree = generateMerkleTreeFromData({ + tree = generateTreeFromData({ [alice.address]: ALICE_SCORE, [bob.address]: BOB_SCORE, [carol.address]: CAROL_SCORE, @@ -86,12 +82,12 @@ describe('Pool Integration', () => { describe('withdraw increase the staker balance', async () => { it('transfers the claimed funds to the staker', async () => { - const root = getMerkleRoot(tree) + const root = getRoot(tree) expect(await pool.connect(deployer).enable(TREE_ID, root)).to.emit( pool, 'Enable' ) - const proof = getMerkleProof(tree, soliditySha3(bob.address, BOB_SCORE)) + const proof = getProof(tree, soliditySha3(bob.address, BOB_SCORE)) await pool.connect(bob).withdraw( [ { diff --git a/source/registry/LICENSE b/source/registry/LICENSE index 25fb212c5..f963da81e 100644 --- a/source/registry/LICENSE +++ b/source/registry/LICENSE @@ -1,4 +1,4 @@ -Copyright 2023 AirSwap +Copyright 2024 AirSwap Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/source/registry/package.json b/source/registry/package.json index 3ea07a141..70c3644a5 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.2", + "@airswap/utils": "4.2.3", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/LICENSE b/source/staking/LICENSE index 25fb212c5..f963da81e 100644 --- a/source/staking/LICENSE +++ b/source/staking/LICENSE @@ -1,4 +1,4 @@ -Copyright 2023 AirSwap +Copyright 2024 AirSwap Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/source/staking/package.json b/source/staking/package.json index 1cc67171a..260841f02 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.2", + "@airswap/utils": "4.2.3", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/LICENSE b/source/swap-erc20/LICENSE index 25fb212c5..f963da81e 100644 --- a/source/swap-erc20/LICENSE +++ b/source/swap-erc20/LICENSE @@ -1,4 +1,4 @@ -Copyright 2023 AirSwap +Copyright 2024 AirSwap Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index 834bf1f35..c3ead2d96 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -30,7 +30,7 @@ }, "devDependencies": { "@airswap/staking": "4.0.5", - "@airswap/utils": "4.2.2", + "@airswap/utils": "4.2.3", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index 7fce1a52a..f59f57e22 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.2", + "@airswap/utils": "4.2.3", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/LICENSE b/source/wrapper/LICENSE index 25fb212c5..f963da81e 100644 --- a/source/wrapper/LICENSE +++ b/source/wrapper/LICENSE @@ -1,4 +1,4 @@ -Copyright 2023 AirSwap +Copyright 2024 AirSwap Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 13a009dab..71d9fbb30 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.2", + "@airswap/utils": "4.2.3", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/LICENSE b/tools/libraries/LICENSE index 25fb212c5..f963da81e 100644 --- a/tools/libraries/LICENSE +++ b/tools/libraries/LICENSE @@ -1,4 +1,4 @@ -Copyright 2023 AirSwap +Copyright 2024 AirSwap Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/tools/libraries/package.json b/tools/libraries/package.json index b2411b722..1f2008357 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.3", + "version": "4.2.4", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -33,7 +33,7 @@ "@airswap/staking": "4.0.5", "@airswap/swap": "4.2.0", "@airswap/swap-erc20": "4.2.0", - "@airswap/utils": "4.2.2", + "@airswap/utils": "4.2.3", "@airswap/wrapper": "4.1.5", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", diff --git a/tools/metadata/.npmignore b/tools/metadata/.npmignore deleted file mode 100644 index 3aa4c66d8..000000000 --- a/tools/metadata/.npmignore +++ /dev/null @@ -1,4 +0,0 @@ -node_modules -src -test -tsconfig.json \ No newline at end of file diff --git a/tools/metadata/LICENSE b/tools/metadata/LICENSE deleted file mode 100644 index 161cdb6e9..000000000 --- a/tools/metadata/LICENSE +++ /dev/null @@ -1,19 +0,0 @@ -Copyright 2022 AirSwap - -Permission is hereby granted, free of charge, to any person obtaining a -copy of this software and associated documentation files (the "Software"), -to deal in the Software without restriction, including without limitation -the rights to use, copy, modify, merge, publish, distribute, sublicense, -and/or sell copies of the Software, and to permit persons to whom the -Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER -DEALINGS IN THE SOFTWARE. diff --git a/tools/metadata/README.md b/tools/metadata/README.md deleted file mode 100644 index 492f17baa..000000000 --- a/tools/metadata/README.md +++ /dev/null @@ -1,39 +0,0 @@ -# Metadata - -Token Metadata Tools for AirSwap Developers - -[![Discord](https://img.shields.io/discord/590643190281928738.svg)](https://discord.gg/ecQbV7H) -[![License](https://img.shields.io/badge/License-MIT-blue)](https://opensource.org/licenses/MIT) -![Twitter Follow](https://img.shields.io/twitter/follow/airswap?style=social) - -## Resources - -- About → https://about.airswap.io/ -- Website → https://www.airswap.io/ -- Twitter → https://twitter.com/airswap -- Chat → https://chat.airswap.io/ - -## Usage - -Add the package to your project: - -```console -yarn add @airswap/metadata -``` - -Import into your application: - -```TypeScript -import { getKnownTokens } from '@airswap/metadata' -import { ChainIds } from '@airswap/utils' -const { errors, tokens } = await getKnownTokens(ChainIds.MAINNET) -``` - -## Commands - -| Command | Description | -| :------------- | :-------------------------------------- | -| `yarn` | Install dependencies | -| `yarn clean` | Delete the contract `build` folder | -| `yarn compile` | Compile all contracts to `build` folder | -| `yarn test` | Run all tests in the `test` folder | diff --git a/tools/metadata/defaults.ts b/tools/metadata/defaults.ts deleted file mode 100644 index 3b099101f..000000000 --- a/tools/metadata/defaults.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { ChainIds, TokenInfo } from '@airswap/utils' - -const TEST_TOKEN_DECIMALS = 6 - -// Test tokens for Sepolia - -export default [ - { - address: '0x20aaebad8c7c6ffb6fdaa5a622c399561562beea', - chainId: ChainIds.SEPOLIA, - decimals: TEST_TOKEN_DECIMALS, - name: 'Mintable USDT', - symbol: 'USDT', - }, - { - address: '0xf450ef4f268eaf2d3d8f9ed0354852e255a5eaef', - chainId: ChainIds.SEPOLIA, - decimals: TEST_TOKEN_DECIMALS, - name: 'Mintable USDC', - symbol: 'USDC', - }, -] as TokenInfo[] diff --git a/tools/metadata/package.json b/tools/metadata/package.json deleted file mode 100644 index 0e65890c9..000000000 --- a/tools/metadata/package.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - "name": "@airswap/metadata", - "version": "4.1.17", - "description": "AirSwap: Token Metadata for Developers", - "repository": { - "type": "git", - "url": "https://github.com/airswap/airswap-protocols" - }, - "keywords": [ - "airswap" - ], - "license": "MIT", - "main": "build/index.js", - "files": [ - "/build" - ], - "scripts": { - "clean": "rm -rf ./build", - "compile": "yarn clean && tsc -b", - "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" - }, - "dependencies": { - "@airswap/utils": "4.2.2", - "@airswap/wrapper": "4.1.5", - "@openzeppelin/contracts": "^4.8.3", - "@uniswap/token-lists": "^1.0.0-beta.24", - "ethers": "^5.6.9", - "valid-url": "^1.0.9" - }, - "publishConfig": { - "access": "public" - } -} diff --git a/tools/metadata/tsconfig.json b/tools/metadata/tsconfig.json deleted file mode 100644 index e03a119e1..000000000 --- a/tools/metadata/tsconfig.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "lib": ["dom"], - "outDir": "./build" - } -} diff --git a/tools/utils/LICENSE b/tools/utils/LICENSE index 161cdb6e9..f963da81e 100644 --- a/tools/utils/LICENSE +++ b/tools/utils/LICENSE @@ -1,4 +1,4 @@ -Copyright 2022 AirSwap +Copyright 2024 AirSwap Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), diff --git a/tools/utils/index.ts b/tools/utils/index.ts index 15142249d..7a6101ac1 100644 --- a/tools/utils/index.ts +++ b/tools/utils/index.ts @@ -1,15 +1,14 @@ import * as url from 'url' import { ethers } from 'ethers' import { explorerUrls } from './src/constants' -import { soliditySha3 } from 'web3-utils' -import { MerkleTree } from './src/MerkleTree' export * from './src/constants' -export * from './src/MerkleTree' -export * from './src/Pricing' -export * from './src/Server' -export * from './src/Swap' -export * from './src/SwapERC20' +export * from './src/metadata' +export * from './src/pricing' +export * from './src/server' +export * from './src/swap' +export * from './src/swap-erc20' +export * from './src/tokenlists' export * from './src/types' export function getReceiptUrl(chainId: number, hash: string): string { @@ -57,33 +56,6 @@ export function stringifyEIP712Type( }, `${primaryType}(`) } -export function generateMerkleTreeFromElements( - elements: Array -): MerkleTree { - return new MerkleTree(elements) -} - -export function generateMerkleTreeFromData(data: { - [id: string]: string -}): MerkleTree { - const elements: any[] = [] - for (const idx in data) { - elements.push(soliditySha3(idx, data[idx])) - } - return new MerkleTree(elements) -} - -export function getMerkleRoot(tree: MerkleTree): string { - return tree.getHexRoot() -} - -export function getMerkleProof( - tree: MerkleTree, - element: string -): Array { - return tree.getHexProof(element) -} - export function parseUrl(locator: string): url.UrlWithStringQuery { if (!/(http|ws)s?:\/\//.test(locator)) { locator = `https://${locator}` diff --git a/tools/utils/package.json b/tools/utils/package.json index a3c3a2673..594ed5d11 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.2", + "version": "4.2.3", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", @@ -18,15 +18,17 @@ "clean": "rm -rf ./build", "compile": "yarn clean && tsc -b", "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts", - "test:ci": "yarn test" + "test:ci": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/utils.ts" }, "dependencies": { "@metamask/eth-sig-util": "^5.0.2", + "@openzeppelin/contracts": "^4.8.3", + "@uniswap/token-lists": "^1.0.0-beta.24", "bignumber.js": "^9.0.1", "ethereumjs-util": "^7.1.5", "ethers": "^5.6.9", "lz-string": "^1.5.0", - "web3-utils": "^1.3.6" + "valid-url": "^1.0.9" }, "devDependencies": { "@openzeppelin/contracts": "^4.8.3" diff --git a/tools/utils/src/MerkleTree.ts b/tools/utils/src/MerkleTree.ts deleted file mode 100644 index 9cf2f6ce0..000000000 --- a/tools/utils/src/MerkleTree.ts +++ /dev/null @@ -1,151 +0,0 @@ -// Adapted from OpenZeppelin -// https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/test/helpers/merkleTree.js - -import { keccak256, keccakFromString, bufferToHex } from 'ethereumjs-util' -import { hexToBytes } from 'web3-utils' - -// Merkle tree called with 32 byte hex values -export class MerkleTree { - public elements: any - public layers: any - public id: any - - public constructor(elements: Array) { - this.elements = elements - .filter((el) => el) - .map((el) => Buffer.from(hexToBytes(el))) - - // Sort elements - this.elements.sort(Buffer.compare) - // Deduplicate elements - this.elements = this.bufDedup(this.elements) - - // Create layers - this.layers = this.getLayers(this.elements) - } - - public getLayers(elements: Array): Array> { - if (elements.length === 0) { - return [['']] - } - - const layers: any = [] - layers.push(elements) - - // Get next layer until we reach the root - while (layers[layers.length - 1].length > 1) { - layers.push(this.getNextLayer(layers[layers.length - 1])) - } - - return layers - } - - public getNextLayer(elements: Array): Array { - return elements.reduce( - (layer: Buffer[], el: Buffer, idx: number, arr: Buffer[]) => { - if (idx % 2 === 0) { - // Hash the current element with its pair element - layer.push(this.combinedHash(el, arr[idx + 1])) - } - - return layer - }, - [] - ) - } - - public combinedHash(first: Buffer, second: Buffer): Buffer { - if (!first) { - return second - } - if (!second) { - return first - } - - return keccak256(this.sortAndConcat(first, second)) - } - - public getMerkleRoot(): Buffer { - return this.layers[this.layers.length - 1][0] - } - - public getHexRoot(): string { - return bufferToHex(this.getMerkleRoot()) - } - - public getMerkleProof(el: Buffer): Array { - let idx = this.bufIndexOf(el, this.elements) - - if (idx === -1) { - throw new Error('Element does not exist in Merkle tree') - } - - return this.layers.reduce((proof: string[], layer: any) => { - const pairElement = this.getPairElement(idx, layer) - - if (pairElement) { - proof.push(pairElement) - } - - idx = Math.floor(idx / 2) - - return proof - }, []) - } - - // external call - convert to buffer - public getHexProof(_el: string): Array { - const el = Buffer.from(hexToBytes(_el)) - - const proof = this.getMerkleProof(el) - - return this.bufArrToHexArr(proof) - } - - public getPairElement(idx: number, layer: string): string | null { - const pairIdx = idx % 2 === 0 ? idx + 1 : idx - 1 - - if (pairIdx < layer.length) { - return layer[pairIdx] - } else { - return null - } - } - - public bufIndexOf(el: Buffer | string, arr: Array): number { - let hash - - // Convert element to 32 byte hash if it is not one already - if (el.length !== 32 || !Buffer.isBuffer(el)) { - hash = keccakFromString(String(el)) - } else { - hash = el - } - - for (let i = 0; i < arr.length; i++) { - if (hash.equals(Buffer.from(arr[i]))) { - return i - } - } - - return -1 - } - - public bufDedup(elements: Array): Array { - return elements.filter((el, idx) => { - return idx === 0 || !elements[idx - 1].equals(el) - }) - } - - public bufArrToHexArr(arr: Array): Array { - if (arr.some((el) => !Buffer.isBuffer(el))) { - throw new Error('Array is not an array of buffers') - } - - return arr.map((el) => '0x' + el.toString('hex')) - } - - public sortAndConcat(...args: Array): Buffer { - return Buffer.concat([...args].sort(Buffer.compare)) - } -} diff --git a/tools/metadata/index.ts b/tools/utils/src/metadata.ts similarity index 94% rename from tools/metadata/index.ts rename to tools/utils/src/metadata.ts index d6632d2d1..18e574eda 100644 --- a/tools/metadata/index.ts +++ b/tools/utils/src/metadata.ts @@ -5,15 +5,36 @@ import { CollectionTokenMetadata, CollectionTokenAttribute, TokenKinds, + ChainIds, chainCurrencies, chainNames, stakingTokenAddresses, } from '@airswap/utils' import tokenlists from './tokenlists' -import defaults from './defaults' import wethDeploys from '@airswap/wrapper/deploys-weth.js' import validUrl from 'valid-url' +const TEST_TOKEN_DECIMALS = 6 + +// Test tokens for Sepolia + +const defaults = [ + { + address: '0x20aaebad8c7c6ffb6fdaa5a622c399561562beea', + chainId: ChainIds.SEPOLIA, + decimals: TEST_TOKEN_DECIMALS, + name: 'Mintable USDT', + symbol: 'USDT', + }, + { + address: '0xf450ef4f268eaf2d3d8f9ed0354852e255a5eaef', + chainId: ChainIds.SEPOLIA, + decimals: TEST_TOKEN_DECIMALS, + name: 'Mintable USDC', + symbol: 'USDC', + }, +] as TokenInfo[] + const AIRSWAP_LOGO_URI = 'https://storage.googleapis.com/subgraph-images/158680119781426823563.png' const AIRSWAP_SYMBOL = 'AST' diff --git a/tools/utils/src/Pricing.ts b/tools/utils/src/pricing.ts similarity index 100% rename from tools/utils/src/Pricing.ts rename to tools/utils/src/pricing.ts diff --git a/tools/utils/src/Server.ts b/tools/utils/src/server.ts similarity index 100% rename from tools/utils/src/Server.ts rename to tools/utils/src/server.ts diff --git a/tools/utils/src/SwapERC20.ts b/tools/utils/src/swap-erc20.ts similarity index 100% rename from tools/utils/src/SwapERC20.ts rename to tools/utils/src/swap-erc20.ts diff --git a/tools/utils/src/Swap.ts b/tools/utils/src/swap.ts similarity index 100% rename from tools/utils/src/Swap.ts rename to tools/utils/src/swap.ts diff --git a/tools/metadata/tokenlists.ts b/tools/utils/src/tokenlists.ts similarity index 100% rename from tools/metadata/tokenlists.ts rename to tools/utils/src/tokenlists.ts diff --git a/tools/metadata/test/metadata.ts b/tools/utils/test/metadata.ts similarity index 86% rename from tools/metadata/test/metadata.ts rename to tools/utils/test/metadata.ts index 8a2c1c5b3..b6d3e9f8a 100644 --- a/tools/metadata/test/metadata.ts +++ b/tools/utils/test/metadata.ts @@ -1,6 +1,10 @@ import { expect } from 'chai' -import { getKnownTokens, findTokenByAddress } from '../index' -import { ChainIds, ADDRESS_ZERO } from '@airswap/utils' +import { + ADDRESS_ZERO, + ChainIds, + getKnownTokens, + findTokenByAddress, +} from '../index' describe('Metadata: Ethereum', async () => { let result: any diff --git a/tools/utils/test/utils.ts b/tools/utils/test/utils.ts index 700fa6447..3c4bc63e7 100644 --- a/tools/utils/test/utils.ts +++ b/tools/utils/test/utils.ts @@ -1,13 +1,6 @@ import { assert, expect } from 'chai' import { ethers } from 'ethers' -import { Levels, FullOrderERC20, UnsignedOrderERC20 } from '@airswap/utils' - -import { soliditySha3 } from 'web3-utils' -import { - generateMerkleTreeFromData, - getMerkleRoot, - getMerkleProof, -} from '../index' +import { Levels, FullOrderERC20, UnsignedOrderERC20 } from '../index' import { ADDRESS_ZERO, @@ -228,27 +221,3 @@ describe('Utils', async () => { }) }) }) - -describe('Merkle', async () => { - let tree: any - const treeRoot = - '0xad519504d6845f9f2529e80a2247d751af56af868ed9f23398705a1ec1bd9fc4' - const proof = [ - '0xc361555652533965d9a3cda90060cb77c14bbaec689e062a4ca8ce8976836719', - '0xe2ad42ca8c17510e58dca1ba6f472caafa90b9fee56f679b0e000881096562f6', - ] - - it('Creates and validates tree', async () => { - tree = generateMerkleTreeFromData({ - a: '1', - b: '2', - c: '3', - }) - expect(getMerkleRoot(tree)).to.equal(treeRoot) - }) - - it('Validates proof', async () => { - const element: any = soliditySha3('a', '1') - expect(getMerkleProof(tree, element).join()).to.equal(proof.join()) - }) -}) diff --git a/yarn.lock b/yarn.lock index 6de59e506..bfa7bdc43 100644 --- a/yarn.lock +++ b/yarn.lock @@ -9,6 +9,15 @@ dependencies: get-parameter-names "^0.3.0" +"@airswap/merkle@0.0.2": + version "0.0.2" + resolved "https://registry.yarnpkg.com/@airswap/merkle/-/merkle-0.0.2.tgz#030f3c2c0a4b2b543be2970e01a41747356409b6" + integrity sha512-d/ES0wgl9MEFE+3TPqoR3JluM8MHLH7QZzgtpm7c2pT6kzdP/KJoybVxoChxCfuftbnbIn0afcj+Km0JAFREGA== + dependencies: + "@types/ethereumjs-util" "^6.1.0" + ethereumjs-util "^7.0.7" + web3-utils "^1.3.1" + "@babel/code-frame@^7.0.0": version "7.21.4" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.21.4.tgz#d0fa9e4413aca81f2b23b9442797bda1826edb39" @@ -228,6 +237,15 @@ "@ethereumjs/rlp" "^4.0.1" ethereum-cryptography "^1.1.2" +"@ethereumjs/util@^8.1.0": + version "8.1.0" + resolved "https://registry.yarnpkg.com/@ethereumjs/util/-/util-8.1.0.tgz#299df97fb6b034e0577ce9f94c7d9d1004409ed4" + integrity sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA== + dependencies: + "@ethereumjs/rlp" "^4.0.1" + ethereum-cryptography "^2.0.0" + micro-ftch "^0.3.1" + "@ethereumjs/vm@5.6.0": version "5.6.0" resolved "https://registry.yarnpkg.com/@ethereumjs/vm/-/vm-5.6.0.tgz#e0ca62af07de820143674c30b776b86c1983a464" @@ -832,11 +850,23 @@ lodash "^4.17.16" uuid "^7.0.3" +"@noble/curves@1.3.0", "@noble/curves@~1.3.0": + version "1.3.0" + resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.3.0.tgz#01be46da4fd195822dab821e72f71bf4aeec635e" + integrity sha512-t01iSXPuN+Eqzb4eBX0S5oubSqXbK/xXa1Ne18Hj8f9pStxztHCE2gfboSp/dZRLSqfuLpRK2nDXDK+W9puocA== + dependencies: + "@noble/hashes" "1.3.3" + "@noble/hashes@1.2.0", "@noble/hashes@~1.2.0": version "1.2.0" resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.2.0.tgz#a3150eeb09cc7ab207ebf6d7b9ad311a9bdbed12" integrity sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ== +"@noble/hashes@1.3.3", "@noble/hashes@~1.3.2": + version "1.3.3" + resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.3.tgz#39908da56a4adc270147bb07968bf3b16cfe1699" + integrity sha512-V7/fPHgl+jsVPXqqeOzT8egNj2iBIVt+ECeMMG8TdcnTikP3oaBtUVqpT/gYCR68aEBJSF+XbYUxStjbFMqIIA== + "@noble/secp256k1@1.7.1", "@noble/secp256k1@~1.7.0": version "1.7.1" resolved "https://registry.yarnpkg.com/@noble/secp256k1/-/secp256k1-1.7.1.tgz#b251c70f824ce3ca7f8dc3df08d58f005cc0507c" @@ -1190,12 +1220,13 @@ nx "16.9.0" tslib "^2.3.0" -"@nrwl/tao@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nrwl/tao/-/tao-16.5.5.tgz#8279e0ebf1ccfb5bb615b9bb63000e36a7255725" - integrity sha512-6SYG3rlKkYvy/wauPwoUXQuN0PTJi95hCEC7lGfCEGye2Y/61UwJQf2xixMxafUM2X84WdEStEz3Jty85gVqkQ== +"@nrwl/tao@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nrwl/tao/-/tao-16.10.0.tgz#94642a0380709b8e387e1e33705a5a9624933375" + integrity sha512-QNAanpINbr+Pod6e1xNgFbzK1x5wmZl+jMocgiEFXZ67KHvmbD6MAQQr0MMz+GPhIu7EE4QCTLTyCEMlAG+K5Q== dependencies: - nx "16.5.5" + nx "16.10.0" + tslib "^2.3.0" "@nx/devkit@16.9.0", "@nx/devkit@>=16.5.1 < 17": version "16.9.0" @@ -1210,100 +1241,100 @@ tmp "~0.2.1" tslib "^2.3.0" -"@nx/nx-darwin-arm64@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-darwin-arm64/-/nx-darwin-arm64-16.5.5.tgz#e8e9a0552954f8333912383da4dea99ba7fee8c3" - integrity sha512-Zzwy7pkSDFTiWcBk78qDe4VzygO9kemtz/kbbLvpisZkUlZX9nIQnLHT80Ms++iqA0enIQAwdTcJiaIHLVd5JQ== +"@nx/nx-darwin-arm64@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-darwin-arm64/-/nx-darwin-arm64-16.10.0.tgz#0c73010cac7a502549483b12bad347da9014e6f1" + integrity sha512-YF+MIpeuwFkyvM5OwgY/rTNRpgVAI/YiR0yTYCZR+X3AAvP775IVlusNgQ3oedTBRUzyRnI4Tknj1WniENFsvQ== "@nx/nx-darwin-arm64@16.9.0": version "16.9.0" resolved "https://registry.yarnpkg.com/@nx/nx-darwin-arm64/-/nx-darwin-arm64-16.9.0.tgz#26fc149f14c867d130dd06dea8cf89f8ff4e754b" integrity sha512-I+045kSIQgdHMfqpJ/bplWzTc82DM/c7VOM/XlrBUwaM9nsDchIC2mo1F93HDe/oJ+oxz9awHbED4GUzS6uc5g== -"@nx/nx-darwin-x64@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-darwin-x64/-/nx-darwin-x64-16.5.5.tgz#0c3c299228920f3f2dd6fd78d03cd301ba8401c5" - integrity sha512-d5O8BD5HFI2hJnMgVVV1pl2A+hlUmn4GxCZTmx2Tr329TYGdpvyXm8NnDFEAigZ77QVMHwFN6vqS07HARu+uVA== +"@nx/nx-darwin-x64@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-darwin-x64/-/nx-darwin-x64-16.10.0.tgz#2ccf270418d552fd0a8e0d6089aee4944315adaa" + integrity sha512-ypi6YxwXgb0kg2ixKXE3pwf5myVNUgWf1CsV5OzVccCM8NzheMO51KDXTDmEpXdzUsfT0AkO1sk5GZeCjhVONg== "@nx/nx-darwin-x64@16.9.0": version "16.9.0" resolved "https://registry.yarnpkg.com/@nx/nx-darwin-x64/-/nx-darwin-x64-16.9.0.tgz#806fb83384fa01a7ebe8993a53d2b2dfe3e6a87e" integrity sha512-Yop/nZlJ+j4RIDB5bfuse583lWLiHtyL7bRPj2IsXAWiQHvXfrNnJJwYH7cGHgtR4ctSAZdOi7SZWlmgHO7Hyw== -"@nx/nx-freebsd-x64@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-freebsd-x64/-/nx-freebsd-x64-16.5.5.tgz#e30781a315ebea5b6aecb12f8c3c7685ddc55ab7" - integrity sha512-SqTvbz21iUc8DHKgisX9pPuXc7/DngbiZxInlEHPXi8zUtyUOqZI3yQk4NVj3dqLBMLwEOZDgvXs0XxzB5nn+g== +"@nx/nx-freebsd-x64@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-freebsd-x64/-/nx-freebsd-x64-16.10.0.tgz#c3ee6914256e69493fed9355b0d6661d0e86da44" + integrity sha512-UeEYFDmdbbDkTQamqvtU8ibgu5jQLgFF1ruNb/U4Ywvwutw2d4ruOMl2e0u9hiNja9NFFAnDbvzrDcMo7jYqYw== "@nx/nx-freebsd-x64@16.9.0": version "16.9.0" resolved "https://registry.yarnpkg.com/@nx/nx-freebsd-x64/-/nx-freebsd-x64-16.9.0.tgz#2865cd20e309c21880def9b05a6c66af834c53e3" integrity sha512-qDg7Sd4V6edRuqR4Y+eEPec0J0Nf5ebGGGDegKjV7X4OfgagOb7k8o3cAGiKkKXuaAUg1OnqVw5nF7JysAmrLQ== -"@nx/nx-linux-arm-gnueabihf@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm-gnueabihf/-/nx-linux-arm-gnueabihf-16.5.5.tgz#9e10b77a9d91fa5b907186cd8881fc9f0fa2d81d" - integrity sha512-8C2KVFHqcyGViEgUicYo1frEgQARbD+CicIos6A5WRYLaxS+upb9FDblKU0eGYIwDp8oCagVjUjNX8d1WHLX7w== +"@nx/nx-linux-arm-gnueabihf@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm-gnueabihf/-/nx-linux-arm-gnueabihf-16.10.0.tgz#a961eccbb38acb2da7fc125b29d1fead0b39152f" + integrity sha512-WV3XUC2DB6/+bz1sx+d1Ai9q2Cdr+kTZRN50SOkfmZUQyEBaF6DRYpx/a4ahhxH3ktpNfyY8Maa9OEYxGCBkQA== "@nx/nx-linux-arm-gnueabihf@16.9.0": version "16.9.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm-gnueabihf/-/nx-linux-arm-gnueabihf-16.9.0.tgz#819bf24fc493d053711502a3bebe95c7eeae3c80" integrity sha512-eyG4PP5jSyDkO8Hm3zrchjm/coVY2L66/ExalfO8j+FSqwlipFIWwkpQM3Tw2fYrrMZpWXa7VlHj10Eu2xF5pQ== -"@nx/nx-linux-arm64-gnu@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-gnu/-/nx-linux-arm64-gnu-16.5.5.tgz#867ca9057bfc5dabb1b684eceb62b1db318e8fcd" - integrity sha512-AGq4wp3Wn8bE0h2c7/bHj2wQWfp08DYJemwTNLkwLcoJWkUidLOBQePRvLxqPeo42Zmt3GYMi+fi5XtKCmvcjg== +"@nx/nx-linux-arm64-gnu@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-gnu/-/nx-linux-arm64-gnu-16.10.0.tgz#795f20072549d03822b5c4639ef438e473dbb541" + integrity sha512-aWIkOUw995V3ItfpAi5FuxQ+1e9EWLS1cjWM1jmeuo+5WtaKToJn5itgQOkvSlPz+HSLgM3VfXMvOFALNk125g== "@nx/nx-linux-arm64-gnu@16.9.0": version "16.9.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-gnu/-/nx-linux-arm64-gnu-16.9.0.tgz#ee064ab6f7a2fe747844ee73a51c9eac8abf27f2" integrity sha512-oJBf2J1qwfACoSN+Hutb6iq0XvIllRdR+52HUXriCWLe6At4kaDW/p+sBcmtlsdgVY3BRs32rqTgYb8qJ1CJRA== -"@nx/nx-linux-arm64-musl@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-musl/-/nx-linux-arm64-musl-16.5.5.tgz#d02403945cd9b21a11bf54671c42f68ca3feb51b" - integrity sha512-xPTYjDCPnXLPXZThAzugiithZaIHk42rTxussMZA00Cx0iEkh5zohqtC0vGBnaAPNcMv0uyCiWABhL4RRUVp2w== +"@nx/nx-linux-arm64-musl@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-musl/-/nx-linux-arm64-musl-16.10.0.tgz#f2428ee6dbe2b2c326e8973f76c97666def33607" + integrity sha512-uO6Gg+irqpVcCKMcEPIQcTFZ+tDI02AZkqkP7koQAjniLEappd8DnUBSQdcn53T086pHpdc264X/ZEpXFfrKWQ== "@nx/nx-linux-arm64-musl@16.9.0": version "16.9.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-musl/-/nx-linux-arm64-musl-16.9.0.tgz#f2b071ea4ac4e3d31c79cd9d41b214f7e1e8edac" integrity sha512-RxAI0ls5Zy/HyL51PMmbaTX+tbZklgAeMqtQhziyjD/awao/9Jt783IqVPFfKoWTNmDq6/bjOG8obcnQlLKsaw== -"@nx/nx-linux-x64-gnu@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-gnu/-/nx-linux-x64-gnu-16.5.5.tgz#e54b44498212f363b8aeddd4313cb5d1fc840af2" - integrity sha512-Rq55OWD4SObfo4sWpjvaijWg33dm+cOf8e2cO06t2EmLMdOyyVnpNdtpjXh6A9tSi3EU5xPfYiy3I9O6gWOnuw== +"@nx/nx-linux-x64-gnu@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-gnu/-/nx-linux-x64-gnu-16.10.0.tgz#d36c2bcf94d49eaa24e3880ddaf6f1f617de539b" + integrity sha512-134PW/u/arNFAQKpqMJniC7irbChMPz+W+qtyKPAUXE0XFKPa7c1GtlI/wK2dvP9qJDZ6bKf0KtA0U/m2HMUOA== "@nx/nx-linux-x64-gnu@16.9.0": version "16.9.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-gnu/-/nx-linux-x64-gnu-16.9.0.tgz#f3c58d41a8e8ffe5b54414dc5c5a3a5031da530f" integrity sha512-xFaA3lOQn1hZ4mzXdCUe/CCioEjRJ0E18AekD2g0r9mMRVyrxEk0KH71jMQwbbVYzkvG9a2Vjiptp8hjmEejAw== -"@nx/nx-linux-x64-musl@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-musl/-/nx-linux-x64-musl-16.5.5.tgz#4f7d352e385ecd69f25d569547413f46408203a8" - integrity sha512-fnkSPv+VIKmQQOEQxFrGx5DlkHGxeH9Fzme6jwuDwmsvs+8Vv/uUnfcxkDZfJxKK+p27w37q3PQCfZGrFXE1cw== +"@nx/nx-linux-x64-musl@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-musl/-/nx-linux-x64-musl-16.10.0.tgz#78bd2ab97a583b3d4ea3387b67fd7b136907493c" + integrity sha512-q8sINYLdIJxK/iUx9vRk5jWAWb/2O0PAbOJFwv4qkxBv4rLoN7y+otgCZ5v0xfx/zztFgk/oNY4lg5xYjIso2Q== "@nx/nx-linux-x64-musl@16.9.0": version "16.9.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-musl/-/nx-linux-x64-musl-16.9.0.tgz#0c7fdcf459d10dc17d8b489724ab72fe4145b4ca" integrity sha512-8tfqvCajTOH5Tt/NFMNJRePwkoUbGYUK7qHJU2LDAazDUsjvpawdvEM8FkJWsNgIsQBej+zcSYA16+sffjsY2g== -"@nx/nx-win32-arm64-msvc@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-win32-arm64-msvc/-/nx-win32-arm64-msvc-16.5.5.tgz#652da52a3eddb0c716ad0ccb1c288c7dca0ec425" - integrity sha512-9nWm+d+tlbxFMLvTLJqIfpTLDuSVDXfSBCSBampyeoI1mUALvq/6CVvWVBDlNqjmrZsYm0sudNqI4Ss7w3BUCQ== +"@nx/nx-win32-arm64-msvc@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-win32-arm64-msvc/-/nx-win32-arm64-msvc-16.10.0.tgz#ef20ec8d0c83d66e73e20df12d2c788b8f866396" + integrity sha512-moJkL9kcqxUdJSRpG7dET3UeLIciwrfP08mzBQ12ewo8K8FzxU8ZUsTIVVdNrwt01CXOdXoweGfdQLjJ4qTURA== "@nx/nx-win32-arm64-msvc@16.9.0": version "16.9.0" resolved "https://registry.yarnpkg.com/@nx/nx-win32-arm64-msvc/-/nx-win32-arm64-msvc-16.9.0.tgz#0ba710f46ac64028a13288c6a414379fec55e3b3" integrity sha512-tUCu1rg76zHdCmov25K2uHUK2rZBTnzbe58r8Wieytmywijp6vGW53RZzYT86YIvInvPJsH7tULdbZpPW56Ruw== -"@nx/nx-win32-x64-msvc@16.5.5": - version "16.5.5" - resolved "https://registry.yarnpkg.com/@nx/nx-win32-x64-msvc/-/nx-win32-x64-msvc-16.5.5.tgz#86ef12c1180fb7a1c7fdc93f5de31c683818f31a" - integrity sha512-fB8miPr887GIGBDhyT6VX7MWX5aC40izEi+4GGSk38oh5dOUK9TLwjAEW/3vBE01fj5Hjcy0CPN7RA45fh/WUw== +"@nx/nx-win32-x64-msvc@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/nx-win32-x64-msvc/-/nx-win32-x64-msvc-16.10.0.tgz#7410a51d0f8be631eec9552f01b2e5946285927c" + integrity sha512-5iV2NKZnzxJwZZ4DM5JVbRG/nkhAbzEskKaLBB82PmYGKzaDHuMHP1lcPoD/rtYMlowZgNA/RQndfKvPBPwmXA== "@nx/nx-win32-x64-msvc@16.9.0": version "16.9.0" @@ -1503,7 +1534,7 @@ path-browserify "^1.0.0" url "^0.11.0" -"@scure/base@~1.1.0": +"@scure/base@~1.1.0", "@scure/base@~1.1.4": version "1.1.5" resolved "https://registry.yarnpkg.com/@scure/base/-/base-1.1.5.tgz#1d85d17269fe97694b9c592552dd9e5e33552157" integrity sha512-Brj9FiG2W1MRQSTB212YVPRrcbjkv48FoZi/u4l/zds/ieRrqsh7aUf6CLwkAq61oKXr/ZlTzlY66gLIj3TFTQ== @@ -1517,6 +1548,15 @@ "@noble/secp256k1" "~1.7.0" "@scure/base" "~1.1.0" +"@scure/bip32@1.3.3": + version "1.3.3" + resolved "https://registry.yarnpkg.com/@scure/bip32/-/bip32-1.3.3.tgz#a9624991dc8767087c57999a5d79488f48eae6c8" + integrity sha512-LJaN3HwRbfQK0X1xFSi0Q9amqOgzQnnDngIt+ZlsBC3Bm7/nE7K0kwshZHyaru79yIVRv/e1mQAjZyuZG6jOFQ== + dependencies: + "@noble/curves" "~1.3.0" + "@noble/hashes" "~1.3.2" + "@scure/base" "~1.1.4" + "@scure/bip39@1.1.1": version "1.1.1" resolved "https://registry.yarnpkg.com/@scure/bip39/-/bip39-1.1.1.tgz#b54557b2e86214319405db819c4b6a370cf340c5" @@ -1525,6 +1565,14 @@ "@noble/hashes" "~1.2.0" "@scure/base" "~1.1.0" +"@scure/bip39@1.2.2": + version "1.2.2" + resolved "https://registry.yarnpkg.com/@scure/bip39/-/bip39-1.2.2.tgz#f3426813f4ced11a47489cbcf7294aa963966527" + integrity sha512-HYf9TUXG80beW+hGAt3TRM8wU6pQoYur9iNypTROm42dorCGmLnFe3eWjz3gOq6G62H2WRh0FCzAR1PI+29zIA== + dependencies: + "@noble/hashes" "~1.3.2" + "@scure/base" "~1.1.4" + "@sentry/core@5.30.0": version "5.30.0" resolved "https://registry.yarnpkg.com/@sentry/core/-/core-5.30.0.tgz#6b203664f69e75106ee8b5a2fe1d717379b331f3" @@ -1796,6 +1844,13 @@ dependencies: "@types/node" "*" +"@types/ethereumjs-util@^6.1.0": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@types/ethereumjs-util/-/ethereumjs-util-6.1.0.tgz#9dabd7302ec9728a7d99be15f4143977c33cd5ac" + integrity sha512-5N0RJldhKCKwDksdnuNHbEJuwO5pjEdtwdHj/kZLxaS84s5R1NLgYfAuDF/VZ4whYABJJvv+o0O8TXLm+F/Byw== + dependencies: + ethereumjs-util "*" + "@types/form-data@0.0.33": version "0.0.33" resolved "https://registry.yarnpkg.com/@types/form-data/-/form-data-0.0.33.tgz#c9ac85b2a5fd18435b8c85d9ecb50e6d6c893ff8" @@ -3932,11 +3987,6 @@ dotenv@^16.0.1: resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.0.3.tgz#115aec42bac5053db3c456db30cc243a5a836a07" integrity sha512-7GO6HghkA5fYG9TYnNxi14/7K9f5occMlp3zXAuSxn7CKCxt9xbNWG7yF8hTCSUchlfWSe3uLmlPfigevRItzQ== -dotenv@~10.0.0: - version "10.0.0" - resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-10.0.0.tgz#3d4227b8fb95f81096cdd2b66653fb2c7085ba81" - integrity sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q== - dotenv@~16.3.1: version "16.3.1" resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.3.1.tgz#369034de7d7e5b120972693352a3bf112172cc3e" @@ -4412,6 +4462,16 @@ ethereum-cryptography@^1.0.3, ethereum-cryptography@^1.1.2: "@scure/bip32" "1.1.5" "@scure/bip39" "1.1.1" +ethereum-cryptography@^2.0.0, ethereum-cryptography@^2.1.2: + version "2.1.3" + resolved "https://registry.yarnpkg.com/ethereum-cryptography/-/ethereum-cryptography-2.1.3.tgz#1352270ed3b339fe25af5ceeadcf1b9c8e30768a" + integrity sha512-BlwbIL7/P45W8FGW2r7LGuvoEZ+7PWsniMvQ4p5s2xCyw9tmaDlpfsN9HjAucbF+t/qpVHwZUisgfK24TCW8aA== + dependencies: + "@noble/curves" "1.3.0" + "@noble/hashes" "1.3.3" + "@scure/bip32" "1.3.3" + "@scure/bip39" "1.2.2" + ethereum-waffle@^4.0.10: version "4.0.10" resolved "https://registry.yarnpkg.com/ethereum-waffle/-/ethereum-waffle-4.0.10.tgz#f1ef1564c0155236f1a66c6eae362a5d67c9f64c" @@ -4432,6 +4492,17 @@ ethereumjs-abi@0.6.8, ethereumjs-abi@^0.6.8: bn.js "^4.11.8" ethereumjs-util "^6.0.0" +ethereumjs-util@*, ethereumjs-util@^7.0.7, ethereumjs-util@^7.1.0, ethereumjs-util@^7.1.1, ethereumjs-util@^7.1.3, ethereumjs-util@^7.1.4, ethereumjs-util@^7.1.5: + version "7.1.5" + resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-7.1.5.tgz#9ecf04861e4fbbeed7465ece5f23317ad1129181" + integrity sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg== + dependencies: + "@types/bn.js" "^5.1.0" + bn.js "^5.1.2" + create-hash "^1.1.2" + ethereum-cryptography "^0.1.3" + rlp "^2.2.4" + ethereumjs-util@7.1.3: version "7.1.3" resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-7.1.3.tgz#b55d7b64dde3e3e45749e4c41288238edec32d23" @@ -4456,17 +4527,6 @@ ethereumjs-util@^6.0.0, ethereumjs-util@^6.2.1: ethjs-util "0.1.6" rlp "^2.2.3" -ethereumjs-util@^7.1.0, ethereumjs-util@^7.1.1, ethereumjs-util@^7.1.3, ethereumjs-util@^7.1.4, ethereumjs-util@^7.1.5: - version "7.1.5" - resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-7.1.5.tgz#9ecf04861e4fbbeed7465ece5f23317ad1129181" - integrity sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg== - dependencies: - "@types/bn.js" "^5.1.0" - bn.js "^5.1.2" - create-hash "^1.1.2" - ethereum-cryptography "^0.1.3" - rlp "^2.2.4" - ethers@^4.0.40: version "4.0.49" resolved "https://registry.yarnpkg.com/ethers/-/ethers-4.0.49.tgz#0eb0e9161a0c8b4761be547396bbe2fb121a8894" @@ -4681,17 +4741,6 @@ fast-diff@^1.1.2: resolved "https://registry.yarnpkg.com/fast-diff/-/fast-diff-1.2.0.tgz#73ee11982d86caaf7959828d519cfe927fac5f03" integrity sha512-xJuoT5+L99XlZ8twedaRf6Ax2TgQVxvgZOYoPKqZufmJib0tL2tegPBOZb1pVNgIhlqDlA0eO0c3wBvQcmzx4w== -fast-glob@3.2.7: - version "3.2.7" - resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.7.tgz#fd6cb7a2d7e9aa7a7846111e85a196d6b2f766a1" - integrity sha512-rYGMRwip6lUMvYD3BTScMwT1HtAs2d71SMv66Vrxs0IekGZEjhM0pcMfjQPnknBt2zeCwQMEupiN02ZP4DiT1Q== - dependencies: - "@nodelib/fs.stat" "^2.0.2" - "@nodelib/fs.walk" "^1.2.3" - glob-parent "^5.1.2" - merge2 "^1.3.0" - micromatch "^4.0.4" - fast-glob@^3.0.3, fast-glob@^3.2.9: version "3.2.12" resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.12.tgz#7f39ec99c2e6ab030337142da9e0c18f37afae80" @@ -7100,6 +7149,11 @@ methods@~1.1.2: resolved "https://registry.yarnpkg.com/methods/-/methods-1.1.2.tgz#5529a4d67654134edcc5266656835b0f851afcee" integrity sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w== +micro-ftch@^0.3.1: + version "0.3.1" + resolved "https://registry.yarnpkg.com/micro-ftch/-/micro-ftch-0.3.1.tgz#6cb83388de4c1f279a034fb0cf96dfc050853c5f" + integrity sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg== + micromatch@^4.0.4: version "4.0.5" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.5.tgz#bc8999a7cbbf77cdc89f132f6e467051b49090c6" @@ -7811,12 +7865,12 @@ number-to-bn@1.7.0: bn.js "4.11.6" strip-hex-prefix "1.0.0" -nx@16.5.5, nx@^16.5.5: - version "16.5.5" - resolved "https://registry.yarnpkg.com/nx/-/nx-16.5.5.tgz#2b67150b72637647e10562b40a74d1ca62bd07a0" - integrity sha512-DHwoUtkirI52JIlCtRK78UI/Ik/VgCtM6FlkfPnFsy8PVyTYMQ40KoG6aZLHjqj5qxoGG2CUjcsbFjGXYrjDbw== +nx@16.10.0, nx@^16.5.5: + version "16.10.0" + resolved "https://registry.yarnpkg.com/nx/-/nx-16.10.0.tgz#b070461f7de0a3d7988bd78558ea84cda3543ace" + integrity sha512-gZl4iCC0Hx0Qe1VWmO4Bkeul2nttuXdPpfnlcDKSACGu3ZIo+uySqwOF8yBAxSTIf8xe2JRhgzJN1aFkuezEBg== dependencies: - "@nrwl/tao" "16.5.5" + "@nrwl/tao" "16.10.0" "@parcel/watcher" "2.0.4" "@yarnpkg/lockfile" "^1.1.0" "@yarnpkg/parsers" "3.0.0-rc.46" @@ -7825,19 +7879,21 @@ nx@16.5.5, nx@^16.5.5: chalk "^4.1.0" cli-cursor "3.1.0" cli-spinners "2.6.1" - cliui "^7.0.2" - dotenv "~10.0.0" + cliui "^8.0.1" + dotenv "~16.3.1" + dotenv-expand "~10.0.0" enquirer "~2.3.6" - fast-glob "3.2.7" figures "3.2.0" flat "^5.0.2" fs-extra "^11.1.0" glob "7.1.4" ignore "^5.0.4" + jest-diff "^29.4.1" js-yaml "4.1.0" jsonc-parser "3.2.0" lines-and-columns "~2.0.3" minimatch "3.0.5" + node-machine-id "1.1.12" npm-run-path "^4.0.1" open "^8.4.0" semver "7.5.3" @@ -7851,16 +7907,16 @@ nx@16.5.5, nx@^16.5.5: yargs "^17.6.2" yargs-parser "21.1.1" optionalDependencies: - "@nx/nx-darwin-arm64" "16.5.5" - "@nx/nx-darwin-x64" "16.5.5" - "@nx/nx-freebsd-x64" "16.5.5" - "@nx/nx-linux-arm-gnueabihf" "16.5.5" - "@nx/nx-linux-arm64-gnu" "16.5.5" - "@nx/nx-linux-arm64-musl" "16.5.5" - "@nx/nx-linux-x64-gnu" "16.5.5" - "@nx/nx-linux-x64-musl" "16.5.5" - "@nx/nx-win32-arm64-msvc" "16.5.5" - "@nx/nx-win32-x64-msvc" "16.5.5" + "@nx/nx-darwin-arm64" "16.10.0" + "@nx/nx-darwin-x64" "16.10.0" + "@nx/nx-freebsd-x64" "16.10.0" + "@nx/nx-linux-arm-gnueabihf" "16.10.0" + "@nx/nx-linux-arm64-gnu" "16.10.0" + "@nx/nx-linux-arm64-musl" "16.10.0" + "@nx/nx-linux-x64-gnu" "16.10.0" + "@nx/nx-linux-x64-musl" "16.10.0" + "@nx/nx-win32-arm64-msvc" "16.10.0" + "@nx/nx-win32-x64-msvc" "16.10.0" nx@16.9.0, "nx@>=16.5.1 < 17": version "16.9.0" @@ -10384,6 +10440,20 @@ wcwidth@^1.0.0, wcwidth@^1.0.1: dependencies: defaults "^1.0.3" +web3-utils@^1.3.1: + version "1.10.3" + resolved "https://registry.yarnpkg.com/web3-utils/-/web3-utils-1.10.3.tgz#f1db99c82549c7d9f8348f04ffe4e0188b449714" + integrity sha512-OqcUrEE16fDBbGoQtZXWdavsPzbGIDc5v3VrRTZ0XrIpefC/viZ1ZU9bGEemazyS0catk/3rkOOxpzTfY+XsyQ== + dependencies: + "@ethereumjs/util" "^8.1.0" + bn.js "^5.2.1" + ethereum-bloom-filters "^1.0.6" + ethereum-cryptography "^2.1.2" + ethjs-unit "0.1.6" + number-to-bn "1.7.0" + randombytes "^2.1.0" + utf8 "3.0.0" + web3-utils@^1.3.6: version "1.9.0" resolved "https://registry.yarnpkg.com/web3-utils/-/web3-utils-1.9.0.tgz#7c5775a47586cefb4ad488831be8f6627be9283d" From 6ede424741588b8e3fbb8060cc9ee8d343eac4ab Mon Sep 17 00:00:00 2001 From: Smartcontrart <100962328+smartcontrart@users.noreply.github.com> Date: Tue, 30 Jan 2024 07:49:43 -0500 Subject: [PATCH 08/43] Created a toggle to allow and unlock stakes (#1279) * Created a toggle to allow and unlock stakes * Updated from toggleStakeUnlocked to setUnlocked * naming updates; conditional priority --------- Co-authored-by: Don Mosites --- source/staking/contracts/Staking.sol | 14 ++++++++++- .../staking/contracts/interfaces/IStaking.sol | 11 +++++---- source/staking/test/Staking.js | 24 ++++++++++++++++++- 3 files changed, 42 insertions(+), 7 deletions(-) diff --git a/source/staking/contracts/Staking.sol b/source/staking/contracts/Staking.sol index 26f808b66..563bceff8 100644 --- a/source/staking/contracts/Staking.sol +++ b/source/staking/contracts/Staking.sol @@ -45,6 +45,9 @@ contract Staking is IStaking, Ownable { // Mapping of staker to stake mapping(address staker => Stake stake) public stakes; + // Whether stakes are unlocked + bool private unlocked; + /** * @notice Staking constructor * @param _name string Token name for this contract @@ -163,7 +166,7 @@ contract Staking is IStaking, Ownable { */ function available(address _staker) public view override returns (uint256) { Stake storage _selected = stakes[_staker]; - if (block.timestamp >= _selected.finish) { + if (unlocked || block.timestamp >= _selected.finish) { return _selected.balance; } // Calc: (Balance * (Now - Start)) / (Finish - Start) @@ -263,6 +266,15 @@ contract Staking is IStaking, Ownable { emit CancelDurationChange(); } + /** + * @notice Unlock (or re-lock) stakes + * @param _unlocked bool Either locked or unlocked + */ + function setUnlocked(bool _unlocked) external onlyOwner { + unlocked = _unlocked; + emit SetUnlocked(_unlocked); + } + /** * @notice Complete timelocked duration change */ diff --git a/source/staking/contracts/interfaces/IStaking.sol b/source/staking/contracts/interfaces/IStaking.sol index 60aa27a9e..a4308ba21 100644 --- a/source/staking/contracts/interfaces/IStaking.sol +++ b/source/staking/contracts/interfaces/IStaking.sol @@ -22,16 +22,17 @@ interface IStaking { uint256 balance; } - event Transfer(address indexed from, address indexed to, uint256 tokens); + event CancelDurationChange(); + event CompleteDurationChange(uint256 indexed newDuration); event ProposeDelegate(address indexed from, address indexed to); - event SetDelegate(address indexed staker, address indexed delegate); - event UnsetDelegate(address indexed staker, address indexed delegate); + event Transfer(address indexed from, address indexed to, uint256 tokens); event ScheduleDurationChange( uint256 proposedStakeDuration, uint256 indexed unlockTimestamp ); - event CancelDurationChange(); - event CompleteDurationChange(uint256 indexed newDuration); + event SetDelegate(address indexed staker, address indexed delegate); + event SetUnlocked(bool unlock); + event UnsetDelegate(address indexed staker, address indexed delegate); function stake(uint256 amount) external; diff --git a/source/staking/test/Staking.js b/source/staking/test/Staking.js index e26358012..e4344a5a8 100644 --- a/source/staking/test/Staking.js +++ b/source/staking/test/Staking.js @@ -76,7 +76,7 @@ describe('Staking Unit', () => { }) }) - describe('Set stake duration', async () => { + describe('Set stake duration and stakes unlock', async () => { it('non-owner cannot set stake duration', async () => { await staking .connect(deployer) @@ -188,6 +188,12 @@ describe('Staking Unit', () => { staking.connect(deployer).cancelDurationChange() ).to.be.revertedWith('TimelockInactive') }) + + it('Only the admin can set unlock', async () => { + expect(staking.connect(account1).setUnlocked(true)).to.be.revertedWith( + 'Unauthorized' + ) + }) }) describe('Stake', async () => { @@ -475,6 +481,22 @@ describe('Staking Unit', () => { expect(initialUserStake.balance).to.equal(200) expect(currentuserStake.balance).to.equal(190) }) + + it('successful full unstake when unlocked', async () => { + await token.mock.transferFrom.returns(true) + await token.mock.transfer.returns(true) + await staking.connect(account1).stake('100') + + await expect(staking.connect(account1).unstake('100')).to.be.revertedWith( + 'AmountInvalid' + ) + await staking.connect(deployer).setUnlocked(true) + + await staking.connect(account1).unstake('100') + const userStake = await staking.connect(account1).stakes(account1.address) + + expect(userStake.balance).to.equal(0) + }) }) describe('Available to unstake', async () => { From d0d2bd1c6232416c032dbd244dc3d3264d59d3c7 Mon Sep 17 00:00:00 2001 From: don mosites Date: Wed, 31 Jan 2024 16:43:10 +0100 Subject: [PATCH 09/43] @airswap/utils fix: lowercase addresses for getFullSwapERC20 (#1280) --- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 4 ++-- tools/utils/package.json | 2 +- tools/utils/src/swap-erc20.ts | 14 +++++++++++--- tools/utils/test/utils.ts | 8 ++++---- 11 files changed, 25 insertions(+), 17 deletions(-) diff --git a/source/batch-call/package.json b/source/batch-call/package.json index c00bf11dd..08b6d3e8c 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,7 +31,7 @@ "@airswap/swap-erc20": "4.2.0" }, "devDependencies": { - "@airswap/utils": "4.2.3", + "@airswap/utils": "4.2.4", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index 0bc4b9be2..aaa8066b0 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,7 +31,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.3", + "@airswap/utils": "4.2.4", "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, diff --git a/source/registry/package.json b/source/registry/package.json index 70c3644a5..dd3393536 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.3", + "@airswap/utils": "4.2.4", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index 260841f02..677073517 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.3", + "@airswap/utils": "4.2.4", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index c3ead2d96..f2e9ecdf8 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -30,7 +30,7 @@ }, "devDependencies": { "@airswap/staking": "4.0.5", - "@airswap/utils": "4.2.3", + "@airswap/utils": "4.2.4", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index f59f57e22..75a3155c5 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.3", + "@airswap/utils": "4.2.4", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 71d9fbb30..0d4e2f138 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.3", + "@airswap/utils": "4.2.4", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 1f2008357..5d945a0e6 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.4", + "version": "4.2.5", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -33,7 +33,7 @@ "@airswap/staking": "4.0.5", "@airswap/swap": "4.2.0", "@airswap/swap-erc20": "4.2.0", - "@airswap/utils": "4.2.3", + "@airswap/utils": "4.2.4", "@airswap/wrapper": "4.1.5", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", diff --git a/tools/utils/package.json b/tools/utils/package.json index 594ed5d11..604af8353 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.3", + "version": "4.2.4", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", diff --git a/tools/utils/src/swap-erc20.ts b/tools/utils/src/swap-erc20.ts index f11635266..c41783e78 100644 --- a/tools/utils/src/swap-erc20.ts +++ b/tools/utils/src/swap-erc20.ts @@ -339,9 +339,9 @@ const parseTransfer = (log: any) => { parsed = erc20Interface.parseLog(log) if (parsed.name === 'Transfer') { transfer = { - token: log.address, - from: parsed.args[0], - to: parsed.args[1], + token: log.address?.toLowerCase(), + from: parsed.args[0]?.toLowerCase(), + to: parsed.args[1]?.toLowerCase(), amount: ethers.BigNumber.from(parsed.args[2]), } } @@ -360,6 +360,10 @@ export const getFullSwapERC20 = async ( const transfers = [] let transfer: any let length = logs.length + + feeReceiver = feeReceiver.toLowerCase() + signerWallet = signerWallet.toLowerCase() + while (length--) { if ((transfer = parseTransfer(logs[length]))) { transfers.push(transfer) @@ -390,6 +394,10 @@ export const getFullSwapERC20 = async ( } } + if (!signer || !sender) { + throw new Error('getFullSwapERC20: Swap not found') + } + return { nonce: nonce.toString(), signerWallet: signer.from, diff --git a/tools/utils/test/utils.ts b/tools/utils/test/utils.ts index 3c4bc63e7..42b6c77da 100644 --- a/tools/utils/test/utils.ts +++ b/tools/utils/test/utils.ts @@ -201,7 +201,7 @@ describe('Utils', async () => { it('Gets full SwapERC20 from signerWallet and logs', async () => { const nonce = '1' - const signerWallet = '0x51C72848c68a965f66FA7a88855F9f7784502a7F' + const signerWallet = '0x51c72848c68a965f66fa7a88855f9f7784502a7f' const feeReceiver = '0xaD30f7EEBD9Bd5150a256F47DA41d4403033CdF0' const fullSwap = await getFullSwapERC20( nonce, @@ -212,10 +212,10 @@ describe('Utils', async () => { expect(fullSwap).to.deep.equal({ nonce, signerWallet, - signerToken: '0xdAC17F958D2ee523a2206206994597C13D831ec7', + signerToken: '0xdac17f958d2ee523a2206206994597c13d831ec7', signerAmount: '1008438461', - senderWallet: '0x74de5d4FCbf63E00296fd95d33236B9794016631', - senderToken: '0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2', + senderWallet: '0x74de5d4fcbf63e00296fd95d33236b9794016631', + senderToken: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', senderAmount: '461545050000000000', feeAmount: '705906', }) From 3aac524fe415228c0beba5ef68790c6d324ef469 Mon Sep 17 00:00:00 2001 From: don mosites Date: Thu, 1 Feb 2024 15:40:49 +0100 Subject: [PATCH 10/43] add testnet token metadata for bsctestnet, mumbai (#1281) * add testnet token metadata for bsctestnet, mumbai * bump libraries to publish with new utils --- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 4 +-- tools/utils/package.json | 2 +- tools/utils/src/metadata.ts | 31 ++++----------------- tools/utils/src/tokendefaults.ts | 47 ++++++++++++++++++++++++++++++++ 11 files changed, 62 insertions(+), 36 deletions(-) create mode 100644 tools/utils/src/tokendefaults.ts diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 08b6d3e8c..c93c57dff 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,7 +31,7 @@ "@airswap/swap-erc20": "4.2.0" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index aaa8066b0..eccac1d9a 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,7 +31,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, diff --git a/source/registry/package.json b/source/registry/package.json index dd3393536..ba802f320 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index 677073517..37d3552bd 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index f2e9ecdf8..955f18dbd 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -30,7 +30,7 @@ }, "devDependencies": { "@airswap/staking": "4.0.5", - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index 75a3155c5..3a8393db3 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 0d4e2f138..220083790 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 5d945a0e6..f03dcc6ea 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.5", + "version": "4.2.6", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -33,7 +33,7 @@ "@airswap/staking": "4.0.5", "@airswap/swap": "4.2.0", "@airswap/swap-erc20": "4.2.0", - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "@airswap/wrapper": "4.1.5", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", diff --git a/tools/utils/package.json b/tools/utils/package.json index 604af8353..fe2704296 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.4", + "version": "4.2.5", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", diff --git a/tools/utils/src/metadata.ts b/tools/utils/src/metadata.ts index 18e574eda..696895700 100644 --- a/tools/utils/src/metadata.ts +++ b/tools/utils/src/metadata.ts @@ -5,36 +5,15 @@ import { CollectionTokenMetadata, CollectionTokenAttribute, TokenKinds, - ChainIds, chainCurrencies, chainNames, stakingTokenAddresses, } from '@airswap/utils' -import tokenlists from './tokenlists' +import TOKEN_LISTS from './tokenlists' +import TOKEN_DEFAULTS from './tokendefaults' import wethDeploys from '@airswap/wrapper/deploys-weth.js' import validUrl from 'valid-url' -const TEST_TOKEN_DECIMALS = 6 - -// Test tokens for Sepolia - -const defaults = [ - { - address: '0x20aaebad8c7c6ffb6fdaa5a622c399561562beea', - chainId: ChainIds.SEPOLIA, - decimals: TEST_TOKEN_DECIMALS, - name: 'Mintable USDT', - symbol: 'USDT', - }, - { - address: '0xf450ef4f268eaf2d3d8f9ed0354852e255a5eaef', - chainId: ChainIds.SEPOLIA, - decimals: TEST_TOKEN_DECIMALS, - name: 'Mintable USDC', - symbol: 'USDC', - }, -] as TokenInfo[] - const AIRSWAP_LOGO_URI = 'https://storage.googleapis.com/subgraph-images/158680119781426823563.png' const AIRSWAP_SYMBOL = 'AST' @@ -52,14 +31,14 @@ export async function getKnownTokens( const errors: Array = [] let tokens = [] tokens.push( - ...defaults.map((token) => ({ + ...TOKEN_DEFAULTS.map((token) => ({ ...token, address: token.address.toLowerCase(), })) ) - if (tokenlists[chainId]) { + if (TOKEN_LISTS[chainId]) { const promises = await Promise.allSettled( - tokenlists[chainId].map(async (url) => { + TOKEN_LISTS[chainId].map(async (url) => { try { const data = await (await fetch(url)).json() if (data.tokens) { diff --git a/tools/utils/src/tokendefaults.ts b/tools/utils/src/tokendefaults.ts new file mode 100644 index 000000000..378402070 --- /dev/null +++ b/tools/utils/src/tokendefaults.ts @@ -0,0 +1,47 @@ +import { ChainIds, TokenInfo } from '@airswap/utils' +const TEST_TOKEN_DECIMALS = 6 + +export default [ + { + address: '0x20aaebad8c7c6ffb6fdaa5a622c399561562beea', + chainId: ChainIds.SEPOLIA, + decimals: TEST_TOKEN_DECIMALS, + name: 'USDT', + symbol: 'USDT', + }, + { + address: '0xf450ef4f268eaf2d3d8f9ed0354852e255a5eaef', + chainId: ChainIds.SEPOLIA, + decimals: TEST_TOKEN_DECIMALS, + name: 'USDC', + symbol: 'USDC', + }, + { + address: '0xdeca72bda0cdf62d79b46b1585b380c9c6d57d9e', + chainId: ChainIds.BSCTESTNET, + decimals: TEST_TOKEN_DECIMALS, + name: 'USDT', + symbol: 'USDT', + }, + { + address: '0x517d482f686f11b922eed764692f2b42663ce2fa', + chainId: ChainIds.BSCTESTNET, + decimals: TEST_TOKEN_DECIMALS, + name: 'USDC', + symbol: 'USDC', + }, + { + address: '0x517d482f686f11b922eed764692f2b42663ce2fa', + chainId: ChainIds.MUMBAI, + decimals: TEST_TOKEN_DECIMALS, + name: 'USDT', + symbol: 'USDT', + }, + { + address: '0xdeca72bda0cdf62d79b46b1585b380c9c6d57d9e', + chainId: ChainIds.MUMBAI, + decimals: TEST_TOKEN_DECIMALS, + name: 'USDC', + symbol: 'USDC', + }, +] as TokenInfo[] From 795ce0b30808b57da0ee59127982b5743841c4b8 Mon Sep 17 00:00:00 2001 From: don mosites Date: Thu, 1 Feb 2024 20:36:40 +0100 Subject: [PATCH 11/43] add Server.getTags to libraries (#1282) --- scripts/owners-report.js | 2 +- tools/libraries/package.json | 2 +- tools/libraries/src/Server.ts | 10 ++++++++++ tools/libraries/test/Server.test.ts | 10 ++++++++++ 4 files changed, 22 insertions(+), 2 deletions(-) diff --git a/scripts/owners-report.js b/scripts/owners-report.js index d928b29ce..9d66b075d 100644 --- a/scripts/owners-report.js +++ b/scripts/owners-report.js @@ -1,12 +1,12 @@ require('dotenv').config({ path: './.env' }) const { ethers } = require('ethers') const { + ADDRESS_ZERO, mainnets, chainNames, ownerAddresses, apiUrls, } = require('@airswap/utils') -const { ADDRESS_ZERO } = require('@airswap/utils') const contracts = [ ['pool', 'Pool'], diff --git a/tools/libraries/package.json b/tools/libraries/package.json index f03dcc6ea..53ca09090 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.6", + "version": "4.2.7", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", diff --git a/tools/libraries/src/Server.ts b/tools/libraries/src/Server.ts index 34ea779b5..0b07b8404 100644 --- a/tools/libraries/src/Server.ts +++ b/tools/libraries/src/Server.ts @@ -329,6 +329,16 @@ export class Server extends TypedEmitter { } } + public async getTags(token: string): Promise { + try { + return Promise.resolve( + (await this.httpCall('getTags', [token])) as string[] + ) + } catch (err) { + return Promise.reject(err) + } + } + public disconnect(): void { if (this.webSocketClient) { if (this.webSocketClient.state !== WebsocketReadyStates.CLOSED) { diff --git a/tools/libraries/test/Server.test.ts b/tools/libraries/test/Server.test.ts index 5204e4739..2d89f9787 100644 --- a/tools/libraries/test/Server.test.ts +++ b/tools/libraries/test/Server.test.ts @@ -133,6 +133,9 @@ function mockHttpServer(api) { ], } break + case 'getTags': + res = [] + break case 'considerOrderERC20': res = true break @@ -212,6 +215,13 @@ describe('HTTPServer', () => { ) expect(isValidFullOrder(result.orders[0])).to.be.true }) + fancy + .nock('https://' + URL, mockHttpServer) + .it('Server getTags()', async () => { + const server = await Server.at(URL) + const result = await server.getTags(ADDRESS_ZERO) + expect(result).to.have.lengthOf(0) + }) }) const samplePairs = [ From 3b9f1664dffa7d2f4645addd2f6deb91946690c1 Mon Sep 17 00:00:00 2001 From: don mosites Date: Wed, 7 Feb 2024 12:00:18 +0100 Subject: [PATCH 12/43] multi-chain deploy; update helper scripts (#1283) * multi-chain deploy; update helper scripts --- hardhat.config.js | 48 ++++++------- package.json | 1 + scripts/deployer-info.js | 27 +++++++ scripts/drain-deployer.js | 97 ++++++++++++++++++++++++++ source/batch-call/deploys-blocks.js | 19 ++++- source/batch-call/deploys.js | 19 ++++- source/batch-call/package.json | 8 +-- source/batch-call/scripts/deploy.js | 10 ++- source/batch-call/scripts/owner.js | 2 +- source/pool/deploys-blocks.js | 2 +- source/pool/deploys.js | 2 +- source/pool/package.json | 4 +- source/pool/scripts/deploy.js | 16 ++--- source/registry/deploys-blocks.js | 24 +++++-- source/registry/deploys.js | 24 +++++-- source/registry/package.json | 4 +- source/registry/scripts/config.js | 83 +++++++++++++++++++--- source/registry/scripts/deploy.js | 16 ++--- source/staking/deploys-blocks.js | 6 +- source/staking/deploys.js | 6 +- source/staking/package.json | 4 +- source/staking/scripts/deploy.js | 10 ++- source/swap-erc20/deploys-blocks.js | 25 +++++-- source/swap-erc20/deploys.js | 25 +++++-- source/swap-erc20/package.json | 6 +- source/swap-erc20/scripts/deploy.js | 15 ++-- source/swap/deploys-adapters-blocks.js | 19 ++++- source/swap/deploys-adapters.js | 87 +++++++++++++++++++++-- source/swap/deploys-blocks.js | 19 ++++- source/swap/deploys.js | 19 ++++- source/swap/package.json | 4 +- source/swap/scripts/deploy-adapters.js | 16 ++--- source/swap/scripts/deploy.js | 20 ++---- source/wrapper/deploys-blocks-weth.js | 5 +- source/wrapper/deploys-weth.js | 5 +- source/wrapper/package.json | 6 +- tools/libraries/package.json | 16 ++--- tools/utils/package.json | 2 +- tools/utils/src/constants.ts | 39 ++++++----- 39 files changed, 555 insertions(+), 205 deletions(-) create mode 100644 scripts/deployer-info.js create mode 100644 scripts/drain-deployer.js diff --git a/hardhat.config.js b/hardhat.config.js index 2d655ad75..e131bd3c9 100644 --- a/hardhat.config.js +++ b/hardhat.config.js @@ -50,8 +50,8 @@ module.exports = { url: apiUrls[ChainIds.ARBITRUM], accounts: process.env.PRIVATE_KEY ? [process.env.PRIVATE_KEY] : undefined, }, - arbitrumgoerli: { - url: apiUrls[ChainIds.ARBITRUMGOERLI], + arbitrumsepolia: { + url: apiUrls[ChainIds.ARBITRUMSEPOLIA], accounts: process.env.PRIVATE_KEY ? [process.env.PRIVATE_KEY] : undefined, }, rsk: { @@ -70,8 +70,8 @@ module.exports = { url: apiUrls[ChainIds.LINEA], accounts: process.env.PRIVATE_KEY ? [process.env.PRIVATE_KEY] : undefined, }, - basegoerli: { - url: apiUrls[ChainIds.BASEGOERLI], + basesepolia: { + url: apiUrls[ChainIds.BASESEPOLIA], accounts: process.env.PRIVATE_KEY ? [process.env.PRIVATE_KEY] : undefined, }, base: { @@ -133,31 +133,31 @@ module.exports = { bscTestnet: process.env.BSCSCAN_API_KEY, polygon: process.env.POLYGONSCAN_API_KEY, arbitrumOne: process.env.ARBISCAN_API_KEY, - arbitrumGoerli: process.env.ARBISCAN_API_KEY, + arbitrumSepolia: process.env.ARBISCAN_API_KEY, avalanche: process.env.SNOWTRACE_API_KEY, avalancheFujiTestnet: process.env.SNOWTRACE_API_KEY, holesky: process.env.ETHERSCAN_API_KEY, polygonMumbai: process.env.POLYGONSCAN_API_KEY, linea: process.env.LINEASCAN_API_KEY, - lineagoerli: process.env.LINEASCAN_API_KEY, + lineaGoerli: process.env.LINEASCAN_API_KEY, base: process.env.BASESCAN_API_KEY, - basegoerli: process.env.BASESCAN_API_KEY, + baseSepolia: process.env.BASESCAN_API_KEY, rsk: process.env.BLOCKSCOUT_API_KEY, - rsktestnet: process.env.BLOCKSCOUT_API_KEY, + rskTestnet: process.env.BLOCKSCOUT_API_KEY, sepolia: process.env.ETHERSCAN_API_KEY, }, customChains: [ { network: 'rsk', - chainId: 30, + chainId: ChainIds.RSK, urls: { apiURL: explorerApiUrls[ChainIds.RSK], browserURL: explorerUrls[ChainIds.RSK], }, }, { - network: 'rsktestnet', - chainId: 31, + network: 'rskTestnet', + chainId: ChainIds.RSKTESTNET, urls: { apiURL: explorerApiUrls[ChainIds.RSKTESTNET], browserURL: explorerUrls[ChainIds.RSKTESTNET], @@ -165,7 +165,7 @@ module.exports = { }, { network: 'holesky', - chainId: 17000, + chainId: ChainIds.HOLESKY, urls: { apiURL: explorerApiUrls[ChainIds.HOLESKY], browserURL: explorerUrls[ChainIds.HOLESKY], @@ -173,15 +173,15 @@ module.exports = { }, { network: 'linea', - chainId: 59144, + chainId: ChainIds.LINEA, urls: { apiURL: explorerApiUrls[ChainIds.LINEA], browserURL: explorerUrls[ChainIds.LINEA], }, }, { - network: 'lineagoerli', - chainId: 59140, + network: 'lineaGoerli', + chainId: ChainIds.LINEAGOERLI, urls: { apiURL: explorerApiUrls[ChainIds.LINEAGOERLI], browserURL: explorerUrls[ChainIds.LINEAGOERLI], @@ -189,26 +189,26 @@ module.exports = { }, { network: 'base', - chainId: 8453, + chainId: ChainIds.BASE, urls: { apiURL: explorerApiUrls[ChainIds.BASE], browserURL: explorerUrls[ChainIds.BASE], }, }, { - network: 'basegoerli', - chainId: 84531, + network: 'baseSepolia', + chainId: ChainIds.BASESEPOLIA, urls: { - apiURL: explorerApiUrls[ChainIds.BASEGOERLI], - browserURL: explorerUrls[ChainIds.BASEGOERLI], + apiURL: explorerApiUrls[ChainIds.BASESEPOLIA], + browserURL: explorerUrls[ChainIds.BASESEPOLIA], }, }, { - network: 'arbitrumGoerli', - chainId: 421613, + network: 'arbitrumSepolia', + chainId: ChainIds.ARBITRUMSEPOLIA, urls: { - apiURL: explorerApiUrls[ChainIds.ARBITRUMGOERLI], - browserURL: explorerUrls[ChainIds.ARBITRUMGOERLI], + apiURL: explorerApiUrls[ChainIds.ARBITRUMSEPOLIA], + browserURL: explorerUrls[ChainIds.ARBITRUMSEPOLIA], }, }, ], diff --git a/package.json b/package.json index 79680baf4..b2fbcb04a 100644 --- a/package.json +++ b/package.json @@ -18,6 +18,7 @@ "test:ci": "lerna run test:ci", "owners": "node ./scripts/owners-report.js", "receivers": "node ./scripts/receivers-report.js", + "drain": "node ./scripts/drain-deployer.js", "prepare": "husky install", "pretty:check": "prettier --check \"./**/*.sol\" \"./**/*.ts\" \"./**/*.js\" \"./**/*.json\"", "pretty:fix": "prettier --write \"./**/*.sol\" \"./**/*.ts\" \"./**/*.js\" \"./**/*.json\"" diff --git a/scripts/deployer-info.js b/scripts/deployer-info.js new file mode 100644 index 000000000..d9f4bec78 --- /dev/null +++ b/scripts/deployer-info.js @@ -0,0 +1,27 @@ +const { + chainNames, + chainCurrencies, + EVM_NATIVE_TOKEN_DECIMALS, +} = require('@airswap/utils') + +module.exports = { + displayDeployerInfo: async function (deployer) { + const gasPrice = await deployer.getGasPrice() + const chainId = await deployer.getChainId() + const balance = ethers.utils.formatUnits( + (await deployer.getBalance()).toString(), + EVM_NATIVE_TOKEN_DECIMALS + ) + console.log(`\nNetwork: ${chainNames[chainId].toUpperCase()}`) + console.log(`Gas price: ${gasPrice / 10 ** 9} gwei`) + console.log(`\nDeployer: ${deployer.address}`) + console.log(`Balance: ${balance} ${chainCurrencies[chainId]}`) + + console.log( + `\nNext contract address will be:\n${ethers.utils.getContractAddress({ + from: deployer.address, + nonce: await deployer.provider.getTransactionCount(deployer.address), + })}\n` + ) + }, +} diff --git a/scripts/drain-deployer.js b/scripts/drain-deployer.js new file mode 100644 index 000000000..c792f3877 --- /dev/null +++ b/scripts/drain-deployer.js @@ -0,0 +1,97 @@ +require('dotenv').config({ path: './.env' }) +const Confirm = require('prompt-confirm') +const { ethers } = require('ethers') +const { + ChainIds, + chainNames, + chainCurrencies, + apiUrls, + getReceiptUrl, + ADDRESS_ZERO, + EVM_NATIVE_TOKEN_DECIMALS, +} = require('@airswap/utils') + +const CONFIRMATIONS = 2 +const RECIPIENT = '0x0000000000000000000000000000000000000000' + +async function main() { + let chainId + if (process.argv[2] === '--network') { + chainId = ChainIds[process.argv[3].toUpperCase()] + } + + if (!chainId) { + console.log('Value for --network flag is required') + return + } + + const provider = new ethers.providers.JsonRpcProvider(apiUrls[chainId]) + const deployer = new ethers.Wallet(process.env.PRIVATE_KEY, provider) + const gasPrice = await deployer.getGasPrice() + + const balance = await deployer.getBalance() + const balanceFormatted = ethers.utils.formatUnits( + balance.toString(), + EVM_NATIVE_TOKEN_DECIMALS + ) + + if (balance.isZero()) { + console.log( + `\n✘ Balance is already 0 on ${process.argv[3].toUpperCase()}.\n` + ) + process.exit(0) + } + + if (RECIPIENT === ADDRESS_ZERO) { + console.log(`\n✘ RECIPIENT must be set.\n`) + process.exit(0) + } + + const estimation = await provider.estimateGas({ + to: RECIPIENT, + value: 1, + }) + + const cost = estimation.mul(gasPrice) + const costFormatted = ethers.utils.formatUnits( + cost, + EVM_NATIVE_TOKEN_DECIMALS + ) + const value = balance.sub(cost) + + console.log(`\nNetwork: ${chainNames[chainId].toUpperCase()}`) + console.log(`Gas price: ${gasPrice / 10 ** 9} gwei`) + console.log(`\nDeployer: ${deployer.address}`) + console.log(`Balance: ${balanceFormatted} ${chainCurrencies[chainId]}`) + console.log(`Transfer cost: ${costFormatted} ${chainCurrencies[chainId]}`) + console.log( + `Net amount: ${ethers.utils.formatUnits( + value, + EVM_NATIVE_TOKEN_DECIMALS + )} ${chainCurrencies[chainId]}\n` + ) + + if (value.isNegative()) { + console.log(`✘ Not enough balance to perform transfer.\n`) + process.exit(0) + } + + const prompt = new Confirm(`Transfer ${balanceFormatted} to ${RECIPIENT}?`) + if (await prompt.run()) { + const tx = await deployer.sendTransaction({ + to: RECIPIENT, + value, + gasPrice, + }) + console.log('Transferring...', getReceiptUrl(chainId, tx.hash), '\n') + await tx.wait(CONFIRMATIONS) + console.log(`✔ Balance transfer complete.\n`) + } +} + +main() + .then(() => process.exit(0)) + .catch((error) => { + console.error(error) + process.exit(1) + }) diff --git a/source/batch-call/deploys-blocks.js b/source/batch-call/deploys-blocks.js index 3bd4c0c88..4a328737e 100644 --- a/source/batch-call/deploys-blocks.js +++ b/source/batch-call/deploys-blocks.js @@ -1,4 +1,19 @@ module.exports = { - 80001: 45223507, - 11155111: 5163580, + 1: 19169067, + 31: 4777071, + 41: 280846804, + 56: 35875924, + 97: 37478338, + 137: 53161285, + 8453: 10229545, + 17000: 882749, + 42161: 178078680, + 43113: 29753793, + 43114: 41340327, + 59140: 3405398, + 59144: 2075793, + 80001: 45576937, + 84532: 5688630, + 421614: 11923855, + 11155111: 5225773, } diff --git a/source/batch-call/deploys.js b/source/batch-call/deploys.js index 64c0561f8..84f32f959 100644 --- a/source/batch-call/deploys.js +++ b/source/batch-call/deploys.js @@ -1,4 +1,19 @@ module.exports = { - 80001: '0x2f9848b5644833b9A55F14375D5dAFCFa4d0E107', - 11155111: '0x2f9848b5644833b9A55F14375D5dAFCFa4d0E107', + 1: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 31: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 41: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 56: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 97: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 137: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 8453: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 17000: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 42161: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 43113: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 43114: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 59140: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 59144: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 80001: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 84532: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 421614: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', + 11155111: '0xd88cf00477B0Edd2C514e6474Ecfc44222830F58', } diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 08b6d3e8c..1b591ead2 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/batch-call", - "version": "4.2.0", + "version": "4.2.1", "description": "Batch balance, allowance, order validity checks", "license": "MIT", "repository": { @@ -27,11 +27,11 @@ }, "dependencies": { "@openzeppelin/contracts": "^4.8.3", - "@airswap/swap": "4.2.0", - "@airswap/swap-erc20": "4.2.0" + "@airswap/swap": "4.2.1", + "@airswap/swap-erc20": "4.2.1" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/batch-call/scripts/deploy.js b/source/batch-call/scripts/deploy.js index 1d699fd9b..e53a39435 100644 --- a/source/batch-call/scripts/deploy.js +++ b/source/batch-call/scripts/deploy.js @@ -3,27 +3,25 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { ChainIds, chainNames, chainLabels } = require('@airswap/utils') +const { ChainIds, chainLabels } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const batchCallDeploys = require('../deploys.js') const batchCallBlocks = require('../deploys-blocks.js') +const { displayDeployerInfo } = require('../../../scripts/deployer-info') async function main() { await run('compile') + const prettierConfig = await prettier.resolveConfig('../deploys.js') const [deployer] = await ethers.getSigners() - const gasPrice = await deployer.getGasPrice() const chainId = await deployer.getChainId() if (chainId === ChainIds.HARDHAT) { console.log('Value for --network flag is required') return } - console.log(`Deployer: ${deployer.address}`) - console.log(`Network: ${chainNames[chainId].toUpperCase()}`) - console.log(`Gas price: ${gasPrice / 10 ** 9} gwei\n`) + await displayDeployerInfo(deployer) const prompt = new Confirm('Proceed to deploy?') if (await prompt.run()) { - const prettierConfig = await prettier.resolveConfig('../deploys.js') const batchFactory = await ethers.getContractFactory('BatchCall') const batchCallContract = await batchFactory.deploy() console.log( diff --git a/source/batch-call/scripts/owner.js b/source/batch-call/scripts/owner.js index 321e8b271..5dd46c375 100644 --- a/source/batch-call/scripts/owner.js +++ b/source/batch-call/scripts/owner.js @@ -1 +1 @@ -console.log(`\n✘ Balances is not ownable.\n`) +console.log(`\n✘ BatchCall is not ownable.\n`) diff --git a/source/pool/deploys-blocks.js b/source/pool/deploys-blocks.js index 35c35cd64..180c9dc76 100644 --- a/source/pool/deploys-blocks.js +++ b/source/pool/deploys-blocks.js @@ -9,7 +9,7 @@ module.exports = { 97: 34150670, 137: 48645401, 8453: 5180096, - 17000: 731316, + 17000: 890721, 42161: 140046382, 43113: 26720218, 43114: 36367783, diff --git a/source/pool/deploys.js b/source/pool/deploys.js index 14886aef8..a08ef00d6 100644 --- a/source/pool/deploys.js +++ b/source/pool/deploys.js @@ -9,7 +9,7 @@ module.exports = { 97: '0xbbcec987E4C189FCbAB0a2534c77b3ba89229F11', 137: '0xbbcec987E4C189FCbAB0a2534c77b3ba89229F11', 8453: '0xbbcec987E4C189FCbAB0a2534c77b3ba89229F11', - 17000: '0xc0799BA9b7bdBA773F77943a9FD448d188345081', + 17000: '0xbbcec987E4C189FCbAB0a2534c77b3ba89229F11', 42161: '0xbbcec987E4C189FCbAB0a2534c77b3ba89229F11', 43113: '0xbbcec987E4C189FCbAB0a2534c77b3ba89229F11', 43114: '0xbbcec987E4C189FCbAB0a2534c77b3ba89229F11', diff --git a/source/pool/package.json b/source/pool/package.json index aaa8066b0..dc6253aeb 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/pool", - "version": "4.1.4", + "version": "4.2.1", "description": "AirSwap: Withdrawable Token Pool", "license": "MIT", "repository": { @@ -31,7 +31,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, diff --git a/source/pool/scripts/deploy.js b/source/pool/scripts/deploy.js index 81c3b28e9..520e7e6d6 100644 --- a/source/pool/scripts/deploy.js +++ b/source/pool/scripts/deploy.js @@ -3,35 +3,33 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { chainLabels, chainNames, ChainIds } = require('@airswap/utils') +const { chainLabels, ChainIds } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const poolDeploys = require('../deploys.js') const poolBlocks = require('../deploys-blocks.js') +const { displayDeployerInfo } = require('../../../scripts/deployer-info') async function main() { await run('compile') const prettierConfig = await prettier.resolveConfig('../deploys.js') - const [deployer] = await ethers.getSigners() - const gasPrice = await deployer.getGasPrice() const chainId = await deployer.getChainId() if (chainId === ChainIds.HARDHAT) { console.log('Value for --network flag is required') return } - console.log(`Deployer: ${deployer.address}`) - console.log(`Network: ${chainNames[chainId].toUpperCase()}`) - console.log(`Gas price: ${gasPrice / 10 ** 9} gwei\n`) + await displayDeployerInfo(deployer) const scale = 10 const max = 100 + console.log(`scale: ${scale}`) + console.log(`max: ${max}`) + const prompt = new Confirm('Proceed to deploy?') if (await prompt.run()) { const poolFactory = await ethers.getContractFactory('Pool') - const poolContract = await poolFactory.deploy(scale, max, { - gasPrice, - }) + const poolContract = await poolFactory.deploy(scale, max) console.log( 'Deploying...', getReceiptUrl(chainId, poolContract.deployTransaction.hash) diff --git a/source/registry/deploys-blocks.js b/source/registry/deploys-blocks.js index de096cba8..52ac8d44c 100644 --- a/source/registry/deploys-blocks.js +++ b/source/registry/deploys-blocks.js @@ -1,9 +1,19 @@ module.exports = { - 1: 19090182, - 56: 35580028, - 137: 52768712, - 43114: 40856912, - 59144: 1853987, - 80001: 45223040, - 11155111: 5156883, + 1: 19169065, + 31: 4777001, + 41: 280843708, + 56: 35875863, + 97: 37477006, + 137: 53161197, + 8453: 10229520, + 17000: 882690, + 42161: 178078567, + 43113: 29752709, + 43114: 41340311, + 59140: 3403822, + 59144: 2075752, + 80001: 45575065, + 84532: 5687996, + 421614: 11915058, + 11155111: 5225447, } diff --git a/source/registry/deploys.js b/source/registry/deploys.js index 90b99099a..bded5354a 100644 --- a/source/registry/deploys.js +++ b/source/registry/deploys.js @@ -1,9 +1,19 @@ module.exports = { - 1: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', - 56: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', - 137: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', - 43114: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', - 59144: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', - 80001: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', - 11155111: '0x1B5c046cDDbb7C6d809CED37898bc87b81666271', + 1: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 31: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 41: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 56: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 97: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 137: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 8453: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 17000: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 42161: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 43113: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 43114: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 59140: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 59144: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 80001: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 84532: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 421614: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', + 11155111: '0xe30E9c001dEFb5F0B04fD21662454A2427F4257A', } diff --git a/source/registry/package.json b/source/registry/package.json index dd3393536..23fd21fd7 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/registry", - "version": "4.2.0", + "version": "4.2.1", "description": "AirSwap: Server Registry", "license": "MIT", "repository": { @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "prompt-confirm": "^2.0.4" } } diff --git a/source/registry/scripts/config.js b/source/registry/scripts/config.js index ac7734214..e0fa4f6b8 100644 --- a/source/registry/scripts/config.js +++ b/source/registry/scripts/config.js @@ -1,8 +1,4 @@ -const { - ChainIds, - stakingTokenAddresses, - ADDRESS_ZERO, -} = require('@airswap/utils') +const { ChainIds, stakingTokenAddresses } = require('@airswap/utils') const wrappedTokenAddresses = require('@airswap/wrapper/deploys-weth') module.exports = { @@ -11,29 +7,94 @@ module.exports = { stakingCost: '1000000000', supportCost: '1000000', }, + [ChainIds.SEPOLIA]: { + stakingToken: stakingTokenAddresses[ChainIds.SEPOLIA], + stakingCost: '1000000000', + supportCost: '1000000', + }, + [ChainIds.HOLESKY]: { + stakingToken: stakingTokenAddresses[ChainIds.HOLESKY], + stakingCost: '1000000000', + supportCost: '1000000', + }, [ChainIds.BSC]: { stakingToken: wrappedTokenAddresses[ChainIds.BSC], - stakingCost: '100000000000000000', - supportCost: '1000000000000000', + stakingCost: '1000000000000000000', + supportCost: '10000000000000000', + }, + [ChainIds.BSCTESTNET]: { + stakingToken: wrappedTokenAddresses[ChainIds.BSCTESTNET], + stakingCost: '1000000000000000000', + supportCost: '10000000000000000', }, [ChainIds.POLYGON]: { stakingToken: wrappedTokenAddresses[ChainIds.POLYGON], stakingCost: '100000000000000000000', supportCost: '1000000000000000000', }, + [ChainIds.MUMBAI]: { + stakingToken: wrappedTokenAddresses[ChainIds.MUMBAI], + stakingCost: '100000000000000000000', + supportCost: '1000000000000000000', + }, [ChainIds.AVALANCHE]: { stakingToken: wrappedTokenAddresses[ChainIds.AVALANCHE], stakingCost: '1000000000000000000', supportCost: '10000000000000000', }, + [ChainIds.FUJI]: { + stakingToken: wrappedTokenAddresses[ChainIds.FUJI], + stakingCost: '1000000000000000000', + supportCost: '10000000000000000', + }, [ChainIds.LINEA]: { stakingToken: wrappedTokenAddresses[ChainIds.LINEA], stakingCost: '50000000000000000', supportCost: '500000000000000', }, - [ChainIds.MUMBAI]: { - stakingToken: ADDRESS_ZERO, - stakingCost: '0', - supportCost: '0', + [ChainIds.LINEAGOERLI]: { + stakingToken: wrappedTokenAddresses[ChainIds.LINEAGOERLI], + stakingCost: '50000000000000000', + supportCost: '500000000000000', + }, + [ChainIds.ARBITRUM]: { + stakingToken: wrappedTokenAddresses[ChainIds.ARBITRUM], + stakingCost: '50000000000000000', + supportCost: '500000000000000', + }, + [ChainIds.ARBITRUMSEPOLIA]: { + stakingToken: wrappedTokenAddresses[ChainIds.ARBITRUMSEPOLIA], + stakingCost: '50000000000000000', + supportCost: '500000000000000', + }, + [ChainIds.BASE]: { + stakingToken: wrappedTokenAddresses[ChainIds.BASE], + stakingCost: '50000000000000000', + supportCost: '500000000000000', + }, + [ChainIds.BASESEPOLIA]: { + stakingToken: wrappedTokenAddresses[ChainIds.BASESEPOLIA], + stakingCost: '50000000000000000', + supportCost: '500000000000000', + }, + [ChainIds.RSK]: { + stakingToken: wrappedTokenAddresses[ChainIds.RSK], + stakingCost: '5000000000000000', + supportCost: '50000000000000', + }, + [ChainIds.RSKTESTNET]: { + stakingToken: wrappedTokenAddresses[ChainIds.RSKTESTNET], + stakingCost: '5000000000000000', + supportCost: '50000000000000', + }, + [ChainIds.TELOS]: { + stakingToken: wrappedTokenAddresses[ChainIds.TELOS], + stakingCost: '1000000000000000000000', + supportCost: '10000000000000000000', + }, + [ChainIds.TELOSTESTNET]: { + stakingToken: wrappedTokenAddresses[ChainIds.TELOSTESTNET], + stakingCost: '1000000000000000000000', + supportCost: '10000000000000000000', }, } diff --git a/source/registry/scripts/deploy.js b/source/registry/scripts/deploy.js index 3fd842424..7ef092c20 100644 --- a/source/registry/scripts/deploy.js +++ b/source/registry/scripts/deploy.js @@ -3,26 +3,23 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { ChainIds, chainLabels, chainNames } = require('@airswap/utils') +const { ChainIds, chainLabels } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const registryDeploys = require('../deploys.js') const registryBlocks = require('../deploys-blocks.js') const config = require('./config.js') +const { displayDeployerInfo } = require('../../../scripts/deployer-info') async function main() { await run('compile') const prettierConfig = await prettier.resolveConfig('../deploys.js') - const [deployer] = await ethers.getSigners() - const gasPrice = await deployer.getGasPrice() const chainId = await deployer.getChainId() if (chainId === ChainIds.HARDHAT) { console.log('Value for --network flag is required') return } - console.log(`Deployer: ${deployer.address}`) - console.log(`Network: ${chainNames[chainId].toUpperCase()}`) - console.log(`Gas price: ${gasPrice / 10 ** 9} gwei\n`) + await displayDeployerInfo(deployer) let stakingToken let stakingCost @@ -34,7 +31,7 @@ async function main() { ;({ stakingToken, stakingCost, supportCost } = config[ChainIds.MAINNET]) } - console.log(`\nstakingToken: ${stakingToken}`) + console.log(`stakingToken: ${stakingToken}`) console.log(`stakingCost: ${stakingCost}`) console.log(`supportCost: ${supportCost}\n`) @@ -44,10 +41,7 @@ async function main() { const registryContract = await registryFactory.deploy( stakingToken, stakingCost, - supportCost, - { - gasPrice, - } + supportCost ) console.log( 'Deploying...', diff --git a/source/staking/deploys-blocks.js b/source/staking/deploys-blocks.js index 4ba52ba2c..84e813abb 100644 --- a/source/staking/deploys-blocks.js +++ b/source/staking/deploys-blocks.js @@ -1 +1,5 @@ -module.exports = {} +module.exports = { + 1: 19169070, + 17000: 882795, + 11155111: 5225823, +} diff --git a/source/staking/deploys.js b/source/staking/deploys.js index 4ba52ba2c..0dd8bdf01 100644 --- a/source/staking/deploys.js +++ b/source/staking/deploys.js @@ -1 +1,5 @@ -module.exports = {} +module.exports = { + 1: '0x8Bf384296A009723435aD5E8203DA5736b895038', + 17000: '0x8Bf384296A009723435aD5E8203DA5736b895038', + 11155111: '0x8Bf384296A009723435aD5E8203DA5736b895038', +} diff --git a/source/staking/package.json b/source/staking/package.json index 677073517..c3ed84eb6 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/staking", - "version": "4.0.5", + "version": "4.2.1", "description": "AirSwap: Stake Tokens", "license": "MIT", "repository": { @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/scripts/deploy.js b/source/staking/scripts/deploy.js index 895ac2861..60dd798d7 100644 --- a/source/staking/scripts/deploy.js +++ b/source/staking/scripts/deploy.js @@ -3,25 +3,23 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { chainNames, chainLabels, ChainIds } = require('@airswap/utils') +const { chainLabels, ChainIds } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const stakingDeploys = require('../deploys.js') const stakingBlocks = require('../deploys-blocks.js') const config = require('./config.js') +const { displayDeployerInfo } = require('../../../scripts/deployer-info') async function main() { await run('compile') const prettierConfig = await prettier.resolveConfig('../deploys.js') const [deployer] = await ethers.getSigners() - const gasPrice = await deployer.getGasPrice() const chainId = await deployer.getChainId() if (chainId === ChainIds.HARDHAT) { console.log('Value for --network flag is required') return } - console.log(`Deployer: ${deployer.address}`) - console.log(`Network: ${chainNames[chainId].toUpperCase()}`) - console.log(`Gas price: ${gasPrice / 10 ** 9} gwei\n`) + await displayDeployerInfo(deployer) const { name, @@ -31,7 +29,7 @@ async function main() { minDurationChangeDelay, } = config[chainId] - console.log(`\nname: ${name}`) + console.log(`name: ${name}`) console.log(`symbol: ${symbol}`) console.log(`stakingToken: ${stakingToken}`) console.log(`stakingDuration: ${stakingDuration}`) diff --git a/source/swap-erc20/deploys-blocks.js b/source/swap-erc20/deploys-blocks.js index e0886cc62..6f2bbd9da 100644 --- a/source/swap-erc20/deploys-blocks.js +++ b/source/swap-erc20/deploys-blocks.js @@ -1,9 +1,20 @@ module.exports = { - 1: 19090128, - 56: 35580014, - 137: 52768683, - 43114: 40856884, - 59144: 1853953, - 80001: 45222994, - 11155111: 5156848, + 1: 19169050, + 31: 4776706, + 41: 280828324, + 56: 35875262, + 97: 37474882, + 137: 53160880, + 8453: 10229426, + 17000: 882207, + 42161: 178077878, + 43113: 29751054, + 43114: 41340140, + 59140: 3401119, + 59144: 2075514, + 80001: 45572097, + 84532: 5684322, + 421613: 61943880, + 421614: 11892510, + 11155111: 5224921, } diff --git a/source/swap-erc20/deploys.js b/source/swap-erc20/deploys.js index bd675d7c4..f105bcbe8 100644 --- a/source/swap-erc20/deploys.js +++ b/source/swap-erc20/deploys.js @@ -1,9 +1,20 @@ module.exports = { - 1: '0x5daDEFF339e1670B83957dA080c91334323A570f', - 56: '0x5daDEFF339e1670B83957dA080c91334323A570f', - 137: '0x5daDEFF339e1670B83957dA080c91334323A570f', - 43114: '0x5daDEFF339e1670B83957dA080c91334323A570f', - 59144: '0x5daDEFF339e1670B83957dA080c91334323A570f', - 80001: '0x5daDEFF339e1670B83957dA080c91334323A570f', - 11155111: '0x5daDEFF339e1670B83957dA080c91334323A570f', + 1: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 31: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 41: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 56: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 97: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 137: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 8453: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 17000: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 42161: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 43113: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 43114: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 59140: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 59144: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 80001: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 84532: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 421613: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 421614: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 11155111: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index f2e9ecdf8..d632cb5dc 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/swap-erc20", - "version": "4.2.0", + "version": "4.2.1", "description": "AirSwap: Atomic ERC20 Token Swap", "license": "MIT", "repository": { @@ -29,8 +29,8 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/staking": "4.0.5", - "@airswap/utils": "4.2.4", + "@airswap/staking": "4.2.1", + "@airswap/utils": "4.2.5", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap-erc20/scripts/deploy.js b/source/swap-erc20/scripts/deploy.js index e291f51d5..d45dd8977 100644 --- a/source/swap-erc20/scripts/deploy.js +++ b/source/swap-erc20/scripts/deploy.js @@ -7,7 +7,6 @@ const poolDeploys = require('@airswap/pool/deploys.js') const { ChainIds, chainLabels, - chainNames, protocolFeeReceiverAddresses, ADDRESS_ZERO, } = require('@airswap/utils') @@ -15,21 +14,18 @@ const { getReceiptUrl } = require('@airswap/utils') const swapERC20Deploys = require('../deploys.js') const swapERC20Blocks = require('../deploys-blocks.js') const config = require('./config.js') +const { displayDeployerInfo } = require('../../../scripts/deployer-info') async function main() { await run('compile') const prettierConfig = await prettier.resolveConfig('../deploys.js') - const [deployer] = await ethers.getSigners() - const gasPrice = await deployer.getGasPrice() const chainId = await deployer.getChainId() if (chainId === ChainIds.HARDHAT) { console.log('Value for --network flag is required') return } - console.log(`Deployer: ${deployer.address}`) - console.log(`Network: ${chainNames[chainId].toUpperCase()}`) - console.log(`Gas price: ${gasPrice / 10 ** 9} gwei\n`) + await displayDeployerInfo(deployer) let protocolFeeReceiver = poolDeploys[chainId] || ADDRESS_ZERO if (protocolFeeReceiverAddresses[chainId]) { @@ -50,7 +46,7 @@ async function main() { console.log(`protocolFee: ${protocolFee}`) console.log(`protocolFeeLight: ${protocolFeeLight}`) - console.log(`protocolFeeReceiver: ${protocolFeeReceiver}`) + console.log(`protocolFeeReceiver: ${protocolFeeReceiver}\n`) const prompt = new Confirm('Proceed to deploy?') if (await prompt.run()) { @@ -60,10 +56,7 @@ async function main() { protocolFeeLight, protocolFeeReceiver, bonusScale, - bonusMax, - { - gasPrice, - } + bonusMax ) console.log( 'Deploying...', diff --git a/source/swap/deploys-adapters-blocks.js b/source/swap/deploys-adapters-blocks.js index cb8428a0f..ce6defdaa 100644 --- a/source/swap/deploys-adapters-blocks.js +++ b/source/swap/deploys-adapters-blocks.js @@ -1,4 +1,19 @@ module.exports = { - 80001: [45223326, 45223344, 45223347], - 11155111: [5163532, 5163533, 5163534], + 1: [19169054, 19169055, 19169056], + 31: [4776848, 4776849, 4776851], + 41: [280836117, 280836129, 280836141], + 56: [35875660, 35875662, 35875663], + 97: [37476273, 37476274, 37476276], + 137: [53161035, 53161040, 53161044], + 8453: [10229451, 10229453, 10229455], + 17000: [882411, 882412, 882414], + 42161: [178078080, 178078093, 178078121], + 43113: [29752224, 29752226, 29752227], + 43114: [41340186, 41340188, 41340191], + 59140: [3402802, 3402803, 3402804], + 59144: [2075614, 2075616, 2075618], + 80001: [45574090, 45574093, 45574096], + 84532: [5686043, 5686046, 5686049], + 421614: [11903161, 11903171, 11903199], + 11155111: [5225253, 5225254, 5225255], } diff --git a/source/swap/deploys-adapters.js b/source/swap/deploys-adapters.js index 5ae16afc8..d3c85577b 100644 --- a/source/swap/deploys-adapters.js +++ b/source/swap/deploys-adapters.js @@ -1,12 +1,87 @@ module.exports = { + 1: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 31: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 41: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 56: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 97: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 137: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 8453: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 17000: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 42161: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 43113: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 43114: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 59140: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 59144: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], 80001: [ - '0xec06d567cfB5360b422B2EBEB7c6ed0aAD132030', - '0x906052b51a22F34c93c1b91B3473D06521100f8e', - '0x647a06900091DEb81927a80Da8E4e6F4AeA4Dc55', + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 84532: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', + ], + 421614: [ + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', ], 11155111: [ - '0xec06d567cfB5360b422B2EBEB7c6ed0aAD132030', - '0x906052b51a22F34c93c1b91B3473D06521100f8e', - '0x647a06900091DEb81927a80Da8E4e6F4AeA4Dc55', + '0x3c80F5c353026790Ffe9064079898Df356cBf688', + '0xebF37f8Cb2c2e58A8779146EfBB83A6e76Faa038', + '0x779932e8D4fE3E5d211434CB67F372592551A586', ], } diff --git a/source/swap/deploys-blocks.js b/source/swap/deploys-blocks.js index fd99f5416..f39797db2 100644 --- a/source/swap/deploys-blocks.js +++ b/source/swap/deploys-blocks.js @@ -1,4 +1,19 @@ module.exports = { - 80001: 45223424, - 11155111: 5163542, + 1: 19169062, + 31: 4776855, + 41: 280836217, + 56: 35875696, + 97: 37476300, + 137: 53161091, + 8453: 10229493, + 17000: 882419, + 42161: 178078363, + 43113: 29752270, + 43114: 41340277, + 59140: 3402835, + 59144: 2075631, + 80001: 45574111, + 84532: 5686079, + 421614: 11903540, + 11155111: 5225267, } diff --git a/source/swap/deploys.js b/source/swap/deploys.js index 4836ed43e..2b8fdff51 100644 --- a/source/swap/deploys.js +++ b/source/swap/deploys.js @@ -1,4 +1,19 @@ module.exports = { - 80001: '0xbBBAA3810e91a703884746deDb714e47C75524E0', - 11155111: '0xbBBAA3810e91a703884746deDb714e47C75524E0', + 1: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 31: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 41: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 56: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 97: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 137: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 8453: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 17000: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 42161: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 43113: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 43114: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 59140: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 59144: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 80001: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 84532: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 421614: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', + 11155111: '0x01b28Aa66a54c6F2bE5C2eF905A2329270CCa96F', } diff --git a/source/swap/package.json b/source/swap/package.json index 75a3155c5..cca934dcf 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/swap", - "version": "4.2.0", + "version": "4.2.1", "description": "AirSwap: Atomic Token Swap", "license": "MIT", "repository": { @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/swap/scripts/deploy-adapters.js b/source/swap/scripts/deploy-adapters.js index de29cd44f..832f8446b 100644 --- a/source/swap/scripts/deploy-adapters.js +++ b/source/swap/scripts/deploy-adapters.js @@ -3,29 +3,25 @@ const fs = require('fs') const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') -const { chainNames, chainLabels, ChainIds } = require('@airswap/utils') +const { chainLabels, ChainIds } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const adapterDeploys = require('../deploys-adapters.js') const adapterBlocks = require('../deploys-adapters-blocks.js') +const { displayDeployerInfo } = require('../../../scripts/deployer-info') async function main() { await run('compile') const prettierConfig = await prettier.resolveConfig('../deploys.js') - const [deployer] = await ethers.getSigners() - const gasPrice = await deployer.getGasPrice() const chainId = await deployer.getChainId() if (chainId === ChainIds.HARDHAT) { console.log('Value for --network flag is required') return } - console.log(`Deployer: ${deployer.address}`) - console.log(`Network: ${chainNames[chainId].toUpperCase()}`) - console.log(`Gas price: ${gasPrice / 10 ** 9} gwei\n`) + await displayDeployerInfo(deployer) const adapters = ['ERC20Adapter', 'ERC721Adapter', 'ERC1155Adapter'] - - console.log(`\nadapters: ${JSON.stringify(adapters)}`) + console.log(`adapters: ${JSON.stringify(adapters)}`) const prompt = new Confirm('Proceed to deploy?') if (await prompt.run()) { @@ -33,9 +29,7 @@ async function main() { for (let i = 0; i < adapters.length; i++) { const adapterContract = await ( await ethers.getContractFactory(adapters[i]) - ).deploy({ - gasPrice, - }) + ).deploy() console.log( `Deploying ${adapters[i]}...`, getReceiptUrl(chainId, adapterContract.deployTransaction.hash) diff --git a/source/swap/scripts/deploy.js b/source/swap/scripts/deploy.js index 523e2eebe..b081f69ec 100644 --- a/source/swap/scripts/deploy.js +++ b/source/swap/scripts/deploy.js @@ -4,7 +4,6 @@ const prettier = require('prettier') const Confirm = require('prompt-confirm') const { ethers, run } = require('hardhat') const { - chainNames, chainLabels, ChainIds, protocolFeeReceiverAddresses, @@ -16,26 +15,18 @@ const swapDeploys = require('../deploys.js') const swapBlocks = require('../deploys-blocks.js') const adapterDeploys = require('../deploys-adapters.js') const config = require('./config.js') +const { displayDeployerInfo } = require('../../../scripts/deployer-info') async function main() { await run('compile') const prettierConfig = await prettier.resolveConfig('../deploys.js') - const [deployer] = await ethers.getSigners() - const gasPrice = await deployer.getGasPrice() const chainId = await deployer.getChainId() if (chainId === ChainIds.HARDHAT) { console.log('Value for --network flag is required') return } - if (!adapterDeploys[chainId]) { - console.log('Adapters must be deployed first.') - return - } - - console.log(`Deployer: ${deployer.address}`) - console.log(`Network: ${chainNames[chainId].toUpperCase()}`) - console.log(`Gas price: ${gasPrice / 10 ** 9} gwei\n`) + await displayDeployerInfo(deployer) let requiredSenderKind let protocolFee @@ -50,7 +41,7 @@ async function main() { protocolFeeReceiver = protocolFeeReceiverAddresses[chainId] } - console.log(`\nadapters: ${JSON.stringify(adapterDeploys[chainId])}`) + console.log(`adapters: ${JSON.stringify(adapterDeploys[chainId])}`) console.log(`requiredSenderKind: ${requiredSenderKind}`) console.log(`protocolFee: ${protocolFee}`) console.log(`protocolFeeReceiver: ${protocolFeeReceiver}`) @@ -62,10 +53,7 @@ async function main() { adapterDeploys[chainId], requiredSenderKind, protocolFee, - protocolFeeReceiver, - { - gasPrice, - } + protocolFeeReceiver ) console.log( 'Deploying...', diff --git a/source/wrapper/deploys-blocks-weth.js b/source/wrapper/deploys-blocks-weth.js index 4b14a0d22..1a2c24fde 100644 --- a/source/wrapper/deploys-blocks-weth.js +++ b/source/wrapper/deploys-blocks-weth.js @@ -1,6 +1,5 @@ module.exports = { 1: 4719568, - 5: 1036651, 30: 5481929, 31: 3949100, 40: 181142510, @@ -8,6 +7,7 @@ module.exports = { 56: 149268, 97: 1585924, 137: 4931456, + 8453: 0, 17000: 28838, 42161: 55, 43113: 352, @@ -15,6 +15,7 @@ module.exports = { 59140: 75, 59144: 624, 80001: 4119576, - 421613: 1377063, + 84532: 0, + 421614: 646132, 11155111: 3236805, } diff --git a/source/wrapper/deploys-weth.js b/source/wrapper/deploys-weth.js index a235cb63b..5cccdc2cb 100644 --- a/source/wrapper/deploys-weth.js +++ b/source/wrapper/deploys-weth.js @@ -1,6 +1,5 @@ module.exports = { 1: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', - 5: '0xb4fbf271143f4fbf7b91a5ded31805e42b2208d6', 30: '0x967f8799af07df1534d48a95a5c9febe92c53ae0', 31: '0x09b6ca5e4496238a1f176aea6bb607db96c2286e', 40: '0xD102cE6A4dB07D247fcc28F366A623Df0938CA9E', @@ -16,7 +15,7 @@ module.exports = { 59140: '0x2C1b868d6596a18e32E61B901E4060C872647b6C', 59144: '0xe5D7C2a44FfDDf6b295A15c148167daaAf5Cf34f', 80001: '0x9c3C9283D3e44854697Cd22D3Faa240Cfb032889', - 84531: '0x4200000000000000000000000000000000000006', - 421613: '0xee01c0cd76354c383b8c7b4e65ea88d00b06f36f', + 84532: '0x4200000000000000000000000000000000000006', + 421614: '0x0091f4e75a03c11cb9be8e3717219005eb780d89', 11155111: '0x7b79995e5f793a07bc00c21412e50ecae098e7f9', } diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 0d4e2f138..4a144f08f 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/wrapper", - "version": "4.1.5", + "version": "4.2.1", "description": "AirSwap: Wrap and Unwrap Native Tokens", "license": "MIT", "repository": { @@ -28,11 +28,11 @@ "owners": "hardhat run ./scripts/owner.js" }, "dependencies": { - "@airswap/swap-erc20": "4.2.0", + "@airswap/swap-erc20": "4.2.1", "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.4", + "@airswap/utils": "4.2.5", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 5d945a0e6..4d099d2d1 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -26,15 +26,15 @@ "test:ci": "yarn test" }, "dependencies": { - "@airswap/batch-call": "4.2.0", + "@airswap/batch-call": "4.2.1", "@airswap/jsonrpc-client-websocket": "0.0.1", - "@airswap/registry": "4.2.0", - "@airswap/pool": "4.1.4", - "@airswap/staking": "4.0.5", - "@airswap/swap": "4.2.0", - "@airswap/swap-erc20": "4.2.0", - "@airswap/utils": "4.2.4", - "@airswap/wrapper": "4.1.5", + "@airswap/registry": "4.2.1", + "@airswap/pool": "4.2.1", + "@airswap/staking": "4.2.1", + "@airswap/swap": "4.2.1", + "@airswap/swap-erc20": "4.2.1", + "@airswap/utils": "4.2.5", + "@airswap/wrapper": "4.2.1", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", "jayson": "^4.0.0", diff --git a/tools/utils/package.json b/tools/utils/package.json index 604af8353..fe2704296 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.4", + "version": "4.2.5", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", diff --git a/tools/utils/src/constants.ts b/tools/utils/src/constants.ts index ed271ec80..07cf5db36 100644 --- a/tools/utils/src/constants.ts +++ b/tools/utils/src/constants.ts @@ -4,6 +4,7 @@ export const DOMAIN_NAME_SWAP = 'SWAP' export const DOMAIN_VERSION_SWAP = '4.2' export const ADDRESS_ZERO = '0x0000000000000000000000000000000000000000' export const SECONDS_IN_DAY = 86400 +export const EVM_NATIVE_TOKEN_DECIMALS = 18 export enum ChainIds { MAINNET = 1, @@ -23,8 +24,8 @@ export enum ChainIds { LINEAGOERLI = 59140, LINEA = 59144, MUMBAI = 80001, - BASEGOERLI = 84531, - ARBITRUMGOERLI = 421613, + BASESEPOLIA = 84532, + ARBITRUMSEPOLIA = 421614, SEPOLIA = 11155111, } @@ -49,8 +50,8 @@ export const testnets: number[] = [ ChainIds.FUJI, ChainIds.LINEAGOERLI, ChainIds.MUMBAI, - ChainIds.BASEGOERLI, - ChainIds.ARBITRUMGOERLI, + ChainIds.BASESEPOLIA, + ChainIds.ARBITRUMSEPOLIA, ChainIds.SEPOLIA, ] @@ -72,8 +73,8 @@ export const chainLabels: Record = { [ChainIds.LINEAGOERLI]: 'LINEAGOERLI', [ChainIds.LINEA]: 'LINEA', [ChainIds.MUMBAI]: 'MUMBAI', - [ChainIds.BASEGOERLI]: 'BASEGOERLI', - [ChainIds.ARBITRUMGOERLI]: 'ARBITRUMGOERLI', + [ChainIds.BASESEPOLIA]: 'BASESEPOLIA', + [ChainIds.ARBITRUMSEPOLIA]: 'ARBITRUMSEPOLIA', [ChainIds.SEPOLIA]: 'SEPOLIA', } @@ -95,8 +96,8 @@ export const chainNames: Record = { [ChainIds.LINEAGOERLI]: 'Linea Goerli', [ChainIds.LINEA]: 'Linea', [ChainIds.MUMBAI]: 'Mumbai Testnet', - [ChainIds.BASEGOERLI]: 'Base Goerli', - [ChainIds.ARBITRUMGOERLI]: 'Arbitrum Goerli', + [ChainIds.BASESEPOLIA]: 'Base Sepolia', + [ChainIds.ARBITRUMSEPOLIA]: 'Arbitrum Sepolia', [ChainIds.SEPOLIA]: 'Sepolia', } @@ -118,8 +119,8 @@ export const chainCurrencies: Record = { [ChainIds.LINEAGOERLI]: 'ETH', [ChainIds.LINEA]: 'ETH', [ChainIds.MUMBAI]: 'MATIC', - [ChainIds.BASEGOERLI]: 'ETH', - [ChainIds.ARBITRUMGOERLI]: 'AETH', + [ChainIds.BASESEPOLIA]: 'ETH', + [ChainIds.ARBITRUMSEPOLIA]: 'AETH', [ChainIds.SEPOLIA]: 'SepoliaETH', } @@ -140,8 +141,8 @@ export const currencyIcons: Record = { [ChainIds.LINEAGOERLI]: ChainIds.MAINNET, [ChainIds.LINEA]: ChainIds.MAINNET, [ChainIds.MUMBAI]: ChainIds.POLYGON, - [ChainIds.BASEGOERLI]: ChainIds.MAINNET, - [ChainIds.ARBITRUMGOERLI]: ChainIds.MAINNET, + [ChainIds.BASESEPOLIA]: ChainIds.MAINNET, + [ChainIds.ARBITRUMSEPOLIA]: ChainIds.MAINNET, [ChainIds.SEPOLIA]: ChainIds.MAINNET, } @@ -154,7 +155,7 @@ export const apiUrls: Record = { [ChainIds.BSC]: 'https://bsc-dataseed.binance.org', [ChainIds.BSCTESTNET]: 'https://data-seed-prebsc-1-s1.binance.org:8545', [ChainIds.POLYGON]: 'https://polygon-rpc.com', - [ChainIds.BASE]: 'https://mainnet.base.org', + [ChainIds.BASE]: 'https://base.publicnode.com', [ChainIds.HOLESKY]: 'https://ethereum-holesky.publicnode.com', [ChainIds.ARBITRUM]: 'https://arb1.arbitrum.io/rpc', [ChainIds.FUJI]: 'https://api.avax-test.network/ext/bc/C/rpc', @@ -162,8 +163,8 @@ export const apiUrls: Record = { [ChainIds.LINEAGOERLI]: 'https://rpc.goerli.linea.build', [ChainIds.LINEA]: 'https://rpc.linea.build', [ChainIds.MUMBAI]: 'https://rpc-mumbai.maticvigil.com', - [ChainIds.BASEGOERLI]: 'https://goerli.base.org', - [ChainIds.ARBITRUMGOERLI]: 'https://goerli-rollup.arbitrum.io/rpc', + [ChainIds.BASESEPOLIA]: 'https://sepolia.base.org', + [ChainIds.ARBITRUMSEPOLIA]: 'https://sepolia-rollup.arbitrum.io/rpc', [ChainIds.SEPOLIA]: 'https://ethereum-sepolia.publicnode.com', } @@ -184,8 +185,8 @@ export const explorerUrls: Record = { [ChainIds.LINEAGOERLI]: 'https://goerli.lineascan.build', [ChainIds.LINEA]: 'https://lineascan.build', [ChainIds.MUMBAI]: 'https://mumbai.polygonscan.com', - [ChainIds.BASEGOERLI]: 'https://goerli.basescan.org', - [ChainIds.ARBITRUMGOERLI]: 'https://goerli.arbiscan.io', + [ChainIds.BASESEPOLIA]: 'https://sepolia.basescan.org', + [ChainIds.ARBITRUMSEPOLIA]: 'https://sepolia.arbiscan.io', [ChainIds.SEPOLIA]: 'https://sepolia.etherscan.io', } @@ -195,9 +196,9 @@ export const explorerApiUrls: Record = { [ChainIds.HOLESKY]: 'https://api-holesky.etherscan.io/api', [ChainIds.LINEAGOERLI]: 'https://api-testnet.lineascan.build/api', [ChainIds.LINEA]: 'https://api.lineascan.build/api', - [ChainIds.BASEGOERLI]: 'https://api-goerli.basescan.org/api', + [ChainIds.BASESEPOLIA]: 'https://api-sepolia.basescan.org/api', [ChainIds.BASE]: 'https://api.basescan.org/api', - [ChainIds.ARBITRUMGOERLI]: 'https://api-goerli.arbiscan.io/api', + [ChainIds.ARBITRUMSEPOLIA]: 'https://api-sepolia.arbiscan.io/api', } export const stakingTokenAddresses: Record = { From 94309177cbd93d67cdd9b498199055ea909f29f2 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Wed, 7 Feb 2024 12:34:59 +0100 Subject: [PATCH 13/43] bump utils, libraries for npm publishing --- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 4 ++-- tools/utils/package.json | 2 +- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 1b591ead2..05a480eef 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,7 +31,7 @@ "@airswap/swap-erc20": "4.2.1" }, "devDependencies": { - "@airswap/utils": "4.2.5", + "@airswap/utils": "4.2.6", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index dc6253aeb..e9e40c09b 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,7 +31,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.5", + "@airswap/utils": "4.2.6", "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, diff --git a/source/registry/package.json b/source/registry/package.json index 23fd21fd7..bad50d15a 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.5", + "@airswap/utils": "4.2.6", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index c3ed84eb6..fd1e96b12 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.5", + "@airswap/utils": "4.2.6", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index d632cb5dc..867b67235 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -30,7 +30,7 @@ }, "devDependencies": { "@airswap/staking": "4.2.1", - "@airswap/utils": "4.2.5", + "@airswap/utils": "4.2.6", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index cca934dcf..71c2ea77b 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.5", + "@airswap/utils": "4.2.6", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 4a144f08f..9fa94c745 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.5", + "@airswap/utils": "4.2.6", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index bed1d4acd..3d5b15918 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.7", + "version": "4.2.8", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -33,7 +33,7 @@ "@airswap/staking": "4.2.1", "@airswap/swap": "4.2.1", "@airswap/swap-erc20": "4.2.1", - "@airswap/utils": "4.2.5", + "@airswap/utils": "4.2.6", "@airswap/wrapper": "4.2.1", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", diff --git a/tools/utils/package.json b/tools/utils/package.json index fe2704296..c3fa72c69 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.5", + "version": "4.2.6", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", From 356cac89fd288b92aadf88ab82fb76dcee5c2685 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Mon, 12 Feb 2024 16:18:09 +0100 Subject: [PATCH 14/43] indexing stores initial --- tools/stores/LICENSE | 19 ++++ tools/stores/README.md | 42 +++++++++ tools/stores/index.ts | 1 + tools/stores/package.json | 34 +++++++ tools/stores/redis/redis.config.ts | 50 +++++++++++ tools/stores/redis/redis.init.js | 22 +++++ tools/stores/redis/redis.ts | 139 +++++++++++++++++++++++++++++ tools/stores/test/redis.ts | 56 ++++++++++++ tools/stores/tsconfig.json | 6 ++ yarn.lock | 66 ++++++++++++-- 10 files changed, 430 insertions(+), 5 deletions(-) create mode 100644 tools/stores/LICENSE create mode 100644 tools/stores/README.md create mode 100644 tools/stores/index.ts create mode 100644 tools/stores/package.json create mode 100644 tools/stores/redis/redis.config.ts create mode 100644 tools/stores/redis/redis.init.js create mode 100644 tools/stores/redis/redis.ts create mode 100644 tools/stores/test/redis.ts create mode 100644 tools/stores/tsconfig.json diff --git a/tools/stores/LICENSE b/tools/stores/LICENSE new file mode 100644 index 000000000..f963da81e --- /dev/null +++ b/tools/stores/LICENSE @@ -0,0 +1,19 @@ +Copyright 2024 AirSwap + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the "Software"), +to deal in the Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, sublicense, +and/or sell copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. diff --git a/tools/stores/README.md b/tools/stores/README.md new file mode 100644 index 000000000..9a9c87b0f --- /dev/null +++ b/tools/stores/README.md @@ -0,0 +1,42 @@ +# Stores + +Storage for Indexing + +[![Discord](https://img.shields.io/discord/590643190281928738.svg)](https://discord.gg/ecQbV7H) +[![License](https://img.shields.io/badge/License-MIT-blue)](https://opensource.org/licenses/MIT) +![Twitter Follow](https://img.shields.io/twitter/follow/airswap?style=social) + +## Resources + +- About → https://about.airswap.io/ +- Website → https://www.airswap.io/ +- Twitter → https://twitter.com/airswap +- Chat → https://chat.airswap.io/ + +## Usage + +Add the package to your project: + +```console +yarn add @airswap/stores +``` + +```console +docker run -p 6379:6379 --name redis-stack redis/redis-stack:latest +``` + +Import into your application: + +```TypeScript +import { Redis } from '@airswap/stores'; +const store = new Redis(process.env.REDISCLOUD_URL) +``` + +## Commands + +| Command | Description | +| :------------- | :-------------------------------------- | +| `yarn` | Install dependencies | +| `yarn clean` | Delete the contract `build` folder | +| `yarn compile` | Compile all contracts to `build` folder | +| `yarn test` | Run all tests in the `test` folder | diff --git a/tools/stores/index.ts b/tools/stores/index.ts new file mode 100644 index 000000000..15c34c823 --- /dev/null +++ b/tools/stores/index.ts @@ -0,0 +1 @@ +export * from './redis/redis' diff --git a/tools/stores/package.json b/tools/stores/package.json new file mode 100644 index 000000000..0e52ba670 --- /dev/null +++ b/tools/stores/package.json @@ -0,0 +1,34 @@ +{ + "name": "@airswap/stores", + "version": "4.2.0", + "description": "AirSwap: Storage for Indexing", + "repository": { + "type": "git", + "url": "https://github.com/airswap/airswap-protocols" + }, + "keywords": [ + "airswap" + ], + "license": "MIT", + "main": "build/index.js", + "files": [ + "/build" + ], + "scripts": { + "clean": "rm -rf ./build", + "compile": "yarn clean && tsc -b", + "redis:init": "node ./redis/redis.init.js", + "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts", + "test:ci": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/utils.ts" + }, + "dependencies": { + "@airswap/utils": "4.2.6", + "redis": "^4.6.13" + }, + "devDependencies": { + "dotenv": "^16.0.1" + }, + "publishConfig": { + "access": "public" + } +} diff --git a/tools/stores/redis/redis.config.ts b/tools/stores/redis/redis.config.ts new file mode 100644 index 000000000..dea4d484b --- /dev/null +++ b/tools/stores/redis/redis.config.ts @@ -0,0 +1,50 @@ +require('dotenv').config({ path: '../../.env' }) +const { SchemaFieldTypes } = require('redis') + +export default async function reset(client) { + await client.flushAll() + await client.ft.create( + 'index:ordersBySigner', + { + '$.nonce': { + type: SchemaFieldTypes.TEXT, + AS: 'nonce', + }, + '$.expiry': { + type: SchemaFieldTypes.TEXT, + AS: 'expiry', + }, + '$.signer.wallet': { + type: SchemaFieldTypes.TEXT, + AS: 'signerWallet', + }, + '$.signer.token': { + type: SchemaFieldTypes.TEXT, + AS: 'signerToken', + }, + '$.signer.amount': { + type: SchemaFieldTypes.TEXT, + AS: 'signerAmount', + }, + '$.signer.id': { + type: SchemaFieldTypes.TEXT, + AS: 'signerId', + }, + '$.sender.amount': { + type: SchemaFieldTypes.TEXT, + AS: 'senderAmount', + }, + '$.sender.token': { + type: SchemaFieldTypes.TEXT, + AS: 'senderToken', + }, + '$.tags.*': { + type: SchemaFieldTypes.TAG, + AS: 'tags', + }, + }, + { + ON: 'JSON', + } + ) +} diff --git a/tools/stores/redis/redis.init.js b/tools/stores/redis/redis.init.js new file mode 100644 index 000000000..d0ffab265 --- /dev/null +++ b/tools/stores/redis/redis.init.js @@ -0,0 +1,22 @@ +require('dotenv').config({ path: '../../.env' }) + +import reset from './redis.config' + +async function main() { + if (!process.env.REDISCLOUD_URL) { + console.log('process.env.REDISCLOUD_URL must be set.') + process.exit(-1) + } + const client = createClient({ + url: process.env.REDISCLOUD_URL, + }) + try { + await client.connect() + await reset(client) + process.exit(0) + } catch (e) { + console.error(e) + process.exit(1) + } +} +main() diff --git a/tools/stores/redis/redis.ts b/tools/stores/redis/redis.ts new file mode 100644 index 000000000..b3ec6c512 --- /dev/null +++ b/tools/stores/redis/redis.ts @@ -0,0 +1,139 @@ +import { createClient } from 'redis' +import { FullOrder, OrderFilter, Indexes, Direction } from '@airswap/utils' + +function tagsKey(token: string) { + return `tags:${token.toLowerCase()}` +} + +function tokenKey(token: string, id: string) { + return `ordersByToken:${token.toLowerCase()}:${id}` +} + +function signerKey(signer: string, nonce: string) { + return `ordersBySigner:${signer.toLowerCase()}:${nonce}` +} + +function cleanTags(tags: string[]) { + return tags.map((tag) => + tag.replace(/\:/g, '\\:').replace(/\=/g, '\\=').replace(/\|/g, '\\|') + ) +} + +const DEFAULT_READ_LIMIT = 10 +const DEFAULT_TTL = 2592000 // 30 days + +export class Redis { + private client: any + + public constructor(connectionUrl: any) { + this.client = createClient({ + url: connectionUrl, + }) + } + + public async write(order: FullOrder, tags: string[]) { + if (!this.client.isOpen) { + await this.client.connect() + } + + const existing = await this.client.json.get( + tokenKey(order.signer.token, order.signer.id) + ) + + // Delete existing order if found. + if (existing) { + const existingOrder = await this.client.json.get( + signerKey(existing.signerWallet, existing.nonce) + ) + await this.client.json.del( + signerKey(existing.signerWallet, existing.nonce) + ) + await this.client.json.del( + tokenKey(existingOrder.signer.token, existingOrder.signer.id) + ) + } + + // Set order by signer wallet and nonce. + await this.client.json.set( + signerKey(order.signer.wallet, order.nonce), + '$', + { ...order, tags: tags || [] } + ) + await this.client.expire( + signerKey(order.signer.wallet, order.nonce), + DEFAULT_TTL + ) + + // Set unique by signer token and signer id. + await this.client.json.set( + tokenKey(order.signer.token, order.signer.id), + '$', + { nonce: order.nonce, signerWallet: order.signer.wallet.toLowerCase() } + ) + await this.client.expire( + tokenKey(order.signer.token, order.signer.id), + DEFAULT_TTL + ) + + // Add tags to set for the signer token. + if (tags.length) { + await this.client.sAdd(tagsKey(order.signer.token), tags) + } + return true + } + + public async tags(token: string) { + if (!this.client.isOpen) { + await this.client.connect() + } + return (await this.client.sMembers(tagsKey(token))) || [] + } + + public async read( + filter: OrderFilter, + offset = 0, + limit = DEFAULT_READ_LIMIT, + by = Indexes.EXPIRY, + direction = Direction.ASC + ) { + if (!this.client.isOpen) { + await this.client.connect() + } + + const args = [] + if (filter.senderToken) args.push(`@senderToken:${filter.senderToken}`) + if (filter.signerToken) args.push(`@signerToken:${filter.signerToken}`) + if (filter.signerId) args.push(`@signerId:${filter.signerId}`) + if (filter.signerWallet) args.push(`@signerWallet:${filter.signerWallet}`) + if (filter.tags?.length) + args.push(`@tags:{${cleanTags(filter.tags).join('|')}}`) + + const { total, documents } = await this.client.ft.search( + 'index:ordersBySigner', + args.join(' '), + { + LIMIT: { from: offset, size: limit }, + SORTBY: { BY: by, DIRECTION: direction }, + } + ) + return { + documents: documents.map((res: any) => res.value), + offset, + total, + } + } + + public async delete(signerWallet: string, nonce: string) { + if (!this.client.isOpen) { + await this.client.connect() + } + + const order = await this.client.json.get(signerKey(signerWallet, nonce)) + if (order) { + await this.client.json.del(signerKey(order.signer.wallet, order.nonce)) + await this.client.json.del(tokenKey(order.signer.token, order.signer.id)) + return true + } + return false + } +} diff --git a/tools/stores/test/redis.ts b/tools/stores/test/redis.ts new file mode 100644 index 000000000..9e69c58bf --- /dev/null +++ b/tools/stores/test/redis.ts @@ -0,0 +1,56 @@ +import { expect } from 'chai' +import { ethers } from 'ethers' +import { createClient } from 'redis' +import { Redis } from '../redis/redis' +import reset from '../redis/redis.config' +import { createOrder, createOrderSignature, ADDRESS_ZERO } from '@airswap/utils' + +const client = createClient({ + url: process.env.REDISCLOUD_URL, +}) + +const store = new Redis(process.env.REDISCLOUD_URL) +const unsignedOrder = createOrder({}) +const signerPrivateKey = + '0x4934d4ff925f39f91e3729fbce52ef12f25fdf93e014e291350f7d314c1a096b' +const wallet = new ethers.Wallet(signerPrivateKey) +let order + +describe('Redis', async () => { + before(async () => { + await client.connect() + await reset(client) + order = { + chainId: 1, + swapContract: ADDRESS_ZERO, + ...unsignedOrder, + ...(await createOrderSignature( + unsignedOrder, + wallet.privateKey, + ADDRESS_ZERO + )), + } + }) + + after(async () => { + await client.disconnect() + }) + + it('InterfaceIds are correct', async () => { + const tags = ['red', 'blue'] + await store.write(order, tags) + const tokenTags = await store.tags(order.signer.token) + const res = await store.read({ tags }) + expect(tokenTags).to.deep.equal(tags) + expect(res).to.deep.equal({ + documents: [ + { + ...order, + tags, + }, + ], + offset: 0, + total: 1, + }) + }) +}) diff --git a/tools/stores/tsconfig.json b/tools/stores/tsconfig.json new file mode 100644 index 000000000..433db29c9 --- /dev/null +++ b/tools/stores/tsconfig.json @@ -0,0 +1,6 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "outDir": "./build" + } +} diff --git a/yarn.lock b/yarn.lock index bfa7bdc43..8ce99306f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1489,6 +1489,40 @@ resolved "https://registry.yarnpkg.com/@pkgjs/parseargs/-/parseargs-0.11.0.tgz#a77ea742fab25775145434eb1d2328cf5013ac33" integrity sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg== +"@redis/bloom@1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@redis/bloom/-/bloom-1.2.0.tgz#d3fd6d3c0af3ef92f26767b56414a370c7b63b71" + integrity sha512-HG2DFjYKbpNmVXsa0keLHp/3leGJz1mjh09f2RLGGLQZzSHpkmZWuwJbAvo3QcRY8p80m5+ZdXZdYOSBLlp7Cg== + +"@redis/client@1.5.14": + version "1.5.14" + resolved "https://registry.yarnpkg.com/@redis/client/-/client-1.5.14.tgz#1107893464d092f140d77c468b018a6ed306a180" + integrity sha512-YGn0GqsRBFUQxklhY7v562VMOP0DcmlrHHs3IV1mFE3cbxe31IITUkqhBcIhVSI/2JqtWAJXg5mjV4aU+zD0HA== + dependencies: + cluster-key-slot "1.1.2" + generic-pool "3.9.0" + yallist "4.0.0" + +"@redis/graph@1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@redis/graph/-/graph-1.1.1.tgz#8c10df2df7f7d02741866751764031a957a170ea" + integrity sha512-FEMTcTHZozZciLRl6GiiIB4zGm5z5F3F6a6FZCyrfxdKOhFlGkiAqlexWMBzCi4DcRoyiOsuLfW+cjlGWyExOw== + +"@redis/json@1.0.6": + version "1.0.6" + resolved "https://registry.yarnpkg.com/@redis/json/-/json-1.0.6.tgz#b7a7725bbb907765d84c99d55eac3fcf772e180e" + integrity sha512-rcZO3bfQbm2zPRpqo82XbW8zg4G/w4W3tI7X8Mqleq9goQjAGLL7q/1n1ZX4dXEAmORVZ4s1+uKLaUOg7LrUhw== + +"@redis/search@1.1.6": + version "1.1.6" + resolved "https://registry.yarnpkg.com/@redis/search/-/search-1.1.6.tgz#33bcdd791d9ed88ab6910243a355d85a7fedf756" + integrity sha512-mZXCxbTYKBQ3M2lZnEddwEAks0Kc7nauire8q20oA0oA/LoA+E/b5Y5KZn232ztPb1FkIGqo12vh3Lf+Vw5iTw== + +"@redis/time-series@1.0.5": + version "1.0.5" + resolved "https://registry.yarnpkg.com/@redis/time-series/-/time-series-1.0.5.tgz#a6d70ef7a0e71e083ea09b967df0a0ed742bc6ad" + integrity sha512-IFjIgTusQym2B5IZJG3XKr5llka7ey84fw/NOYqESP5WUfQs9zz1ww/9+qoz4ka/S6KcGBodzlCeZ5UImKbscg== + "@relaycorp/ws-mock@^5.2.6": version "5.2.6" resolved "https://registry.yarnpkg.com/@relaycorp/ws-mock/-/ws-mock-5.2.6.tgz#eaabaf22e4c6d607d17c9e0ca65e3c76f7f6f4e1" @@ -3402,6 +3436,11 @@ clone@^1.0.2: resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e" integrity sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg== +cluster-key-slot@1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/cluster-key-slot/-/cluster-key-slot-1.1.2.tgz#88ddaa46906e303b5de30d3153b7d9fe0a0c19ac" + integrity sha512-RMr0FhtfXemyinomL4hrWcYJxmX6deFdCxpJzhDttxgO1+bcCnkk+9drydLVDmAMG7NE6aN/fl4F7ucU/90gAA== + cmd-shim@6.0.1: version "6.0.1" resolved "https://registry.yarnpkg.com/cmd-shim/-/cmd-shim-6.0.1.tgz#a65878080548e1dca760b3aea1e21ed05194da9d" @@ -5113,6 +5152,11 @@ gauge@^4.0.3: strip-ansi "^6.0.1" wide-align "^1.1.5" +generic-pool@3.9.0: + version "3.9.0" + resolved "https://registry.yarnpkg.com/generic-pool/-/generic-pool-3.9.0.tgz#36f4a678e963f4fdb8707eab050823abc4e8f5e4" + integrity sha512-hymDOu5B53XvN4QT9dBmZxPX4CWhBPPLguTZ9MMFeFa/Kg0xWVfylOVNlJji/E7yTZWFd/q9GO5TxDLq156D7g== + get-caller-file@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" @@ -8854,6 +8898,18 @@ redent@^3.0.0: indent-string "^4.0.0" strip-indent "^3.0.0" +redis@^4.6.13: + version "4.6.13" + resolved "https://registry.yarnpkg.com/redis/-/redis-4.6.13.tgz#e247267c5f3ba35ab8277b57343d3a56acb2f0a6" + integrity sha512-MHgkS4B+sPjCXpf+HfdetBwbRz6vCtsceTmw1pHNYJAsYxrfpOP6dz+piJWGos8wqG7qb3vj/Rrc5qOlmInUuA== + dependencies: + "@redis/bloom" "1.2.0" + "@redis/client" "1.5.14" + "@redis/graph" "1.1.1" + "@redis/json" "1.0.6" + "@redis/search" "1.1.6" + "@redis/time-series" "1.0.5" + reduce-flatten@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/reduce-flatten/-/reduce-flatten-2.0.0.tgz#734fd84e65f375d7ca4465c69798c25c9d10ae27" @@ -10696,16 +10752,16 @@ yaeti@^0.0.6: resolved "https://registry.yarnpkg.com/yaeti/-/yaeti-0.0.6.tgz#f26f484d72684cf42bedfb76970aa1608fbf9577" integrity sha512-MvQa//+KcZCUkBTIC9blM+CU9J2GzuTytsOUwf2lidtvkx/6gnEp1QvJv34t9vdjhFmha/mUiNDbN0D0mJWdug== +yallist@4.0.0, yallist@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" + integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== + yallist@^3.0.2: version "3.1.1" resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd" integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g== -yallist@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" - integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== - yargs-parser@13.1.2, yargs-parser@^13.1.2: version "13.1.2" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.2.tgz#130f09702ebaeef2650d54ce6e3e5706f7a4fb38" From 847e713469b497b058d3b16cbc182bdd5bedebb5 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Mon, 12 Feb 2024 16:36:40 +0100 Subject: [PATCH 15/43] add wrappers report to scripts --- .husky/pre-commit | 2 +- package.json | 11 ++++--- scripts/wrappers-report.js | 56 ++++++++++++++++++++++++++++++++++++ tools/libraries/package.json | 4 --- tools/utils/src/constants.ts | 1 - 5 files changed, 62 insertions(+), 12 deletions(-) create mode 100644 scripts/wrappers-report.js diff --git a/.husky/pre-commit b/.husky/pre-commit index ddb0fdc45..7fa5d8f44 100755 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -1,4 +1,4 @@ #!/bin/sh . "$(dirname "$0")/_/husky.sh" -yarn lint:check && yarn pretty:check +yarn linter && yarn prettier diff --git a/package.json b/package.json index b2fbcb04a..b4ffc9e63 100644 --- a/package.json +++ b/package.json @@ -10,18 +10,17 @@ ] }, "scripts": { + "check:owners": "node ./scripts/owners-report.js", + "check:receivers": "node ./scripts/receivers-report.js", + "check:wrappers": "node ./scripts/wrappers-report.js", "clean": "lerna run clean", "compile": "lerna run compile", - "lint:check": "yarn eslint . --ext .js,.ts", - "lint:fix": "yarn eslint . --ext .js,.ts --fix", + "linter": "yarn eslint . --ext .js,.ts --fix", "test": "lerna run test", "test:ci": "lerna run test:ci", - "owners": "node ./scripts/owners-report.js", - "receivers": "node ./scripts/receivers-report.js", "drain": "node ./scripts/drain-deployer.js", "prepare": "husky install", - "pretty:check": "prettier --check \"./**/*.sol\" \"./**/*.ts\" \"./**/*.js\" \"./**/*.json\"", - "pretty:fix": "prettier --write \"./**/*.sol\" \"./**/*.ts\" \"./**/*.js\" \"./**/*.json\"" + "prettier": "prettier --write \"./**/*.sol\" \"./**/*.ts\" \"./**/*.js\" \"./**/*.json\"" }, "devDependencies": { "@ethersproject/abi": "^5.7.0", diff --git a/scripts/wrappers-report.js b/scripts/wrappers-report.js new file mode 100644 index 000000000..84344bca7 --- /dev/null +++ b/scripts/wrappers-report.js @@ -0,0 +1,56 @@ +require('dotenv').config({ path: './.env' }) +const { ethers } = require('ethers') +const { mainnets, testnets, chainNames, apiUrls } = require('@airswap/utils') +const swapERC20Deploys = require('@airswap/swap-erc20/deploys.js') + +const chains = mainnets.concat(testnets) + +async function main() { + console.log() + for (let c = 0; c < chains.length; c++) { + const chainId = chains[c] + const apiUrl = apiUrls[chainId] + const provider = new ethers.providers.JsonRpcProvider(apiUrl) + const deployer = new ethers.Wallet(process.env.PRIVATE_KEY, provider) + + const deploys = require('../source/wrapper/deploys.js') + const { + Wrapper__factory, + } = require('@airswap/wrapper/typechain/factories/contracts') + if (deploys[chainId]) { + const contract = Wrapper__factory.connect(deploys[chainId], deployer) + const currentSwapERC20 = await contract.swapERC20Contract() + + const intendedSwapERC20 = swapERC20Deploys[chainId] + + if (intendedSwapERC20) { + console.log( + chainNames[chainId].toUpperCase(), + `(${chainId})`, + '· Intended SwapERC20: ', + intendedSwapERC20 + ) + + let label = 'Wrapper has correct SwapERC20' + if (currentSwapERC20 !== intendedSwapERC20) { + label = `Wrapper has incorrect SwapERC20: ${currentSwapERC20}` + } + console.log(currentSwapERC20 === intendedSwapERC20 ? '✔' : '✘', label) + } else { + console.log( + chainNames[chainId].toUpperCase(), + `(${chainId})`, + '✘ Not deployed' + ) + } + console.log() + } + } +} + +main() + .then(() => process.exit(0)) + .catch((error) => { + console.error(error) + process.exit(1) + }) diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 3d5b15918..0ccf3691e 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -18,10 +18,6 @@ "scripts": { "clean": "rm -rf ./build", "compile": "yarn clean && tsc -b", - "lint:check": "yarn eslint . --ext .js,.ts", - "lint:fix": "yarn eslint . --ext .js,.ts --fix", - "pretty:check": "prettier --check \"./**/*.ts\" \"./**/*.js\"", - "pretty:fix": "prettier --write \"./**/*.ts\" \"./**/*.js\"", "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts", "test:ci": "yarn test" }, diff --git a/tools/utils/src/constants.ts b/tools/utils/src/constants.ts index 07cf5db36..a80f852ea 100644 --- a/tools/utils/src/constants.ts +++ b/tools/utils/src/constants.ts @@ -46,7 +46,6 @@ export const testnets: number[] = [ ChainIds.TELOSTESTNET, ChainIds.BSCTESTNET, ChainIds.HOLESKY, - ChainIds.HARDHAT, ChainIds.FUJI, ChainIds.LINEAGOERLI, ChainIds.MUMBAI, From 3de0680afad6e0043a58a507fecbc8487ddddad2 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Tue, 13 Feb 2024 13:00:56 +0100 Subject: [PATCH 16/43] tests for redis store; improvements --- tools/stores/package.json | 3 +- tools/stores/redis/redis.ts | 45 ++++++++--- tools/stores/test/redis.ts | 140 ++++++++++++++++++++++++----------- tools/utils/src/constants.ts | 1 + 4 files changed, 135 insertions(+), 54 deletions(-) diff --git a/tools/stores/package.json b/tools/stores/package.json index 0e52ba670..9eb8d2db5 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -18,8 +18,7 @@ "clean": "rm -rf ./build", "compile": "yarn clean && tsc -b", "redis:init": "node ./redis/redis.init.js", - "test": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts", - "test:ci": "TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/utils.ts" + "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { "@airswap/utils": "4.2.6", diff --git a/tools/stores/redis/redis.ts b/tools/stores/redis/redis.ts index b3ec6c512..9b63e8267 100644 --- a/tools/stores/redis/redis.ts +++ b/tools/stores/redis/redis.ts @@ -1,5 +1,12 @@ import { createClient } from 'redis' -import { FullOrder, OrderFilter, Indexes, Direction } from '@airswap/utils' +import { + FullOrder, + OrderFilter, + Indexes, + Direction, + THIRTY_DAYS, +} from '@airswap/utils' +import reset from '../redis/redis.config' function tagsKey(token: string) { return `tags:${token.toLowerCase()}` @@ -19,19 +26,24 @@ function cleanTags(tags: string[]) { ) } -const DEFAULT_READ_LIMIT = 10 -const DEFAULT_TTL = 2592000 // 30 days - export class Redis { private client: any + private ttl: number + private defaultReadLimit: number - public constructor(connectionUrl: any) { + public constructor( + connectionUrl: any, + defaultReadLimit = 10, + ttl = THIRTY_DAYS + ) { this.client = createClient({ url: connectionUrl, }) + this.defaultReadLimit = defaultReadLimit + this.ttl = ttl } - public async write(order: FullOrder, tags: string[]) { + public async write(order: FullOrder, tags: string[] = []) { if (!this.client.isOpen) { await this.client.connect() } @@ -61,7 +73,7 @@ export class Redis { ) await this.client.expire( signerKey(order.signer.wallet, order.nonce), - DEFAULT_TTL + this.ttl ) // Set unique by signer token and signer id. @@ -72,7 +84,7 @@ export class Redis { ) await this.client.expire( tokenKey(order.signer.token, order.signer.id), - DEFAULT_TTL + this.ttl ) // Add tags to set for the signer token. @@ -92,7 +104,7 @@ export class Redis { public async read( filter: OrderFilter, offset = 0, - limit = DEFAULT_READ_LIMIT, + limit = this.defaultReadLimit, by = Indexes.EXPIRY, direction = Direction.ASC ) { @@ -117,7 +129,7 @@ export class Redis { } ) return { - documents: documents.map((res: any) => res.value), + orders: documents.map((res: any) => res.value), offset, total, } @@ -136,4 +148,17 @@ export class Redis { } return false } + + public async reset() { + if (!this.client.isOpen) { + await this.client.connect() + } + await reset(this.client) + } + + public async disconnect() { + if (this.client.isOpen) { + await this.client.disconnect() + } + } } diff --git a/tools/stores/test/redis.ts b/tools/stores/test/redis.ts index 9e69c58bf..8ae0c6ab9 100644 --- a/tools/stores/test/redis.ts +++ b/tools/stores/test/redis.ts @@ -1,56 +1,112 @@ import { expect } from 'chai' -import { ethers } from 'ethers' -import { createClient } from 'redis' import { Redis } from '../redis/redis' -import reset from '../redis/redis.config' -import { createOrder, createOrderSignature, ADDRESS_ZERO } from '@airswap/utils' -const client = createClient({ - url: process.env.REDISCLOUD_URL, -}) +import { + createOrder, + createOrderSignature, + FullOrder, + ADDRESS_ZERO, +} from '@airswap/utils' const store = new Redis(process.env.REDISCLOUD_URL) -const unsignedOrder = createOrder({}) -const signerPrivateKey = - '0x4934d4ff925f39f91e3729fbce52ef12f25fdf93e014e291350f7d314c1a096b' -const wallet = new ethers.Wallet(signerPrivateKey) -let order + +async function createSignedOrder( + id: string, + signerWallet = ADDRESS_ZERO, + signerToken = '0x000000000000000000000000000000000000000A' +): Promise { + const unsignedOrder = createOrder({ + signer: { + wallet: signerWallet, + token: signerToken, + id, + }, + }) + return { + chainId: 1, + swapContract: ADDRESS_ZERO, + ...unsignedOrder, + ...(await createOrderSignature( + unsignedOrder, + '0x4934d4ff925f39f91e3729fbce52ef12f25fdf93e014e291350f7d314c1a096b', + ADDRESS_ZERO + )), + } +} + +const signerOne = '0x0000000000000000000000000000000000000001' +const signerTwo = '0x0000000000000000000000000000000000000002' + +let orderOne +let orderTwo describe('Redis', async () => { before(async () => { - await client.connect() - await reset(client) - order = { - chainId: 1, - swapContract: ADDRESS_ZERO, - ...unsignedOrder, - ...(await createOrderSignature( - unsignedOrder, - wallet.privateKey, - ADDRESS_ZERO - )), - } + await store.reset() + orderOne = await createSignedOrder('1', signerOne) + orderTwo = await createSignedOrder('2', signerTwo) }) after(async () => { - await client.disconnect() - }) - - it('InterfaceIds are correct', async () => { - const tags = ['red', 'blue'] - await store.write(order, tags) - const tokenTags = await store.tags(order.signer.token) - const res = await store.read({ tags }) - expect(tokenTags).to.deep.equal(tags) - expect(res).to.deep.equal({ - documents: [ - { - ...order, - tags, - }, - ], - offset: 0, - total: 1, + await store.disconnect() + }) + + it('Tags are stored', async () => { + await store.write(orderOne, ['grass:green', 'sky:blue']) + await store.write(orderTwo, ['grass:green', 'sky:grey']) + const tokenTags = await store.tags(orderOne.signer.token) + expect(tokenTags).to.deep.equal(['grass:green', 'sky:blue', 'sky:grey']) + }) + + it('Query by signer token', async () => { + await store.write(orderOne) + await store.write(orderTwo) + const res = await store.read({ + signerToken: orderOne.signer.token, }) + expect(res.total).to.equal(2) + expect(res.orders[0].signer.id).to.equal('1') + }) + + it('Query by signer wallet', async () => { + await store.write(orderOne) + await store.write(orderTwo) + const res = await store.read({ + signerWallet: orderOne.signer.wallet, + }) + expect(res.total).to.equal(1) + expect(res.orders[0].signer.id).to.equal('1') + }) + + it('Query by tag', async () => { + await store.write(orderOne, ['Grass|Green', 'Sun:Bright Yellow']) + await store.write(orderTwo, ['Grass|Green', 'Sun=Deep Orange']) + const res = await store.read({ + signerToken: orderOne.signer.token, + tags: ['Sun:Bright Yellow'], + }) + expect(res.total).to.equal(1) + expect(res.orders[0].signer.id).to.equal('1') + }) + + it('Query with pagination', async () => { + const OFFSET = 5 + const LIMIT = 30 + const TOTAL = 125 + for (let i = 0; i < TOTAL; i++) { + const order = await createSignedOrder(String(i), signerOne) + await store.write(order) + } + const res = await store.read( + { + signerToken: orderOne.signer.token, + }, + OFFSET, + LIMIT + ) + expect(res.total).to.equal(TOTAL) + expect(res.offset).to.equal(OFFSET) + expect(res.orders.length).to.equal(LIMIT) + expect(res.orders[0].signer.id).to.equal(String(OFFSET)) }) }) diff --git a/tools/utils/src/constants.ts b/tools/utils/src/constants.ts index 07cf5db36..6587ca17a 100644 --- a/tools/utils/src/constants.ts +++ b/tools/utils/src/constants.ts @@ -4,6 +4,7 @@ export const DOMAIN_NAME_SWAP = 'SWAP' export const DOMAIN_VERSION_SWAP = '4.2' export const ADDRESS_ZERO = '0x0000000000000000000000000000000000000000' export const SECONDS_IN_DAY = 86400 +export const THIRTY_DAYS = 86400 * 30 export const EVM_NATIVE_TOKEN_DECIMALS = 18 export enum ChainIds { From 988e0886be5c8c87a76d43cb995464cabacc0ccf Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Tue, 13 Feb 2024 13:03:20 +0100 Subject: [PATCH 17/43] update README --- tools/stores/README.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/tools/stores/README.md b/tools/stores/README.md index 9a9c87b0f..f950c5294 100644 --- a/tools/stores/README.md +++ b/tools/stores/README.md @@ -21,10 +21,6 @@ Add the package to your project: yarn add @airswap/stores ``` -```console -docker run -p 6379:6379 --name redis-stack redis/redis-stack:latest -``` - Import into your application: ```TypeScript @@ -32,6 +28,11 @@ import { Redis } from '@airswap/stores'; const store = new Redis(process.env.REDISCLOUD_URL) ``` +Dockerized Redis for local development: +```console +docker run -p 6379:6379 --name redis-stack redis/redis-stack:latest +``` + ## Commands | Command | Description | From 773f00c0a901b6705ef8e2a12c3125d1308ba6a3 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Tue, 13 Feb 2024 13:10:57 +0100 Subject: [PATCH 18/43] update redis:init command --- tools/stores/README.md | 5 +++++ tools/stores/package.json | 2 +- tools/stores/redis/redis.init.js | 6 ++++-- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/tools/stores/README.md b/tools/stores/README.md index f950c5294..8e92ad24c 100644 --- a/tools/stores/README.md +++ b/tools/stores/README.md @@ -33,6 +33,11 @@ Dockerized Redis for local development: docker run -p 6379:6379 --name redis-stack redis/redis-stack:latest ``` +Flush and create Redis indexes: +``` +yarn compile; yarn redis:init +``` + ## Commands | Command | Description | diff --git a/tools/stores/package.json b/tools/stores/package.json index 9eb8d2db5..ee6fc460e 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -17,7 +17,7 @@ "scripts": { "clean": "rm -rf ./build", "compile": "yarn clean && tsc -b", - "redis:init": "node ./redis/redis.init.js", + "redis:init": "REDISCLOUD_URL=redis://localhost:6379 node ./redis/redis.init.js", "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { diff --git a/tools/stores/redis/redis.init.js b/tools/stores/redis/redis.init.js index d0ffab265..9fd6dd623 100644 --- a/tools/stores/redis/redis.init.js +++ b/tools/stores/redis/redis.init.js @@ -1,6 +1,7 @@ require('dotenv').config({ path: '../../.env' }) -import reset from './redis.config' +const { createClient } = require('redis') +const config = require('../build/redis/redis.config.js') async function main() { if (!process.env.REDISCLOUD_URL) { @@ -12,7 +13,8 @@ async function main() { }) try { await client.connect() - await reset(client) + await config['default'](client) + console.log('Flushed and created Redis indexes.') process.exit(0) } catch (e) { console.error(e) From 1d495584bbebb0550835b80992a5bfa0a721da9e Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Tue, 13 Feb 2024 13:14:42 +0100 Subject: [PATCH 19/43] bump utils, libraries for publishing --- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 4 ++-- tools/stores/package.json | 2 +- tools/utils/package.json | 2 +- 10 files changed, 11 insertions(+), 11 deletions(-) diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 05a480eef..0d812b5ad 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,7 +31,7 @@ "@airswap/swap-erc20": "4.2.1" }, "devDependencies": { - "@airswap/utils": "4.2.6", + "@airswap/utils": "4.2.7", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index e9e40c09b..c84360768 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,7 +31,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.6", + "@airswap/utils": "4.2.7", "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, diff --git a/source/registry/package.json b/source/registry/package.json index bad50d15a..428d90b27 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.6", + "@airswap/utils": "4.2.7", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index fd1e96b12..0d17b64c4 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.6", + "@airswap/utils": "4.2.7", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index 867b67235..6837f4b04 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -30,7 +30,7 @@ }, "devDependencies": { "@airswap/staking": "4.2.1", - "@airswap/utils": "4.2.6", + "@airswap/utils": "4.2.7", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index 71c2ea77b..d7978632c 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.6", + "@airswap/utils": "4.2.7", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 9fa94c745..102bba378 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.6", + "@airswap/utils": "4.2.7", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 3d5b15918..fb54f42c6 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.8", + "version": "4.2.9", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -33,7 +33,7 @@ "@airswap/staking": "4.2.1", "@airswap/swap": "4.2.1", "@airswap/swap-erc20": "4.2.1", - "@airswap/utils": "4.2.6", + "@airswap/utils": "4.2.7", "@airswap/wrapper": "4.2.1", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", diff --git a/tools/stores/package.json b/tools/stores/package.json index ee6fc460e..5e3b5712d 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -21,7 +21,7 @@ "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/utils": "4.2.6", + "@airswap/utils": "4.2.7", "redis": "^4.6.13" }, "devDependencies": { diff --git a/tools/utils/package.json b/tools/utils/package.json index c3fa72c69..9ba3e3845 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.6", + "version": "4.2.7", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", From 92233348d5e5c5f5788a842a26586df1a6ba4ba5 Mon Sep 17 00:00:00 2001 From: don mosites Date: Tue, 13 Feb 2024 18:12:19 +0100 Subject: [PATCH 20/43] Apply suggestions from code review Co-authored-by: piersss <86911296+piersss@users.noreply.github.com> --- tools/stores/test/redis.ts | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/tools/stores/test/redis.ts b/tools/stores/test/redis.ts index 8ae0c6ab9..8ed70a590 100644 --- a/tools/stores/test/redis.ts +++ b/tools/stores/test/redis.ts @@ -54,6 +54,7 @@ describe('Redis', async () => { it('Tags are stored', async () => { await store.write(orderOne, ['grass:green', 'sky:blue']) await store.write(orderTwo, ['grass:green', 'sky:grey']) + await store.write(orderThree, ['grass:green', 'grass:green']) const tokenTags = await store.tags(orderOne.signer.token) expect(tokenTags).to.deep.equal(['grass:green', 'sky:blue', 'sky:grey']) }) @@ -80,7 +81,16 @@ describe('Redis', async () => { it('Query by tag', async () => { await store.write(orderOne, ['Grass|Green', 'Sun:Bright Yellow']) - await store.write(orderTwo, ['Grass|Green', 'Sun=Deep Orange']) + await store.write(orderTwo, [ + 'Grass|Green', + 'Sun=Deep Orange', + 'Grass', + 'Two Words', + ' ', + '', + undefined, + null, + ]) const res = await store.read({ signerToken: orderOne.signer.token, tags: ['Sun:Bright Yellow'], From 4aebe8209cea08937d7cd88748ba975fb2821604 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Tue, 13 Feb 2024 18:15:35 +0100 Subject: [PATCH 21/43] update tests --- tools/stores/test/redis.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/tools/stores/test/redis.ts b/tools/stores/test/redis.ts index 8ed70a590..cea4ba65d 100644 --- a/tools/stores/test/redis.ts +++ b/tools/stores/test/redis.ts @@ -53,8 +53,7 @@ describe('Redis', async () => { it('Tags are stored', async () => { await store.write(orderOne, ['grass:green', 'sky:blue']) - await store.write(orderTwo, ['grass:green', 'sky:grey']) - await store.write(orderThree, ['grass:green', 'grass:green']) + await store.write(orderTwo, ['grass:green', 'grass:green', 'sky:grey']) const tokenTags = await store.tags(orderOne.signer.token) expect(tokenTags).to.deep.equal(['grass:green', 'sky:blue', 'sky:grey']) }) @@ -88,9 +87,7 @@ describe('Redis', async () => { 'Two Words', ' ', '', - undefined, - null, - ]) + ]) const res = await store.read({ signerToken: orderOne.signer.token, tags: ['Sun:Bright Yellow'], From 63fe9b2b62fd4e64c3e7020a01a7f6f9730de435 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Wed, 14 Feb 2024 16:27:17 +0100 Subject: [PATCH 22/43] longer timeout for (non-ci) metadata tests --- tools/utils/test/metadata.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tools/utils/test/metadata.ts b/tools/utils/test/metadata.ts index b6d3e9f8a..d1de0ff21 100644 --- a/tools/utils/test/metadata.ts +++ b/tools/utils/test/metadata.ts @@ -6,8 +6,11 @@ import { findTokenByAddress, } from '../index' -describe('Metadata: Ethereum', async () => { +const METADATA_FETCH_TIMEOUT = 5000 + +describe('Metadata: Ethereum', async function go() { let result: any + this.timeout(METADATA_FETCH_TIMEOUT) it('fetches all known tokens', async () => { result = await getKnownTokens(ChainIds.MAINNET) From 3e55e78f248c2f87e9c9becd52690f7c8243e759 Mon Sep 17 00:00:00 2001 From: don mosites Date: Wed, 14 Feb 2024 16:39:34 +0100 Subject: [PATCH 23/43] @airswap/stores: index and store by chainId; flexible filters (#1288) * index and store by chainId; flexible filters * clarity and existing order quickfix --- tools/stores/package.json | 2 +- tools/stores/redis/redis.config.ts | 5 +- tools/stores/redis/redis.init.js | 1 + tools/stores/redis/redis.ts | 79 ++++++++++++++++++++---------- tools/stores/test/redis.ts | 54 ++++++++++++++------ 5 files changed, 100 insertions(+), 41 deletions(-) diff --git a/tools/stores/package.json b/tools/stores/package.json index 5e3b5712d..68b19a4a0 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/stores", - "version": "4.2.0", + "version": "4.2.1", "description": "AirSwap: Storage for Indexing", "repository": { "type": "git", diff --git a/tools/stores/redis/redis.config.ts b/tools/stores/redis/redis.config.ts index dea4d484b..3b0f1ecd5 100644 --- a/tools/stores/redis/redis.config.ts +++ b/tools/stores/redis/redis.config.ts @@ -2,10 +2,13 @@ require('dotenv').config({ path: '../../.env' }) const { SchemaFieldTypes } = require('redis') export default async function reset(client) { - await client.flushAll() await client.ft.create( 'index:ordersBySigner', { + '$.chainId': { + type: SchemaFieldTypes.NUMERIC, + AS: 'chainId', + }, '$.nonce': { type: SchemaFieldTypes.TEXT, AS: 'nonce', diff --git a/tools/stores/redis/redis.init.js b/tools/stores/redis/redis.init.js index 9fd6dd623..c0cad3070 100644 --- a/tools/stores/redis/redis.init.js +++ b/tools/stores/redis/redis.init.js @@ -13,6 +13,7 @@ async function main() { }) try { await client.connect() + await client.flushAll() await config['default'](client) console.log('Flushed and created Redis indexes.') process.exit(0) diff --git a/tools/stores/redis/redis.ts b/tools/stores/redis/redis.ts index 9b63e8267..8517e17aa 100644 --- a/tools/stores/redis/redis.ts +++ b/tools/stores/redis/redis.ts @@ -12,17 +12,21 @@ function tagsKey(token: string) { return `tags:${token.toLowerCase()}` } -function tokenKey(token: string, id: string) { - return `ordersByToken:${token.toLowerCase()}:${id}` +function tokenKey(chainId: number, signerToken: string, id: string) { + return `ordersByToken:${chainId}:${signerToken.toLowerCase()}:${id}` } -function signerKey(signer: string, nonce: string) { - return `ordersBySigner:${signer.toLowerCase()}:${nonce}` +function signerKey(chainId: number, signerWallet: string, nonce: string) { + return `ordersBySigner:${chainId}:${signerWallet.toLowerCase()}:${nonce}` } function cleanTags(tags: string[]) { return tags.map((tag) => - tag.replace(/\:/g, '\\:').replace(/\=/g, '\\=').replace(/\|/g, '\\|') + tag + .replace(/\s/g, '\\ ') + .replace(/\:/g, '\\:') + .replace(/\=/g, '\\=') + .replace(/\|/g, '\\|') ) } @@ -49,41 +53,45 @@ export class Redis { } const existing = await this.client.json.get( - tokenKey(order.signer.token, order.signer.id) + tokenKey(order.chainId, order.signer.token, order.signer.id) ) // Delete existing order if found. if (existing) { const existingOrder = await this.client.json.get( - signerKey(existing.signerWallet, existing.nonce) + signerKey(existing[0], existing[1], existing[2]) ) await this.client.json.del( - signerKey(existing.signerWallet, existing.nonce) + signerKey(existing[0], existing[1], existing[2]) ) await this.client.json.del( - tokenKey(existingOrder.signer.token, existingOrder.signer.id) + tokenKey( + existingOrder.chainId, + existingOrder.signer.token, + existingOrder.signer.id + ) ) } // Set order by signer wallet and nonce. await this.client.json.set( - signerKey(order.signer.wallet, order.nonce), + signerKey(order.chainId, order.signer.wallet, order.nonce), '$', { ...order, tags: tags || [] } ) await this.client.expire( - signerKey(order.signer.wallet, order.nonce), + signerKey(order.chainId, order.signer.wallet, order.nonce), this.ttl ) // Set unique by signer token and signer id. await this.client.json.set( - tokenKey(order.signer.token, order.signer.id), + tokenKey(order.chainId, order.signer.token, order.signer.id), '$', - { nonce: order.nonce, signerWallet: order.signer.wallet.toLowerCase() } + [order.chainId, order.signer.wallet.toLowerCase(), order.nonce] ) await this.client.expire( - tokenKey(order.signer.token, order.signer.id), + tokenKey(order.chainId, order.signer.token, order.signer.id), this.ttl ) @@ -113,12 +121,20 @@ export class Redis { } const args = [] - if (filter.senderToken) args.push(`@senderToken:${filter.senderToken}`) - if (filter.signerToken) args.push(`@signerToken:${filter.signerToken}`) - if (filter.signerId) args.push(`@signerId:${filter.signerId}`) - if (filter.signerWallet) args.push(`@signerWallet:${filter.signerWallet}`) - if (filter.tags?.length) - args.push(`@tags:{${cleanTags(filter.tags).join('|')}}`) + for (const prop in filter) { + switch (prop) { + case 'chainId': + args.push(`@chainId:[${filter.chainId} ${filter.chainId}]`) + break + case 'tags': + if (filter.tags.length) { + args.push(`@tags:{${cleanTags(filter.tags).join('|')}}`) + } + break + default: + args.push(`@${prop}:(${filter[prop]})`) + } + } const { total, documents } = await this.client.ft.search( 'index:ordersBySigner', @@ -135,27 +151,40 @@ export class Redis { } } - public async delete(signerWallet: string, nonce: string) { + public async delete(chainId: number, signerWallet: string, nonce: string) { if (!this.client.isOpen) { await this.client.connect() } - const order = await this.client.json.get(signerKey(signerWallet, nonce)) + const order = await this.client.json.get( + signerKey(chainId, signerWallet, nonce) + ) if (order) { - await this.client.json.del(signerKey(order.signer.wallet, order.nonce)) - await this.client.json.del(tokenKey(order.signer.token, order.signer.id)) + await this.client.json.del( + signerKey(order.chainId, order.signer.wallet, order.nonce) + ) + await this.client.json.del( + tokenKey(order.chainId, order.signer.token, order.signer.id) + ) return true } return false } - public async reset() { + public async setup() { if (!this.client.isOpen) { await this.client.connect() } await reset(this.client) } + public async flush() { + if (!this.client.isOpen) { + await this.client.connect() + } + await this.client.flushAll() + } + public async disconnect() { if (this.client.isOpen) { await this.client.disconnect() diff --git a/tools/stores/test/redis.ts b/tools/stores/test/redis.ts index cea4ba65d..c7e45d98d 100644 --- a/tools/stores/test/redis.ts +++ b/tools/stores/test/redis.ts @@ -1,5 +1,6 @@ import { expect } from 'chai' import { Redis } from '../redis/redis' +import { ChainIds } from '@airswap/utils' import { createOrder, @@ -10,10 +11,18 @@ import { const store = new Redis(process.env.REDISCLOUD_URL) +const TOKEN_ADDRESS = '0x000000000000000000000000000000000000000A' +const signerOne = '0x0000000000000000000000000000000000000001' +const signerTwo = '0x0000000000000000000000000000000000000002' + +let orderOne +let orderTwo + async function createSignedOrder( id: string, signerWallet = ADDRESS_ZERO, - signerToken = '0x000000000000000000000000000000000000000A' + signerToken = TOKEN_ADDRESS, + chainId = 1 ): Promise { const unsignedOrder = createOrder({ signer: { @@ -23,7 +32,7 @@ async function createSignedOrder( }, }) return { - chainId: 1, + chainId, swapContract: ADDRESS_ZERO, ...unsignedOrder, ...(await createOrderSignature( @@ -34,15 +43,10 @@ async function createSignedOrder( } } -const signerOne = '0x0000000000000000000000000000000000000001' -const signerTwo = '0x0000000000000000000000000000000000000002' - -let orderOne -let orderTwo - describe('Redis', async () => { - before(async () => { - await store.reset() + beforeEach(async () => { + await store.flush() + await store.setup() orderOne = await createSignedOrder('1', signerOne) orderTwo = await createSignedOrder('2', signerTwo) }) @@ -54,15 +58,26 @@ describe('Redis', async () => { it('Tags are stored', async () => { await store.write(orderOne, ['grass:green', 'sky:blue']) await store.write(orderTwo, ['grass:green', 'grass:green', 'sky:grey']) - const tokenTags = await store.tags(orderOne.signer.token) + const tokenTags = await store.tags(TOKEN_ADDRESS) expect(tokenTags).to.deep.equal(['grass:green', 'sky:blue', 'sky:grey']) }) + it('Query by chain id', async () => { + await store.write(orderOne) + await store.write( + await createSignedOrder('2', signerTwo, TOKEN_ADDRESS, ChainIds.SEPOLIA) + ) + const res = await store.read({ + chainId: ChainIds.SEPOLIA, + }) + expect(res.total).to.equal(1) + }) + it('Query by signer token', async () => { await store.write(orderOne) await store.write(orderTwo) const res = await store.read({ - signerToken: orderOne.signer.token, + signerToken: TOKEN_ADDRESS, }) expect(res.total).to.equal(2) expect(res.orders[0].signer.id).to.equal('1') @@ -89,13 +104,24 @@ describe('Redis', async () => { '', ]) const res = await store.read({ - signerToken: orderOne.signer.token, + signerToken: TOKEN_ADDRESS, tags: ['Sun:Bright Yellow'], }) expect(res.total).to.equal(1) expect(res.orders[0].signer.id).to.equal('1') }) + it('Query with empty tags', async () => { + await store.write(orderOne) + await store.write(orderTwo) + const res = await store.read({ + signerToken: TOKEN_ADDRESS, + tags: [], + }) + expect(res.total).to.equal(2) + expect(res.orders[0].signer.id).to.equal('1') + }) + it('Query with pagination', async () => { const OFFSET = 5 const LIMIT = 30 @@ -106,7 +132,7 @@ describe('Redis', async () => { } const res = await store.read( { - signerToken: orderOne.signer.token, + signerToken: TOKEN_ADDRESS, }, OFFSET, LIMIT From 71161af671f8eff88d3ffc8177032d3ae0e38ff1 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Thu, 15 Feb 2024 10:15:55 +0100 Subject: [PATCH 24/43] @airswap/stores: separate flush and recreate commands for redis --- tools/stores/package.json | 3 ++- tools/stores/redis/redis.config.ts | 1 + tools/stores/redis/redis.flush.js | 23 +++++++++++++++++++ .../{redis.init.js => redis.recreate.js} | 5 ++-- 4 files changed, 29 insertions(+), 3 deletions(-) create mode 100644 tools/stores/redis/redis.flush.js rename tools/stores/redis/{redis.init.js => redis.recreate.js} (84%) diff --git a/tools/stores/package.json b/tools/stores/package.json index 68b19a4a0..aeec0767b 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -17,7 +17,8 @@ "scripts": { "clean": "rm -rf ./build", "compile": "yarn clean && tsc -b", - "redis:init": "REDISCLOUD_URL=redis://localhost:6379 node ./redis/redis.init.js", + "redis:flush": "REDISCLOUD_URL=redis://localhost:6379 node ./redis/redis.flush.js", + "redis:recreate": "REDISCLOUD_URL=redis://localhost:6379 node ./redis/redis.recreate.js", "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { diff --git a/tools/stores/redis/redis.config.ts b/tools/stores/redis/redis.config.ts index 3b0f1ecd5..83e30bcbe 100644 --- a/tools/stores/redis/redis.config.ts +++ b/tools/stores/redis/redis.config.ts @@ -2,6 +2,7 @@ require('dotenv').config({ path: '../../.env' }) const { SchemaFieldTypes } = require('redis') export default async function reset(client) { + await client.ft.dropIndex('index:ordersBySigner') await client.ft.create( 'index:ordersBySigner', { diff --git a/tools/stores/redis/redis.flush.js b/tools/stores/redis/redis.flush.js new file mode 100644 index 000000000..952c40f98 --- /dev/null +++ b/tools/stores/redis/redis.flush.js @@ -0,0 +1,23 @@ +require('dotenv').config({ path: '../../.env' }) + +const { createClient } = require('redis') + +async function main() { + if (!process.env.REDISCLOUD_URL) { + console.log('process.env.REDISCLOUD_URL must be set.') + process.exit(-1) + } + const client = createClient({ + url: process.env.REDISCLOUD_URL, + }) + try { + await client.connect() + await client.flushAll() + console.log(`Flushed Redis instance at ${process.env.REDISCLOUD_URL}.`) + process.exit(0) + } catch (e) { + console.error(e) + process.exit(1) + } +} +main() diff --git a/tools/stores/redis/redis.init.js b/tools/stores/redis/redis.recreate.js similarity index 84% rename from tools/stores/redis/redis.init.js rename to tools/stores/redis/redis.recreate.js index c0cad3070..a34eab3fc 100644 --- a/tools/stores/redis/redis.init.js +++ b/tools/stores/redis/redis.recreate.js @@ -13,9 +13,10 @@ async function main() { }) try { await client.connect() - await client.flushAll() await config['default'](client) - console.log('Flushed and created Redis indexes.') + console.log( + `Recreated index on Redis instance at ${process.env.REDISCLOUD_URL}.` + ) process.exit(0) } catch (e) { console.error(e) From f02a764f2b157365c743aa1f465d34a70c2eaf0b Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Thu, 15 Feb 2024 13:30:32 +0100 Subject: [PATCH 25/43] @airswap/stores: escape hyphen on query; update tests --- tools/stores/package.json | 4 ++-- .../redis/{redis.recreate.js => redis.create.js} | 6 +++--- tools/stores/redis/{redis.config.ts => redis.index.ts} | 6 ++++-- tools/stores/redis/redis.ts | 5 +++-- tools/stores/test/redis.ts | 10 ++++++++-- 5 files changed, 20 insertions(+), 11 deletions(-) rename tools/stores/redis/{redis.recreate.js => redis.create.js} (73%) rename tools/stores/redis/{redis.config.ts => redis.index.ts} (90%) diff --git a/tools/stores/package.json b/tools/stores/package.json index aeec0767b..d8152724d 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/stores", - "version": "4.2.1", + "version": "4.2.2", "description": "AirSwap: Storage for Indexing", "repository": { "type": "git", @@ -18,7 +18,7 @@ "clean": "rm -rf ./build", "compile": "yarn clean && tsc -b", "redis:flush": "REDISCLOUD_URL=redis://localhost:6379 node ./redis/redis.flush.js", - "redis:recreate": "REDISCLOUD_URL=redis://localhost:6379 node ./redis/redis.recreate.js", + "redis:create": "yarn compile && REDISCLOUD_URL=redis://localhost:6379 node ./redis/redis.create.js", "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { diff --git a/tools/stores/redis/redis.recreate.js b/tools/stores/redis/redis.create.js similarity index 73% rename from tools/stores/redis/redis.recreate.js rename to tools/stores/redis/redis.create.js index a34eab3fc..837ad3aa6 100644 --- a/tools/stores/redis/redis.recreate.js +++ b/tools/stores/redis/redis.create.js @@ -1,7 +1,7 @@ require('dotenv').config({ path: '../../.env' }) const { createClient } = require('redis') -const config = require('../build/redis/redis.config.js') +const { createIndex } = require('../build/redis/redis.index.js') async function main() { if (!process.env.REDISCLOUD_URL) { @@ -13,9 +13,9 @@ async function main() { }) try { await client.connect() - await config['default'](client) + await createIndex(client) console.log( - `Recreated index on Redis instance at ${process.env.REDISCLOUD_URL}.` + `Created index on Redis instance at ${process.env.REDISCLOUD_URL}.` ) process.exit(0) } catch (e) { diff --git a/tools/stores/redis/redis.config.ts b/tools/stores/redis/redis.index.ts similarity index 90% rename from tools/stores/redis/redis.config.ts rename to tools/stores/redis/redis.index.ts index 83e30bcbe..2b6f61fcb 100644 --- a/tools/stores/redis/redis.config.ts +++ b/tools/stores/redis/redis.index.ts @@ -1,8 +1,10 @@ require('dotenv').config({ path: '../../.env' }) const { SchemaFieldTypes } = require('redis') -export default async function reset(client) { - await client.ft.dropIndex('index:ordersBySigner') +export async function createIndex(client) { + try { + await client.ft.dropIndex('index:ordersBySigner') + } catch (e) {} await client.ft.create( 'index:ordersBySigner', { diff --git a/tools/stores/redis/redis.ts b/tools/stores/redis/redis.ts index 8517e17aa..efff2c897 100644 --- a/tools/stores/redis/redis.ts +++ b/tools/stores/redis/redis.ts @@ -6,7 +6,7 @@ import { Direction, THIRTY_DAYS, } from '@airswap/utils' -import reset from '../redis/redis.config' +import { createIndex } from './redis.index' function tagsKey(token: string) { return `tags:${token.toLowerCase()}` @@ -24,6 +24,7 @@ function cleanTags(tags: string[]) { return tags.map((tag) => tag .replace(/\s/g, '\\ ') + .replace(/\-/g, '\\-') .replace(/\:/g, '\\:') .replace(/\=/g, '\\=') .replace(/\|/g, '\\|') @@ -175,7 +176,7 @@ export class Redis { if (!this.client.isOpen) { await this.client.connect() } - await reset(this.client) + await createIndex(this.client) } public async flush() { diff --git a/tools/stores/test/redis.ts b/tools/stores/test/redis.ts index c7e45d98d..ef910fd52 100644 --- a/tools/stores/test/redis.ts +++ b/tools/stores/test/redis.ts @@ -100,15 +100,21 @@ describe('Redis', async () => { 'Sun=Deep Orange', 'Grass', 'Two Words', + 'Eyes:Big Yellow Side-eye', ' ', '', ]) const res = await store.read({ signerToken: TOKEN_ADDRESS, - tags: ['Sun:Bright Yellow'], + tags: [ + 'Sun:Bright Yellow', + 'Eyes:Big Yellow Side-eye', + 'Sun=Deep Orange', + ], }) - expect(res.total).to.equal(1) + expect(res.total).to.equal(2) expect(res.orders[0].signer.id).to.equal('1') + expect(res.orders[1].signer.id).to.equal('2') }) it('Query with empty tags', async () => { From 0a8b536ec4a68136f1f81cd119206d3b37b7fa2f Mon Sep 17 00:00:00 2001 From: don mosites Date: Thu, 15 Feb 2024 22:41:03 +0100 Subject: [PATCH 26/43] fix filtering for getServerURLs; add test file for Registry (#1289) * fix filtering for getServerURLs; add test file for Registry * bump libraries version for publishing --- tools/libraries/package.json | 2 +- tools/libraries/src/Registry.ts | 43 ++++++----- tools/libraries/test/Registry.test.ts | 101 ++++++++++++++++++++++++++ 3 files changed, 126 insertions(+), 20 deletions(-) create mode 100644 tools/libraries/test/Registry.test.ts diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 0ffa2d744..fc667394c 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.9", + "version": "4.2.10", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", diff --git a/tools/libraries/src/Registry.ts b/tools/libraries/src/Registry.ts index 96d55e824..97febf757 100644 --- a/tools/libraries/src/Registry.ts +++ b/tools/libraries/src/Registry.ts @@ -1,5 +1,4 @@ import { ethers } from 'ethers' -import { ServerOptions } from '@airswap/utils' import { Registry__factory } from '@airswap/registry/typechain/factories/contracts' import registryDeploys from '@airswap/registry/deploys.js' import registryBlocks from '@airswap/registry/deploys-blocks.js' @@ -16,23 +15,29 @@ class ServerRegistry extends Contract { chainId: number, protocol: string, baseToken?: string, - quoteToken?: string + quoteToken?: string, + address = registryDeploys[chainId] ): Promise { - const contract = Registry__factory.connect( - registryDeploys[chainId], - providerOrSigner - ) + const contract = Registry__factory.connect(address, providerOrSigner) const protocolStakers: string[] = await contract.getStakersForProtocol( protocol ) - const stakers = protocolStakers.filter(async (staker) => { - const tokens = await contract.getTokensForStaker(staker) - let include = false - if (!tokens.length) include = true - else if (baseToken) include = tokens.includes(baseToken) - else if (quoteToken) include = tokens.includes(quoteToken) - return include - }) + const results = await Promise.all( + protocolStakers.map(async (staker) => { + const tokens = await contract.getTokensForStaker(staker) + let toInclude = false + if (baseToken) + toInclude = tokens + .map((token) => token.toLowerCase()) + .includes(baseToken.toLowerCase()) + else if (quoteToken) + toInclude = tokens + .map((token) => token.toLowerCase()) + .includes(quoteToken.toLowerCase()) + return toInclude + }) + ) + const stakers = protocolStakers.filter((_v, index) => results[index]) return await contract.getServerURLsForStakers(stakers) } public async getServers( @@ -41,21 +46,21 @@ class ServerRegistry extends Contract { protocol: string, baseToken?: string, quoteToken?: string, - options?: ServerOptions + address = registryDeploys[chainId] ): Promise> { const urls = await this.getServerURLs( providerOrSigner, chainId, protocol, baseToken, - quoteToken + quoteToken, + address ) const serverPromises = await Promise.allSettled( urls.map((url) => { return Server.at(url, { - swapContract: options?.swapContract || SwapERC20.addresses[chainId], - chainId: chainId, - initializeTimeout: options?.initializeTimeout, + chainId, + swapContract: SwapERC20.addresses[chainId], }) }) ) diff --git a/tools/libraries/test/Registry.test.ts b/tools/libraries/test/Registry.test.ts new file mode 100644 index 000000000..4a1315078 --- /dev/null +++ b/tools/libraries/test/Registry.test.ts @@ -0,0 +1,101 @@ +import { ADDRESS_ZERO } from '@airswap/utils' +import { expect } from 'chai' + +const { ChainIds, ProtocolIds } = require('@airswap/utils') +const { ethers } = require('hardhat') +const ERC20PresetFixedSupply = require('@openzeppelin/contracts/build/contracts/ERC20PresetFixedSupply.json') +const RegistryABI = require('@airswap/registry/build/contracts/Registry.sol/Registry.json') + +const { Registry } = require('../index') + +let deployer +let staker +let stakingToken +let baseToken +let quoteToken +let registryFactory +let registry + +const SERVER_URL = 'https://maker.com/xyz' +const STAKING_COST = 1000 +const SUPPORT_COST = 10 +const TOKEN_BALANCE = 10000 + +describe('Registry', async () => { + before(async () => { + ;[deployer, staker] = await ethers.getSigners() + stakingToken = await ( + await ethers.getContractFactory( + ERC20PresetFixedSupply.abi, + ERC20PresetFixedSupply.bytecode + ) + ).deploy('TestERC20', 'TERC20', TOKEN_BALANCE, staker.address) + baseToken = await ( + await ethers.getContractFactory( + ERC20PresetFixedSupply.abi, + ERC20PresetFixedSupply.bytecode + ) + ).deploy('TestERC20', 'TERC20', TOKEN_BALANCE, staker.address) + quoteToken = await ( + await ethers.getContractFactory( + ERC20PresetFixedSupply.abi, + ERC20PresetFixedSupply.bytecode + ) + ).deploy('TestERC20', 'TERC20', TOKEN_BALANCE, staker.address) + registryFactory = await ethers.getContractFactory( + RegistryABI.abi, + RegistryABI.bytecode + ) + registry = await registryFactory + .connect(deployer) + .deploy(stakingToken.address, STAKING_COST, SUPPORT_COST) + await registry.deployed() + + stakingToken.connect(staker).approve(registry.address, STAKING_COST * 2) + + await registry.connect(staker).setServerURL(SERVER_URL) + await registry + .connect(staker) + .addProtocols([ProtocolIds.RequestForQuoteERC20]) + await registry + .connect(staker) + .addTokens([quoteToken.address, baseToken.address]) + }) + + it('get URLs: succeeds', async () => { + const servers = await Registry.getServerURLs( + ethers.provider, + ChainIds.HARDHAT, + ProtocolIds.RequestForQuoteERC20, + baseToken.address, + quoteToken.address, + registry.address + ) + expect(servers.length).to.be.equal(1) + expect(servers[0]).to.be.equal(SERVER_URL) + }) + + it('get URLs: none for incorrect protocol', async () => { + const servers = await Registry.getServerURLs( + ethers.provider, + ChainIds.HARDHAT, + ProtocolIds.LastLookERC20, + baseToken.address, + quoteToken.address, + registry.address + ) + expect(servers.length).to.be.equal(0) + }) + + it('get URLs: none for incorrect tokens', async () => { + const servers = await Registry.getServerURLs( + ethers.provider, + ChainIds.HARDHAT, + ProtocolIds.RequestForQuoteERC20, + ADDRESS_ZERO, + ADDRESS_ZERO, + registry.address + ) + expect(servers.length).to.be.equal(0) + }) +}) From 753c13e3b51c26dda9bf78745bdf2132e930f782 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Fri, 16 Feb 2024 07:00:06 +0100 Subject: [PATCH 27/43] @airwap/utils: drop wrapper dep; add native tokens --- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 4 ++-- tools/stores/package.json | 2 +- tools/utils/package.json | 2 +- tools/utils/src/constants.ts | 22 ++++++++++++++++++++++ tools/utils/src/metadata.ts | 12 +++++++----- tools/utils/src/tokendefaults.ts | 3 ++- tools/utils/src/tokenlists.ts | 2 +- 14 files changed, 43 insertions(+), 18 deletions(-) diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 0d812b5ad..8e4853379 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,7 +31,7 @@ "@airswap/swap-erc20": "4.2.1" }, "devDependencies": { - "@airswap/utils": "4.2.7", + "@airswap/utils": "4.2.8", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index c84360768..4e022c02d 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,7 +31,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.7", + "@airswap/utils": "4.2.8", "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, diff --git a/source/registry/package.json b/source/registry/package.json index 428d90b27..6d8179e22 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.7", + "@airswap/utils": "4.2.8", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index 0d17b64c4..19ade7278 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.7", + "@airswap/utils": "4.2.8", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index 6837f4b04..ab8bb35a2 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -30,7 +30,7 @@ }, "devDependencies": { "@airswap/staking": "4.2.1", - "@airswap/utils": "4.2.7", + "@airswap/utils": "4.2.8", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index d7978632c..1319461b8 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.7", + "@airswap/utils": "4.2.8", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 102bba378..a4518c764 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.7", + "@airswap/utils": "4.2.8", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index fc667394c..cd50df46c 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.10", + "version": "4.2.11", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -29,7 +29,7 @@ "@airswap/staking": "4.2.1", "@airswap/swap": "4.2.1", "@airswap/swap-erc20": "4.2.1", - "@airswap/utils": "4.2.7", + "@airswap/utils": "4.2.8", "@airswap/wrapper": "4.2.1", "browser-or-node": "^2.1.1", "ethers": "^5.6.9", diff --git a/tools/stores/package.json b/tools/stores/package.json index d8152724d..e548377c6 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -22,7 +22,7 @@ "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/utils": "4.2.7", + "@airswap/utils": "4.2.8", "redis": "^4.6.13" }, "devDependencies": { diff --git a/tools/utils/package.json b/tools/utils/package.json index 9ba3e3845..9be1dfe11 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.7", + "version": "4.2.8", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", diff --git a/tools/utils/src/constants.ts b/tools/utils/src/constants.ts index 069cefe9e..f213c62bf 100644 --- a/tools/utils/src/constants.ts +++ b/tools/utils/src/constants.ts @@ -207,6 +207,28 @@ export const stakingTokenAddresses: Record = { [ChainIds.HOLESKY]: '0x4092d6dba9abb7450b9d91aa7ed2712935d63b39', } +export const wrappedNativeTokenAddresses: Record = { + [ChainIds.MAINNET]: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2', + [ChainIds.RSK]: '0x967f8799af07df1534d48a95a5c9febe92c53ae0', + [ChainIds.RSKTESTNET]: '0x09b6ca5e4496238a1f176aea6bb607db96c2286e', + [ChainIds.TELOS]: '0xD102cE6A4dB07D247fcc28F366A623Df0938CA9E', + [ChainIds.TELOSTESTNET]: '0xaE85Bf723A9e74d6c663dd226996AC1b8d075AA9', + [ChainIds.BSC]: '0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c', + [ChainIds.BSCTESTNET]: '0xae13d989daC2f0dEbFf460aC112a837C89BAa7cd', + [ChainIds.POLYGON]: '0x0d500b1d8e8ef31e21c99d1db9a6444d3adf1270', + [ChainIds.BASE]: '0x4200000000000000000000000000000000000006', + [ChainIds.HOLESKY]: '0x94373a4919b3240d86ea41593d5eba789fef3848', + [ChainIds.ARBITRUM]: '0x82af49447d8a07e3bd95bd0d56f35241523fbab1', + [ChainIds.FUJI]: '0xd9d01a9f7c810ec035c0e42cb9e80ef44d7f8692', + [ChainIds.AVALANCHE]: '0xb31f66aa3c1e785363f0875a1b74e27b85fd66c7', + [ChainIds.LINEAGOERLI]: '0x2C1b868d6596a18e32E61B901E4060C872647b6C', + [ChainIds.LINEA]: '0xe5D7C2a44FfDDf6b295A15c148167daaAf5Cf34f', + [ChainIds.MUMBAI]: '0x9c3C9283D3e44854697Cd22D3Faa240Cfb032889', + [ChainIds.BASESEPOLIA]: '0x4200000000000000000000000000000000000006', + [ChainIds.ARBITRUMSEPOLIA]: '0x0091f4e75a03c11cb9be8e3717219005eb780d89', + [ChainIds.SEPOLIA]: '0x7b79995e5f793a07bc00c21412e50ecae098e7f9', +} + export const ownerAddresses: Record = { [ChainIds.MAINNET]: '0xf8bB149F9525875Fa47B8CC632d368EB600FAba3', [ChainIds.RSK]: '0xed669F5fe2A37Ef204DB178c7a982717B9f03Ec2', diff --git a/tools/utils/src/metadata.ts b/tools/utils/src/metadata.ts index 696895700..871dc93a7 100644 --- a/tools/utils/src/metadata.ts +++ b/tools/utils/src/metadata.ts @@ -4,14 +4,16 @@ import { CollectionTokenInfo, CollectionTokenMetadata, CollectionTokenAttribute, +} from './types' +import { TokenKinds, chainCurrencies, chainNames, stakingTokenAddresses, -} from '@airswap/utils' + wrappedNativeTokenAddresses, +} from './constants' import TOKEN_LISTS from './tokenlists' import TOKEN_DEFAULTS from './tokendefaults' -import wethDeploys from '@airswap/wrapper/deploys-weth.js' import validUrl from 'valid-url' const AIRSWAP_LOGO_URI = @@ -77,7 +79,7 @@ export async function getKnownTokens( } } } - if (wethDeploys[chainId]) { + if (wrappedNativeTokenAddresses[chainId]) { const wrappedTokens = getWrappedTokens() for (let i = 0; i < wrappedTokens.length; i++) { if (wrappedTokens[i].chainId == chainId) { @@ -130,12 +132,12 @@ export function firstTokenBySymbol( export function getWrappedTokens(): TokenInfo[] { const _wrappedTokens: TokenInfo[] = [] - for (const chainId in wethDeploys) { + for (const chainId in wrappedNativeTokenAddresses) { const _chainId = Number(chainId) _wrappedTokens.push({ name: `Wrapped ${chainCurrencies[_chainId]}`, symbol: `W${chainCurrencies[_chainId]}`, - address: wethDeploys[_chainId], + address: wrappedNativeTokenAddresses[_chainId], decimals: 18, chainId: Number(_chainId), }) diff --git a/tools/utils/src/tokendefaults.ts b/tools/utils/src/tokendefaults.ts index 378402070..2a9c7c20e 100644 --- a/tools/utils/src/tokendefaults.ts +++ b/tools/utils/src/tokendefaults.ts @@ -1,4 +1,5 @@ -import { ChainIds, TokenInfo } from '@airswap/utils' +import { ChainIds } from './constants' +import { TokenInfo } from './types' const TEST_TOKEN_DECIMALS = 6 export default [ diff --git a/tools/utils/src/tokenlists.ts b/tools/utils/src/tokenlists.ts index f5b3974b1..b1ccf5d48 100644 --- a/tools/utils/src/tokenlists.ts +++ b/tools/utils/src/tokenlists.ts @@ -1,4 +1,4 @@ -import { ChainIds } from '@airswap/utils' +import { ChainIds } from './constants' export default { [ChainIds.MAINNET]: [ From 94e806743d202fe70d3371735bedf5bc3e7bcf70 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Fri, 16 Feb 2024 07:01:01 +0100 Subject: [PATCH 28/43] @airswap/stores: bump for npm publishing --- tools/stores/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/stores/package.json b/tools/stores/package.json index e548377c6..f0c840a75 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/stores", - "version": "4.2.2", + "version": "4.2.3", "description": "AirSwap: Storage for Indexing", "repository": { "type": "git", From 1c3637ba86c816827e6ca9cec91221339493a910 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Fri, 16 Feb 2024 08:24:02 +0100 Subject: [PATCH 29/43] upgrade ethers 5.7.2; bump utils, libraries --- package.json | 2 +- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 6 +++--- tools/stores/package.json | 4 ++-- tools/utils/package.json | 4 ++-- yarn.lock | 2 +- 12 files changed, 16 insertions(+), 16 deletions(-) diff --git a/package.json b/package.json index b4ffc9e63..bc64507f0 100644 --- a/package.json +++ b/package.json @@ -41,7 +41,7 @@ "eslint-config-prettier": "^8.5.0", "eslint-plugin-prettier": "^4.2.1", "ethereum-waffle": "^4.0.10", - "ethers": "^5.6.9", + "ethers": "^5.7.2", "hardhat": "^2.12.7", "hardhat-gas-reporter": "^1.0.9", "husky": "^8.0.1", diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 8e4853379..8ac4da9ef 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,7 +31,7 @@ "@airswap/swap-erc20": "4.2.1" }, "devDependencies": { - "@airswap/utils": "4.2.8", + "@airswap/utils": "4.2.9", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index 4e022c02d..087a31e6a 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,7 +31,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.8", + "@airswap/utils": "4.2.9", "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, diff --git a/source/registry/package.json b/source/registry/package.json index 6d8179e22..3c7dfda8b 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.8", + "@airswap/utils": "4.2.9", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index 19ade7278..12bda2906 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.8", + "@airswap/utils": "4.2.9", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index ab8bb35a2..b8aa829f4 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -30,7 +30,7 @@ }, "devDependencies": { "@airswap/staking": "4.2.1", - "@airswap/utils": "4.2.8", + "@airswap/utils": "4.2.9", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index 1319461b8..90cdad28c 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.8", + "@airswap/utils": "4.2.9", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index a4518c764..f2fa66128 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.8", + "@airswap/utils": "4.2.9", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index cd50df46c..8c4d37e54 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.11", + "version": "4.2.12", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -29,10 +29,10 @@ "@airswap/staking": "4.2.1", "@airswap/swap": "4.2.1", "@airswap/swap-erc20": "4.2.1", - "@airswap/utils": "4.2.8", + "@airswap/utils": "4.2.9", "@airswap/wrapper": "4.2.1", "browser-or-node": "^2.1.1", - "ethers": "^5.6.9", + "ethers": "^5.7.2", "jayson": "^4.0.0", "tiny-typed-emitter": "^2.1.0", "websocket": "^1.0.34" diff --git a/tools/stores/package.json b/tools/stores/package.json index f0c840a75..40bb5a4ec 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/stores", - "version": "4.2.3", + "version": "4.2.4", "description": "AirSwap: Storage for Indexing", "repository": { "type": "git", @@ -22,7 +22,7 @@ "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/utils": "4.2.8", + "@airswap/utils": "4.2.9", "redis": "^4.6.13" }, "devDependencies": { diff --git a/tools/utils/package.json b/tools/utils/package.json index 9be1dfe11..40b993d92 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.8", + "version": "4.2.9", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", @@ -26,7 +26,7 @@ "@uniswap/token-lists": "^1.0.0-beta.24", "bignumber.js": "^9.0.1", "ethereumjs-util": "^7.1.5", - "ethers": "^5.6.9", + "ethers": "^5.7.2", "lz-string": "^1.5.0", "valid-url": "^1.0.9" }, diff --git a/yarn.lock b/yarn.lock index 8ce99306f..d4dda8eab 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4581,7 +4581,7 @@ ethers@^4.0.40: uuid "2.0.1" xmlhttprequest "1.8.0" -ethers@^5.6.9, ethers@^5.7.1: +ethers@^5.7.1, ethers@^5.7.2: version "5.7.2" resolved "https://registry.yarnpkg.com/ethers/-/ethers-5.7.2.tgz#3a7deeabbb8c030d4126b24f84e525466145872e" integrity sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg== From d3c6cea1cfffffd5a1052788cc0f693667372ec3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 20 Feb 2024 20:58:35 +0100 Subject: [PATCH 30/43] Bump undici from 5.28.2 to 5.28.3 (#1290) Bumps [undici](https://github.com/nodejs/undici) from 5.28.2 to 5.28.3. - [Release notes](https://github.com/nodejs/undici/releases) - [Commits](https://github.com/nodejs/undici/compare/v5.28.2...v5.28.3) --- updated-dependencies: - dependency-name: undici dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 8ce99306f..4910615a5 100644 --- a/yarn.lock +++ b/yarn.lock @@ -10305,9 +10305,9 @@ undici-types@~5.26.4: integrity sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA== undici@^5.14.0: - version "5.28.2" - resolved "https://registry.yarnpkg.com/undici/-/undici-5.28.2.tgz#fea200eac65fc7ecaff80a023d1a0543423b4c91" - integrity sha512-wh1pHJHnUeQV5Xa8/kyQhO7WFa8M34l026L5P/+2TYiakvGy5Rdc8jWZVyG7ieht/0WgJLEd3kcU5gKx+6GC8w== + version "5.28.3" + resolved "https://registry.yarnpkg.com/undici/-/undici-5.28.3.tgz#a731e0eff2c3fcfd41c1169a869062be222d1e5b" + integrity sha512-3ItfzbrhDlINjaP0duwnNsKpDQk3acHI3gVJ1z4fmwMK31k5G9OVIAMLSIaP6w4FaGkaAkN6zaQO9LUvZ1t7VA== dependencies: "@fastify/busboy" "^2.0.0" From cae9c63128ec0e93155de4d8b6c37959213d1ed1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 20 Feb 2024 20:59:51 +0100 Subject: [PATCH 31/43] Bump ip from 2.0.0 to 2.0.1 (#1291) Bumps [ip](https://github.com/indutny/node-ip) from 2.0.0 to 2.0.1. - [Commits](https://github.com/indutny/node-ip/compare/v2.0.0...v2.0.1) --- updated-dependencies: - dependency-name: ip dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 4910615a5..00dd088bc 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5954,9 +5954,9 @@ io-ts@1.10.4: fp-ts "^1.0.0" ip@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ip/-/ip-2.0.0.tgz#4cf4ab182fee2314c75ede1276f8c80b479936da" - integrity sha512-WKa+XuLG1A1R0UWhl2+1XQSi+fZWMsYKffMZTTYsiZaUD8k2yDAj5atimTUD2TZkyCkNEeYE5NhFZmupOGtjYQ== + version "2.0.1" + resolved "https://registry.yarnpkg.com/ip/-/ip-2.0.1.tgz#e8f3595d33a3ea66490204234b77636965307105" + integrity sha512-lJUL9imLTNi1ZfXT+DU6rBBdbiKGBuay9B6xGSPVjUeQwaH1RIGqef8RZkUtHioLmSNpPR5M4HVKJGm1j8FWVQ== ipaddr.js@1.9.1: version "1.9.1" From b5bf09a7f41b4ec7f681cc1677b94142217d64c6 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Thu, 22 Feb 2024 13:07:13 +0100 Subject: [PATCH 32/43] @airswap/stores: export createIndex from redis store --- tools/stores/package.json | 2 +- tools/stores/redis/redis.create.js | 2 +- tools/stores/redis/redis.index.ts | 56 ------------------------ tools/stores/redis/redis.ts | 70 +++++++++++++++++++++++++----- tools/stores/test/redis.ts | 4 +- 5 files changed, 62 insertions(+), 72 deletions(-) delete mode 100644 tools/stores/redis/redis.index.ts diff --git a/tools/stores/package.json b/tools/stores/package.json index 40bb5a4ec..9aa99c753 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/stores", - "version": "4.2.4", + "version": "4.2.5", "description": "AirSwap: Storage for Indexing", "repository": { "type": "git", diff --git a/tools/stores/redis/redis.create.js b/tools/stores/redis/redis.create.js index 837ad3aa6..357e1f74b 100644 --- a/tools/stores/redis/redis.create.js +++ b/tools/stores/redis/redis.create.js @@ -1,7 +1,7 @@ require('dotenv').config({ path: '../../.env' }) const { createClient } = require('redis') -const { createIndex } = require('../build/redis/redis.index.js') +const { createIndex } = require('../build/redis/redis.js') async function main() { if (!process.env.REDISCLOUD_URL) { diff --git a/tools/stores/redis/redis.index.ts b/tools/stores/redis/redis.index.ts deleted file mode 100644 index 2b6f61fcb..000000000 --- a/tools/stores/redis/redis.index.ts +++ /dev/null @@ -1,56 +0,0 @@ -require('dotenv').config({ path: '../../.env' }) -const { SchemaFieldTypes } = require('redis') - -export async function createIndex(client) { - try { - await client.ft.dropIndex('index:ordersBySigner') - } catch (e) {} - await client.ft.create( - 'index:ordersBySigner', - { - '$.chainId': { - type: SchemaFieldTypes.NUMERIC, - AS: 'chainId', - }, - '$.nonce': { - type: SchemaFieldTypes.TEXT, - AS: 'nonce', - }, - '$.expiry': { - type: SchemaFieldTypes.TEXT, - AS: 'expiry', - }, - '$.signer.wallet': { - type: SchemaFieldTypes.TEXT, - AS: 'signerWallet', - }, - '$.signer.token': { - type: SchemaFieldTypes.TEXT, - AS: 'signerToken', - }, - '$.signer.amount': { - type: SchemaFieldTypes.TEXT, - AS: 'signerAmount', - }, - '$.signer.id': { - type: SchemaFieldTypes.TEXT, - AS: 'signerId', - }, - '$.sender.amount': { - type: SchemaFieldTypes.TEXT, - AS: 'senderAmount', - }, - '$.sender.token': { - type: SchemaFieldTypes.TEXT, - AS: 'senderToken', - }, - '$.tags.*': { - type: SchemaFieldTypes.TAG, - AS: 'tags', - }, - }, - { - ON: 'JSON', - } - ) -} diff --git a/tools/stores/redis/redis.ts b/tools/stores/redis/redis.ts index efff2c897..3b55d4bbb 100644 --- a/tools/stores/redis/redis.ts +++ b/tools/stores/redis/redis.ts @@ -1,4 +1,4 @@ -import { createClient } from 'redis' +import { createClient, SchemaFieldTypes } from 'redis' import { FullOrder, OrderFilter, @@ -6,7 +6,6 @@ import { Direction, THIRTY_DAYS, } from '@airswap/utils' -import { createIndex } from './redis.index' function tagsKey(token: string) { return `tags:${token.toLowerCase()}` @@ -32,9 +31,9 @@ function cleanTags(tags: string[]) { } export class Redis { - private client: any - private ttl: number - private defaultReadLimit: number + public client: any + public ttl: number + public defaultReadLimit: number public constructor( connectionUrl: any, @@ -172,13 +171,6 @@ export class Redis { return false } - public async setup() { - if (!this.client.isOpen) { - await this.client.connect() - } - await createIndex(this.client) - } - public async flush() { if (!this.client.isOpen) { await this.client.connect() @@ -192,3 +184,57 @@ export class Redis { } } } + +export async function createIndex(client) { + try { + await client.ft.dropIndex('index:ordersBySigner') + } catch (e) {} + await client.ft.create( + 'index:ordersBySigner', + { + '$.chainId': { + type: SchemaFieldTypes.NUMERIC, + AS: 'chainId', + }, + '$.nonce': { + type: SchemaFieldTypes.TEXT, + AS: 'nonce', + }, + '$.expiry': { + type: SchemaFieldTypes.TEXT, + AS: 'expiry', + }, + '$.signer.wallet': { + type: SchemaFieldTypes.TEXT, + AS: 'signerWallet', + }, + '$.signer.token': { + type: SchemaFieldTypes.TEXT, + AS: 'signerToken', + }, + '$.signer.amount': { + type: SchemaFieldTypes.TEXT, + AS: 'signerAmount', + }, + '$.signer.id': { + type: SchemaFieldTypes.TEXT, + AS: 'signerId', + }, + '$.sender.amount': { + type: SchemaFieldTypes.TEXT, + AS: 'senderAmount', + }, + '$.sender.token': { + type: SchemaFieldTypes.TEXT, + AS: 'senderToken', + }, + '$.tags.*': { + type: SchemaFieldTypes.TAG, + AS: 'tags', + }, + }, + { + ON: 'JSON', + } + ) +} diff --git a/tools/stores/test/redis.ts b/tools/stores/test/redis.ts index ef910fd52..0cb39735b 100644 --- a/tools/stores/test/redis.ts +++ b/tools/stores/test/redis.ts @@ -1,5 +1,5 @@ import { expect } from 'chai' -import { Redis } from '../redis/redis' +import { Redis, createIndex } from '../redis/redis' import { ChainIds } from '@airswap/utils' import { @@ -46,7 +46,7 @@ async function createSignedOrder( describe('Redis', async () => { beforeEach(async () => { await store.flush() - await store.setup() + await createIndex(store.client) orderOne = await createSignedOrder('1', signerOne) orderTwo = await createSignedOrder('2', signerTwo) }) From b7b27dccc68096bdf2ba806e760ca27ad06ed5d6 Mon Sep 17 00:00:00 2001 From: don mosites Date: Thu, 22 Feb 2024 17:42:49 +0100 Subject: [PATCH 33/43] @airswap/utils: add animation_url to collection token (#1292) * add animation_url to collection token * update package versions for publishing --- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 4 ++-- tools/stores/package.json | 4 ++-- tools/utils/package.json | 2 +- tools/utils/src/metadata.ts | 4 +++- tools/utils/src/types.ts | 5 +++-- 12 files changed, 18 insertions(+), 15 deletions(-) diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 8ac4da9ef..e4a722e3c 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -31,7 +31,7 @@ "@airswap/swap-erc20": "4.2.1" }, "devDependencies": { - "@airswap/utils": "4.2.9", + "@airswap/utils": "4.2.10", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index 087a31e6a..9219d50fd 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,7 +31,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.9", + "@airswap/utils": "4.2.10", "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, diff --git a/source/registry/package.json b/source/registry/package.json index 3c7dfda8b..1c348de7e 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.9", + "@airswap/utils": "4.2.10", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index 12bda2906..a90474e81 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.9", + "@airswap/utils": "4.2.10", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index b8aa829f4..6f38b1b0f 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -30,7 +30,7 @@ }, "devDependencies": { "@airswap/staking": "4.2.1", - "@airswap/utils": "4.2.9", + "@airswap/utils": "4.2.10", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index 90cdad28c..553127902 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.9", + "@airswap/utils": "4.2.10", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index f2fa66128..ccdc61b96 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.9", + "@airswap/utils": "4.2.10", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 8c4d37e54..2fcb35471 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.12", + "version": "4.2.13", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -29,7 +29,7 @@ "@airswap/staking": "4.2.1", "@airswap/swap": "4.2.1", "@airswap/swap-erc20": "4.2.1", - "@airswap/utils": "4.2.9", + "@airswap/utils": "4.2.10", "@airswap/wrapper": "4.2.1", "browser-or-node": "^2.1.1", "ethers": "^5.7.2", diff --git a/tools/stores/package.json b/tools/stores/package.json index 9aa99c753..4b9f5fade 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/stores", - "version": "4.2.5", + "version": "4.2.6", "description": "AirSwap: Storage for Indexing", "repository": { "type": "git", @@ -22,7 +22,7 @@ "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/utils": "4.2.9", + "@airswap/utils": "4.2.10", "redis": "^4.6.13" }, "devDependencies": { diff --git a/tools/utils/package.json b/tools/utils/package.json index 40b993d92..c4fad2797 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.9", + "version": "4.2.10", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", diff --git a/tools/utils/src/metadata.ts b/tools/utils/src/metadata.ts index 871dc93a7..bdc65ba69 100644 --- a/tools/utils/src/metadata.ts +++ b/tools/utils/src/metadata.ts @@ -290,6 +290,7 @@ const transformERC721ToCollectionToken = ( name: metadata.name || DEFAULT_NAME, description: metadata.description, image: metadata.image?.replace('ipfs://', ipfsUri), + animation_url: metadata.animation_url?.replace('ipfs://', ipfsUri), attributes: (metadata.attributes || []).map( transformErc721TokenAttributeToCollectionTokenAttribute ), @@ -311,8 +312,9 @@ const transformERC1155ToCollectionToken = ( image: (metadata.image_url || metadata.image || '').replace('ipfs://', ipfsUri) || undefined, + animation_url: metadata.animation_url?.replace('ipfs://', ipfsUri), + createdBy: metadata.created_by, attributes: (metadata.attributes || []).map( transformErc1155TokenAttributeToCollectionTokenAttribute ), - createdBy: metadata.created_by, }) diff --git a/tools/utils/src/types.ts b/tools/utils/src/types.ts index 00f26dbab..79cac8b43 100644 --- a/tools/utils/src/types.ts +++ b/tools/utils/src/types.ts @@ -24,10 +24,11 @@ export interface CollectionTokenAttribute { export type CollectionTokenMetadata = { name?: string - image?: string description?: string - attributes?: CollectionTokenAttribute[] + image?: string + animation_url?: string createdBy?: string + attributes?: CollectionTokenAttribute[] } export type CollectionTokenInfo = { From a145565e103578ce5afd5091c78f2a7f1fdaba7c Mon Sep 17 00:00:00 2001 From: don mosites Date: Tue, 27 Feb 2024 09:34:09 +0100 Subject: [PATCH 34/43] @airswap/swap-erc20: swap in solady for openzeppelin (#1293) * @airswap/swap-erc20: swap in solady for openzeppelin * named imports for clarity * Implemented the ECDSA.tryRecover function from solady * add TransferFromFailed error; add transfer integration tests --------- Co-authored-by: Smart Contrart --- source/swap-erc20/contracts/SwapERC20.sol | 110 +++++++++++------- .../contracts/interfaces/INoReturnERC20.sol | 6 - .../contracts/interfaces/ISwapERC20.sol | 3 +- source/swap-erc20/package.json | 2 +- source/swap-erc20/test/SwapERC20.js | 34 +++--- .../swap-erc20/test/SwapERC20Integration.js | 86 ++++++++++---- yarn.lock | 5 + 7 files changed, 159 insertions(+), 87 deletions(-) delete mode 100644 source/swap-erc20/contracts/interfaces/INoReturnERC20.sol diff --git a/source/swap-erc20/contracts/SwapERC20.sol b/source/swap-erc20/contracts/SwapERC20.sol index 20bcd3930..8b0a0503c 100644 --- a/source/swap-erc20/contracts/SwapERC20.sol +++ b/source/swap-erc20/contracts/SwapERC20.sol @@ -1,11 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.23; -import "@openzeppelin/contracts/access/Ownable.sol"; -import "@openzeppelin/contracts/utils/cryptography/EIP712.sol"; -import "@openzeppelin/contracts/utils/cryptography/SignatureChecker.sol"; -import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; -import "./interfaces/INoReturnERC20.sol"; +import { ECDSA } from "solady/src/utils/ECDSA.sol"; +import { EIP712 } from "solady/src/utils/EIP712.sol"; +import { ERC20 } from "solady/src/tokens/ERC20.sol"; +import { Ownable } from "solady/src/auth/Ownable.sol"; +import { SafeTransferLib } from "solady/src/utils/SafeTransferLib.sol"; +import { SignatureCheckerLib } from "solady/src/utils/SignatureCheckerLib.sol"; + import "./interfaces/ISwapERC20.sol"; /** @@ -13,7 +15,8 @@ import "./interfaces/ISwapERC20.sol"; * @notice https://www.airswap.io/ */ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { - using SafeERC20 for IERC20; + uint256 public immutable DOMAIN_CHAIN_ID; + bytes32 public immutable DOMAIN_SEPARATOR; bytes32 public constant ORDER_TYPEHASH = keccak256( @@ -23,12 +26,6 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { ) ); - // Domain name and version for use in EIP712 signatures - string public constant DOMAIN_NAME = "SWAP_ERC20"; - string public constant DOMAIN_VERSION = "4.2"; - uint256 public immutable DOMAIN_CHAIN_ID; - bytes32 public immutable DOMAIN_SEPARATOR; - uint256 public constant FEE_DIVISOR = 10000; uint256 private constant MAX_ERROR_COUNT = 8; uint256 private constant MAX_MAX = 100; @@ -65,15 +62,17 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { address _protocolFeeWallet, uint256 _bonusScale, uint256 _bonusMax - ) EIP712(DOMAIN_NAME, DOMAIN_VERSION) { + ) { if (_protocolFee >= FEE_DIVISOR) revert InvalidFee(); if (_protocolFeeLight >= FEE_DIVISOR) revert InvalidFeeLight(); if (_protocolFeeWallet == address(0)) revert InvalidFeeWallet(); if (_bonusMax > MAX_MAX) revert MaxTooHigh(); if (_bonusScale > MAX_SCALE) revert ScaleTooHigh(); + _initializeOwner(msg.sender); + DOMAIN_CHAIN_ID = block.chainid; - DOMAIN_SEPARATOR = _domainSeparatorV4(); + DOMAIN_SEPARATOR = _domainSeparator(); protocolFee = _protocolFee; protocolFeeLight = _protocolFeeLight; @@ -82,6 +81,21 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { bonusScale = _bonusScale; } + /** + * @notice Return EIP712 domain values + * @return name EIP712 domain name + * @return version EIP712 domain version + */ + function _domainNameAndVersion() + internal + pure + override + returns (string memory name, string memory version) + { + name = "SWAP_ERC20"; + version = "4.2"; + } + /** * @notice Atomic ERC20 Swap * @param recipient address Wallet to receive sender proceeds @@ -125,14 +139,20 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { ); // Transfer token from sender to signer - IERC20(senderToken).safeTransferFrom( + SafeTransferLib.safeTransferFrom( + senderToken, msg.sender, signerWallet, senderAmount ); // Transfer token from signer to recipient - IERC20(signerToken).safeTransferFrom(signerWallet, recipient, signerAmount); + SafeTransferLib.safeTransferFrom( + signerToken, + signerWallet, + recipient, + signerAmount + ); // Calculate and transfer protocol fee _transferProtocolFee(signerToken, signerWallet, signerAmount); @@ -184,14 +204,20 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { ); // Transfer token from sender to signer - IERC20(senderToken).safeTransferFrom( + SafeTransferLib.safeTransferFrom( + senderToken, msg.sender, signerWallet, senderAmount ); // Transfer token from signer to recipient - IERC20(signerToken).safeTransferFrom(signerWallet, recipient, signerAmount); + SafeTransferLib.safeTransferFrom( + signerToken, + signerWallet, + recipient, + signerAmount + ); // Calculate and transfer protocol fee _transferProtocolFee(signerToken, signerWallet, signerAmount); @@ -230,7 +256,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { if (expiry <= block.timestamp) revert OrderExpired(); // Recover the signatory from the hash and signature - address signatory = ecrecover( + address signatory = ECDSA.tryRecover( keccak256( abi.encodePacked( "\x19\x01", // EIP191: Indicates EIP712 @@ -255,9 +281,8 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { r, s ); - // Ensure the signatory is not null - if (signatory == address(0)) revert Unauthorized(); + if (signatory == address(0)) revert SignatureInvalid(); // Ensure the nonce is not yet used and if not mark it used if (!_markNonceAsUsed(signatory, nonce)) revert NonceAlreadyUsed(nonce); @@ -265,28 +290,31 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { // Ensure signatory is authorized to sign if (authorized[signerWallet] != address(0)) { // If one is set by signer wallet, signatory must be authorized - if (signatory != authorized[signerWallet]) revert Unauthorized(); + if (signatory != authorized[signerWallet]) revert SignatureInvalid(); } else { // Otherwise, signatory must be signer wallet - if (signatory != signerWallet) revert Unauthorized(); + if (signatory != signerWallet) revert SignatureInvalid(); } // Transfer token from sender to signer - INoReturnERC20(senderToken).transferFrom( + SafeTransferLib.safeTransferFrom( + senderToken, msg.sender, signerWallet, senderAmount ); // Transfer token from signer to sender - INoReturnERC20(signerToken).transferFrom( + SafeTransferLib.safeTransferFrom( + signerToken, signerWallet, msg.sender, signerAmount ); // Transfer protocol fee from signer to fee wallet - INoReturnERC20(signerToken).transferFrom( + SafeTransferLib.safeTransferFrom( + signerToken, signerWallet, protocolFeeWallet, (signerAmount * protocolFeeLight) / FEE_DIVISOR @@ -457,7 +485,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { } if ( - !SignatureChecker.isValidSignatureNow( + !SignatureCheckerLib.isValidSignatureNow( signatory, _getOrderHash( order.nonce, @@ -472,7 +500,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { abi.encodePacked(r, s, v) ) ) { - errors[count++] = "Unauthorized"; + errors[count++] = "SignatureInvalid"; } else if (nonceUsed(signatory, order.nonce)) { errors[count++] = "NonceAlreadyUsed"; } @@ -482,11 +510,12 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { } if (order.senderWallet != address(0)) { - uint256 senderBalance = IERC20(order.senderToken).balanceOf( + uint256 senderBalance = SafeTransferLib.balanceOf( + order.senderToken, order.senderWallet ); - uint256 senderAllowance = IERC20(order.senderToken).allowance( + uint256 senderAllowance = ERC20(order.senderToken).allowance( order.senderWallet, address(this) ); @@ -500,11 +529,11 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { } } - uint256 signerBalance = IERC20(order.signerToken).balanceOf( + uint256 signerBalance = ERC20(order.signerToken).balanceOf( order.signerWallet ); - uint256 signerAllowance = IERC20(order.signerToken).allowance( + uint256 signerAllowance = ERC20(order.signerToken).allowance( order.signerWallet, address(this) ); @@ -555,7 +584,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { uint256 feeAmount = (amount * protocolFee) / FEE_DIVISOR; if (stakingToken != address(0) && feeAmount > 0) { uint256 bonusAmount = calculateBonus( - IERC20(stakingToken).balanceOf(wallet), + ERC20(stakingToken).balanceOf(wallet), feeAmount ); return feeAmount - bonusAmount; @@ -641,7 +670,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { // Ensure the signature is correct for the order if ( - !SignatureChecker.isValidSignatureNow( + !SignatureCheckerLib.isValidSignatureNow( signatory, _getOrderHash( nonce, @@ -655,7 +684,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { ), abi.encodePacked(r, s, v) ) - ) revert Unauthorized(); + ) revert SignatureInvalid(); // Ensure the nonce is not yet used and if not mark as used if (!_markNonceAsUsed(signatory, nonce)) revert NonceAlreadyUsed(nonce); @@ -723,25 +752,28 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { if (stakingToken != address(0)) { // Only check bonus if staking is set bonusAmount = calculateBonus( - IERC20(stakingToken).balanceOf(msg.sender), + SafeTransferLib.balanceOf(stakingToken, msg.sender), feeAmount ); } if (bonusAmount > 0) { // Transfer fee from signer to sender - IERC20(sourceToken).safeTransferFrom( + SafeTransferLib.safeTransferFrom( + sourceToken, sourceWallet, msg.sender, bonusAmount ); // Transfer fee from signer to feeWallet - IERC20(sourceToken).safeTransferFrom( + SafeTransferLib.safeTransferFrom( + sourceToken, sourceWallet, protocolFeeWallet, feeAmount - bonusAmount ); } else { - IERC20(sourceToken).safeTransferFrom( + SafeTransferLib.safeTransferFrom( + sourceToken, sourceWallet, protocolFeeWallet, feeAmount diff --git a/source/swap-erc20/contracts/interfaces/INoReturnERC20.sol b/source/swap-erc20/contracts/interfaces/INoReturnERC20.sol deleted file mode 100644 index b57329fc7..000000000 --- a/source/swap-erc20/contracts/interfaces/INoReturnERC20.sol +++ /dev/null @@ -1,6 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity 0.8.23; - -interface INoReturnERC20 { - function transferFrom(address from, address to, uint256 value) external; -} diff --git a/source/swap-erc20/contracts/interfaces/ISwapERC20.sol b/source/swap-erc20/contracts/interfaces/ISwapERC20.sol index 95b5ed2a6..70a62308f 100644 --- a/source/swap-erc20/contracts/interfaces/ISwapERC20.sol +++ b/source/swap-erc20/contracts/interfaces/ISwapERC20.sol @@ -38,7 +38,8 @@ interface ISwapERC20 { error NonceAlreadyUsed(uint256); error ScaleTooHigh(); error SignatoryInvalid(); - error Unauthorized(); + error SignatureInvalid(); + error TransferFromFailed(); function swap( address recipient, diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index 6f38b1b0f..540c2dc36 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -26,7 +26,7 @@ "owners": "hardhat run ./scripts/owner.js" }, "dependencies": { - "@openzeppelin/contracts": "^4.8.3" + "solady": "0.0.172" }, "devDependencies": { "@airswap/staking": "4.2.1", diff --git a/source/swap-erc20/test/SwapERC20.js b/source/swap-erc20/test/SwapERC20.js index bb312982d..e0084068b 100644 --- a/source/swap-erc20/test/SwapERC20.js +++ b/source/swap-erc20/test/SwapERC20.js @@ -255,7 +255,7 @@ describe('SwapERC20 Unit', () => { it('test setProtocolFee as non-owner', async () => { await expect( swap.connect(anyone).setProtocolFee(FEE_DIVISOR) - ).to.be.revertedWith('Ownable: caller is not the owner') + ).to.be.revertedWith('Unauthorized') }) it('test setProtocolFeeLight', async () => { await expect( @@ -270,7 +270,7 @@ describe('SwapERC20 Unit', () => { it('test setProtocolFeeLight as non-owner', async () => { await expect( swap.connect(anyone).setProtocolFeeLight(FEE_DIVISOR) - ).to.be.revertedWith('Ownable: caller is not the owner') + ).to.be.revertedWith('Unauthorized') }) it('test protocolFeeWallet', async () => { await expect( @@ -291,7 +291,7 @@ describe('SwapERC20 Unit', () => { it('test setBonusScale as non-owner', async () => { await expect( swap.connect(anyone).setBonusScale(BONUS_SCALE) - ).to.be.revertedWith('Ownable: caller is not the owner') + ).to.be.revertedWith('Unauthorized') }) it('test setBonusMax', async () => { await expect(await swap.connect(deployer).setBonusMax(BONUS_MAX)).to.emit( @@ -307,7 +307,7 @@ describe('SwapERC20 Unit', () => { it('test setBonusMax as non-owner', async () => { await expect( swap.connect(anyone).setBonusMax(BONUS_MAX) - ).to.be.revertedWith('Ownable: caller is not the owner') + ).to.be.revertedWith('Unauthorized') }) it('test setStaking', async () => { await expect(swap.connect(deployer).setStaking(staking.address)).to.emit( @@ -421,7 +421,7 @@ describe('SwapERC20 Unit', () => { await expect( swap.connect(sender).swap(sender.address, ...order) - ).to.be.revertedWith('Unauthorized') + ).to.be.revertedWith('SignatureInvalid') }) it('test when signer not authorized', async () => { @@ -434,7 +434,7 @@ describe('SwapERC20 Unit', () => { await expect( swap.connect(sender).swap(sender.address, ...order) - ).to.be.revertedWith('Unauthorized') + ).to.be.revertedWith('SignatureInvalid') }) it('test when order is expired', async () => { @@ -484,7 +484,7 @@ describe('SwapERC20 Unit', () => { await expect( swap.connect(sender).swap(sender.address, ...order) - ).to.be.revertedWith('Unauthorized') + ).to.be.revertedWith('SignatureInvalid') }) }) @@ -524,7 +524,7 @@ describe('SwapERC20 Unit', () => { await expect( swap.connect(sender).swapAnySender(sender.address, ...order) - ).to.be.revertedWith('Unauthorized') + ).to.be.revertedWith('SignatureInvalid') }) it('test when order is expired', async () => { @@ -570,7 +570,7 @@ describe('SwapERC20 Unit', () => { order[7] = '29' // Change "v" of signature await expect( swap.connect(sender).swapAnySender(sender.address, ...order) - ).to.be.revertedWith('Unauthorized') + ).to.be.revertedWith('SignatureInvalid') }) }) @@ -621,7 +621,7 @@ describe('SwapERC20 Unit', () => { .withArgs(signer.address, anyone.address) await expect(swap.connect(sender).swapLight(...order)).to.be.revertedWith( - 'Unauthorized' + 'SignatureInvalid' ) }) it('test when expiration has passed', async () => { @@ -641,7 +641,7 @@ describe('SwapERC20 Unit', () => { const order = await createSignedOrderERC20({}, signer) order[7] = '29' // Change "v" of signature await expect(swap.connect(sender).swapLight(...order)).to.be.revertedWith( - 'Unauthorized' + 'SignatureInvalid' ) }) it('test when nonce has already been used', async () => { @@ -666,7 +666,7 @@ describe('SwapERC20 Unit', () => { anyone ) await expect(swap.connect(sender).swapLight(...order)).to.be.revertedWith( - 'Unauthorized' + 'SignatureInvalid' ) }) }) @@ -682,7 +682,7 @@ describe('SwapERC20 Unit', () => { it('test only deployer can change fee wallet', async () => { await expect( swap.connect(anyone).setProtocolFeeWallet(anyone.address) - ).to.be.revertedWith('Ownable: caller is not the owner') + ).to.be.revertedWith('Unauthorized') }) it('test invalid fee wallet', async () => { @@ -700,7 +700,7 @@ describe('SwapERC20 Unit', () => { it('test only deployer can change fee', async () => { await expect(swap.connect(anyone).setProtocolFee('0')).to.be.revertedWith( - 'Ownable: caller is not the owner' + 'Unauthorized' ) }) @@ -733,7 +733,7 @@ describe('SwapERC20 Unit', () => { ) await expect( swap.connect(sender).swap(sender.address, ...order) - ).to.be.revertedWith('Unauthorized') + ).to.be.revertedWith('SignatureInvalid') }) }) @@ -741,7 +741,7 @@ describe('SwapERC20 Unit', () => { it('test set staking by non-owner', async () => { await expect( swap.connect(anyone).setStaking(staking.address) - ).to.be.revertedWith('Ownable: caller is not the owner') + ).to.be.revertedWith('Unauthorized') }) it('test set staking', async () => { @@ -842,7 +842,7 @@ describe('SwapERC20 Unit', () => { const order = await createSignedOrderERC20({}, anyone) const errors = await checkForErrors(order) expect(errors).to.include( - ethers.utils.formatBytes32String('Unauthorized') + ethers.utils.formatBytes32String('SignatureInvalid') ) }) it('test with low signer allowance', async () => { diff --git a/source/swap-erc20/test/SwapERC20Integration.js b/source/swap-erc20/test/SwapERC20Integration.js index b78305dc1..dd1d9f23a 100644 --- a/source/swap-erc20/test/SwapERC20Integration.js +++ b/source/swap-erc20/test/SwapERC20Integration.js @@ -26,6 +26,8 @@ describe('SwapERC20 Integration', () => { const PROTOCOL_FEE = '30' const PROTOCOL_FEE_LIGHT = '7' const DEFAULT_AMOUNT = '10000' + const MINT_AMOUNT = '1000000' + const STAKE_AMOUNT = '10000000000' async function createSignedOrder(params, signer) { const unsignedOrder = createOrderERC20({ @@ -64,7 +66,7 @@ describe('SwapERC20 Integration', () => { await ethers.getContractFactory(ERC20.abi, ERC20.bytecode) ).deploy('Staking', 'STAKE') await stakingToken.deployed() - await stakingToken.mint(sender.address, 10000000000) + await stakingToken.mint(sender.address, STAKE_AMOUNT) staking = await ( await ethers.getContractFactory(STAKING.abi, STAKING.bytecode) @@ -75,13 +77,11 @@ describe('SwapERC20 Integration', () => { await ethers.getContractFactory(ERC20.abi, ERC20.bytecode) ).deploy('A', 'A') await signerToken.deployed() - await signerToken.mint(signer.address, 1000000) senderToken = await ( await ethers.getContractFactory(ERC20.abi, ERC20.bytecode) ).deploy('B', 'B') await senderToken.deployed() - await senderToken.mint(sender.address, 1000000) swap = await ( await ethers.getContractFactory('SwapERC20') @@ -93,33 +93,63 @@ describe('SwapERC20 Integration', () => { BONUS_MAX ) await swap.deployed() - - signerToken.connect(signer).approve(swap.address, 1000000) - senderToken.connect(sender).approve(swap.address, 1000000) }) describe('Test token holder bonuss', async () => { - it('test swap without staking', async () => { + it('swap fails without sender balance', async () => { + await signerToken.mint(signer.address, MINT_AMOUNT) + signerToken.connect(signer).approve(swap.address, MINT_AMOUNT) + senderToken.connect(sender).approve(swap.address, MINT_AMOUNT) + const order = await createSignedOrder({}, signer) - await expect(swap.connect(sender).swap(sender.address, ...order)).to.emit( - swap, - 'SwapERC20' - ) + await expect( + swap.connect(sender).swap(sender.address, ...order) + ).to.be.revertedWith('TransferFromFailed') + }) - // Expect full 30 to be taken from signer - expect(await signerToken.balanceOf(signer.address)).to.equal('989970') + it('swap fails without sender allowance', async () => { + await signerToken.mint(signer.address, MINT_AMOUNT) + await senderToken.mint(sender.address, MINT_AMOUNT) + signerToken.connect(signer).approve(swap.address, MINT_AMOUNT) - // Expect full amount to have been sent to sender - expect(await signerToken.balanceOf(sender.address)).to.equal('10000') + const order = await createSignedOrder({}, signer) - // Expect full fee to have been sent to fee wallet - expect(await signerToken.balanceOf(protocolFeeWallet.address)).to.equal( - '30' - ) + await expect( + swap.connect(sender).swap(sender.address, ...order) + ).to.be.revertedWith('TransferFromFailed') + }) + + it('swap fails without signer balance', async () => { + await senderToken.mint(sender.address, MINT_AMOUNT) + signerToken.connect(signer).approve(swap.address, MINT_AMOUNT) + senderToken.connect(sender).approve(swap.address, MINT_AMOUNT) + + const order = await createSignedOrder({}, signer) + + await expect( + swap.connect(sender).swap(sender.address, ...order) + ).to.be.revertedWith('TransferFromFailed') + }) + + it('swap fails without signer allowance', async () => { + await signerToken.mint(signer.address, MINT_AMOUNT) + await senderToken.mint(sender.address, MINT_AMOUNT) + senderToken.connect(sender).approve(swap.address, MINT_AMOUNT) + + const order = await createSignedOrder({}, signer) + + await expect( + swap.connect(sender).swap(sender.address, ...order) + ).to.be.revertedWith('TransferFromFailed') }) - it('test swap without bonus', async () => { + it('swap succeeds, no staking bonus', async () => { + await signerToken.mint(signer.address, MINT_AMOUNT) + await senderToken.mint(sender.address, MINT_AMOUNT) + signerToken.connect(signer).approve(swap.address, MINT_AMOUNT) + senderToken.connect(sender).approve(swap.address, MINT_AMOUNT) + const order = await createSignedOrder({}, signer) await expect(swap.connect(sender).swap(sender.address, ...order)).to.emit( @@ -139,9 +169,14 @@ describe('SwapERC20 Integration', () => { ) }) - it('test swap with bonus', async () => { - await stakingToken.connect(sender).approve(staking.address, 10000000000) - await staking.connect(sender).stake(10000000000) + it('swap succeeds, staking bonus', async () => { + await signerToken.mint(signer.address, MINT_AMOUNT) + await senderToken.mint(sender.address, MINT_AMOUNT) + signerToken.connect(signer).approve(swap.address, MINT_AMOUNT) + senderToken.connect(sender).approve(swap.address, MINT_AMOUNT) + + await stakingToken.connect(sender).approve(staking.address, STAKE_AMOUNT) + await staking.connect(sender).stake(STAKE_AMOUNT) await expect(swap.connect(deployer).setStaking(staking.address)).to.emit( swap, @@ -167,6 +202,11 @@ describe('SwapERC20 Integration', () => { }) it('test light swap', async () => { + await signerToken.mint(signer.address, MINT_AMOUNT) + await senderToken.mint(sender.address, MINT_AMOUNT) + signerToken.connect(signer).approve(swap.address, MINT_AMOUNT) + senderToken.connect(sender).approve(swap.address, MINT_AMOUNT) + const order = await createSignedOrder( { protocolFee: PROTOCOL_FEE_LIGHT, diff --git a/yarn.lock b/yarn.lock index 06b7748b3..92d0a8db2 100644 --- a/yarn.lock +++ b/yarn.lock @@ -9448,6 +9448,11 @@ socks@^2.6.2: ip "^2.0.0" smart-buffer "^4.2.0" +solady@0.0.172: + version "0.0.172" + resolved "https://registry.yarnpkg.com/solady/-/solady-0.0.172.tgz#aea9071c1ba41d805c74c9423201173b8d05246c" + integrity sha512-8YkQr78PuaGKb1jWQzVgLcCtAOYXc6Xczh/wB6YUEZO/ioidzbGYoFSmYCA1nN0Ln+K9+NZSqDhyuyv/q4N8XQ== + solc@0.7.3: version "0.7.3" resolved "https://registry.yarnpkg.com/solc/-/solc-0.7.3.tgz#04646961bd867a744f63d2b4e3c0701ffdc7d78a" From 7b0e8ea486ae377701c02e76fb7fc40757476d8f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 27 Feb 2024 09:36:48 +0100 Subject: [PATCH 35/43] Bump es5-ext from 0.10.62 to 0.10.63 (#1294) Bumps [es5-ext](https://github.com/medikoo/es5-ext) from 0.10.62 to 0.10.63. - [Release notes](https://github.com/medikoo/es5-ext/releases) - [Changelog](https://github.com/medikoo/es5-ext/blob/main/CHANGELOG.md) - [Commits](https://github.com/medikoo/es5-ext/compare/v0.10.62...v0.10.63) --- updated-dependencies: - dependency-name: es5-ext dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/yarn.lock b/yarn.lock index 92d0a8db2..f016b6e11 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4235,13 +4235,14 @@ es-to-primitive@^1.2.1: is-date-object "^1.0.1" is-symbol "^1.0.2" -es5-ext@^0.10.35, es5-ext@^0.10.50: - version "0.10.62" - resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.62.tgz#5e6adc19a6da524bf3d1e02bbc8960e5eb49a9a5" - integrity sha512-BHLqn0klhEpnOKSrzn/Xsz2UIW8j+cGmo9JLzr8BiUapV8hPL9+FliFqjwr9ngW7jWdnxv6eO+/LqyhJVqgrjA== +es5-ext@^0.10.35, es5-ext@^0.10.50, es5-ext@^0.10.62, es5-ext@~0.10.14: + version "0.10.63" + resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.63.tgz#9c222a63b6a332ac80b1e373b426af723b895bd6" + integrity sha512-hUCZd2Byj/mNKjfP9jXrdVZ62B8KuA/VoK7X8nUh5qT+AxDmcbvZz041oDVZdbIN1qW6XY9VDNwzkvKnZvK2TQ== dependencies: es6-iterator "^2.0.3" es6-symbol "^3.1.3" + esniff "^2.0.1" next-tick "^1.1.0" es6-iterator@^2.0.3: @@ -4384,6 +4385,16 @@ eslint@^8.20.0: strip-json-comments "^3.1.0" text-table "^0.2.0" +esniff@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/esniff/-/esniff-2.0.1.tgz#a4d4b43a5c71c7ec51c51098c1d8a29081f9b308" + integrity sha512-kTUIGKQ/mDPFoJ0oVfcmyJn4iBDRptjNVIzwIFR7tqWXdVI9xfA2RMwY/gbSpJG3lkdWNEjLap/NqVHZiJsdfg== + dependencies: + d "^1.0.1" + es5-ext "^0.10.62" + event-emitter "^0.3.5" + type "^2.7.2" + espree@^9.5.1: version "9.5.1" resolved "https://registry.yarnpkg.com/espree/-/espree-9.5.1.tgz#4f26a4d5f18905bf4f2e0bd99002aab807e96dd4" @@ -4633,6 +4644,14 @@ ethjs-util@0.1.6, ethjs-util@^0.1.6: is-hex-prefixed "1.0.0" strip-hex-prefix "1.0.0" +event-emitter@^0.3.5: + version "0.3.5" + resolved "https://registry.yarnpkg.com/event-emitter/-/event-emitter-0.3.5.tgz#df8c69eef1647923c7157b9ce83840610b02cc39" + integrity sha512-D9rRn9y7kLPnJ+hMq7S/nhvoKwwvVJahBi2BPmx3bvbsEdK3W9ii8cBSGjP+72/LnM4n6fo3+dkCX5FeTQruXA== + dependencies: + d "1" + es5-ext "~0.10.14" + eventemitter3@^4.0.4: version "4.0.7" resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.7.tgz#2de9b68f6528d5644ef5c59526a1b4a07306169f" From 27b60da16f2504878c458643db71a4c0c08ca6e4 Mon Sep 17 00:00:00 2001 From: don mosites Date: Thu, 29 Feb 2024 21:36:31 +0100 Subject: [PATCH 36/43] @airswap/swap-erc20: use ERC20 for all balanceOf calls (#1296) --- source/swap-erc20/contracts/SwapERC20.sol | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/source/swap-erc20/contracts/SwapERC20.sol b/source/swap-erc20/contracts/SwapERC20.sol index 8b0a0503c..bf8f0e783 100644 --- a/source/swap-erc20/contracts/SwapERC20.sol +++ b/source/swap-erc20/contracts/SwapERC20.sol @@ -510,8 +510,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { } if (order.senderWallet != address(0)) { - uint256 senderBalance = SafeTransferLib.balanceOf( - order.senderToken, + uint256 senderBalance = ERC20(order.senderToken).balanceOf( order.senderWallet ); @@ -752,7 +751,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { if (stakingToken != address(0)) { // Only check bonus if staking is set bonusAmount = calculateBonus( - SafeTransferLib.balanceOf(stakingToken, msg.sender), + ERC20(stakingToken).balanceOf(msg.sender), feeAmount ); } From a0b45d4ab68652f0328aa7444409ddd50d916464 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Mar 2024 10:05:02 +0100 Subject: [PATCH 37/43] Bump @openzeppelin/contracts from 4.9.3 to 4.9.6 (#1297) Bumps [@openzeppelin/contracts](https://github.com/OpenZeppelin/openzeppelin-contracts) from 4.9.3 to 4.9.6. - [Release notes](https://github.com/OpenZeppelin/openzeppelin-contracts/releases) - [Changelog](https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/CHANGELOG.md) - [Commits](https://github.com/OpenZeppelin/openzeppelin-contracts/compare/v4.9.3...v4.9.6) --- updated-dependencies: - dependency-name: "@openzeppelin/contracts" dependency-type: direct:production ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index f016b6e11..70655ff2d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1472,9 +1472,9 @@ "@octokit/openapi-types" "^18.0.0" "@openzeppelin/contracts@^4.8.3": - version "4.9.3" - resolved "https://registry.yarnpkg.com/@openzeppelin/contracts/-/contracts-4.9.3.tgz#00d7a8cf35a475b160b3f0293a6403c511099364" - integrity sha512-He3LieZ1pP2TNt5JbkPA4PNT9WC3gOTOlDcFGJW4Le4QKqwmiNJCRt44APfxMxvq7OugU/cqYuPcSBzOw38DAg== + version "4.9.6" + resolved "https://registry.yarnpkg.com/@openzeppelin/contracts/-/contracts-4.9.6.tgz#2a880a24eb19b4f8b25adc2a5095f2aa27f39677" + integrity sha512-xSmezSupL+y9VkHZJGDoCBpmnB2ogM13ccaYDWqJTfS3dbuHkgjuwDFUmaFauBCboQMGB/S5UqUl2y54X99BmA== "@parcel/watcher@2.0.4": version "2.0.4" From 8870acc9b7241bc6d5bb7a1e094ddb37d2d2a927 Mon Sep 17 00:00:00 2001 From: don mosites Date: Fri, 1 Mar 2024 18:31:53 +0100 Subject: [PATCH 38/43] swap-erc20 mainnets deploy, others to follow; dep upgrades (#1298) * workspace dep updates; upgrades * upgrade @typescript-eslint packages * upgrade to solady@0.0.173 * update natspec for clarity * clear deploys for swap-erc20 * 4.3 mainnet swap-erc20 deploy; others to follow --- hardhat.config.js | 2 +- package.json | 18 +- source/batch-call/package.json | 4 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/contracts/SwapERC20.sol | 13 +- source/swap-erc20/deploys-blocks.js | 24 +- source/swap-erc20/deploys.js | 24 +- source/swap-erc20/package.json | 6 +- source/swap/package.json | 2 +- source/wrapper/package.json | 4 +- tools/libraries/package.json | 6 +- tools/stores/package.json | 2 +- tools/utils/package.json | 2 +- tools/utils/src/constants.ts | 3 +- yarn.lock | 3463 ++++++++------------- 17 files changed, 1391 insertions(+), 2188 deletions(-) diff --git a/hardhat.config.js b/hardhat.config.js index e131bd3c9..dbe707969 100644 --- a/hardhat.config.js +++ b/hardhat.config.js @@ -2,7 +2,7 @@ require('dotenv').config({ path: '../../.env' }) require('@typechain/hardhat') require('@nomiclabs/hardhat-ethers') require('@nomiclabs/hardhat-waffle') -require('@nomiclabs/hardhat-etherscan') +require('@nomicfoundation/hardhat-verify') require('hardhat-gas-reporter') require('solidity-coverage') diff --git a/package.json b/package.json index bc64507f0..a8b37c076 100644 --- a/package.json +++ b/package.json @@ -23,18 +23,20 @@ "prettier": "prettier --write \"./**/*.sol\" \"./**/*.ts\" \"./**/*.js\" \"./**/*.json\"" }, "devDependencies": { + "@ensdomains/ens": "^0.4.4", + "@ensdomains/resolver": "^0.2.4", "@ethersproject/abi": "^5.7.0", - "@ethersproject/bytes": "^5.7.0", "@ethersproject/providers": "^5.7.2", - "@nomiclabs/hardhat-ethers": "^2.1.0", - "@nomiclabs/hardhat-etherscan": "^3.1.0", - "@nomiclabs/hardhat-waffle": "^2.0.3", - "@typechain/ethers-v5": "^10.2.0", - "@typechain/hardhat": "^6.1.5", + "@nomicfoundation/hardhat-verify": "^2.0.4", + "@nomiclabs/hardhat-ethers": "^2.2.3", + "@nomiclabs/hardhat-waffle": "^2.0.6", + "@typechain/ethers-v5": "^11.1.2", + "@typechain/hardhat": "^7.0.0", "@types/mocha": "^10.0.1", "@types/node": "^18.15.11", - "@typescript-eslint/eslint-plugin": "^5.58.0", - "@typescript-eslint/parser": "^5.58.0", + "@types/sinon-chai": "^3.2.12", + "@typescript-eslint/eslint-plugin": "^7.1.0", + "@typescript-eslint/parser": "^7.1.0", "chai": "^4.3.6", "dotenv": "^16.0.1", "eslint": "^8.20.0", diff --git a/source/batch-call/package.json b/source/batch-call/package.json index e4a722e3c..4b5e6e84f 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -28,10 +28,10 @@ "dependencies": { "@openzeppelin/contracts": "^4.8.3", "@airswap/swap": "4.2.1", - "@airswap/swap-erc20": "4.2.1" + "@airswap/swap-erc20": "4.3.0" }, "devDependencies": { - "@airswap/utils": "4.2.10", + "@airswap/utils": "4.3.0", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index 9219d50fd..f1a481b3a 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -31,7 +31,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.10", + "@airswap/utils": "4.3.0", "@airswap/merkle": "0.0.2", "prompt-confirm": "^2.0.4" }, diff --git a/source/registry/package.json b/source/registry/package.json index 1c348de7e..72e8ea5f1 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.10", + "@airswap/utils": "4.3.0", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index a90474e81..4f88bd0de 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -32,7 +32,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.2.10", + "@airswap/utils": "4.3.0", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/contracts/SwapERC20.sol b/source/swap-erc20/contracts/SwapERC20.sol index bf8f0e783..4b8720297 100644 --- a/source/swap-erc20/contracts/SwapERC20.sol +++ b/source/swap-erc20/contracts/SwapERC20.sol @@ -93,7 +93,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { returns (string memory name, string memory version) { name = "SWAP_ERC20"; - version = "4.2"; + version = "4.3"; } /** @@ -734,7 +734,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { } /** - * @notice Calculates and transfers protocol fee and bonus + * @notice Calculates and transfers protocol fee and staking bonus * @param sourceToken address * @param sourceWallet address * @param amount uint256 @@ -744,26 +744,26 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { address sourceWallet, uint256 amount ) private { - // Transfer fee from signer to feeWallet + // Determine protocol fee from amount uint256 feeAmount = (amount * protocolFee) / FEE_DIVISOR; if (feeAmount > 0) { uint256 bonusAmount; if (stakingToken != address(0)) { - // Only check bonus if staking is set + // Only check staking bonus if staking token set bonusAmount = calculateBonus( ERC20(stakingToken).balanceOf(msg.sender), feeAmount ); } if (bonusAmount > 0) { - // Transfer fee from signer to sender + // Transfer staking bonus from source to msg.sender SafeTransferLib.safeTransferFrom( sourceToken, sourceWallet, msg.sender, bonusAmount ); - // Transfer fee from signer to feeWallet + // Transfer remaining protocol fee from source to fee wallet SafeTransferLib.safeTransferFrom( sourceToken, sourceWallet, @@ -771,6 +771,7 @@ contract SwapERC20 is ISwapERC20, Ownable, EIP712 { feeAmount - bonusAmount ); } else { + // Transfer full protocol fee from source to fee wallet SafeTransferLib.safeTransferFrom( sourceToken, sourceWallet, diff --git a/source/swap-erc20/deploys-blocks.js b/source/swap-erc20/deploys-blocks.js index 6f2bbd9da..dffb6818b 100644 --- a/source/swap-erc20/deploys-blocks.js +++ b/source/swap-erc20/deploys-blocks.js @@ -1,20 +1,8 @@ module.exports = { - 1: 19169050, - 31: 4776706, - 41: 280828324, - 56: 35875262, - 97: 37474882, - 137: 53160880, - 8453: 10229426, - 17000: 882207, - 42161: 178077878, - 43113: 29751054, - 43114: 41340140, - 59140: 3401119, - 59144: 2075514, - 80001: 45572097, - 84532: 5684322, - 421613: 61943880, - 421614: 11892510, - 11155111: 5224921, + 1: 19341464, + 56: 36593146, + 137: 54144778, + 43114: 42345669, + 59144: 2613444, + 11155111: 5395281, } diff --git a/source/swap-erc20/deploys.js b/source/swap-erc20/deploys.js index f105bcbe8..18ca0ce44 100644 --- a/source/swap-erc20/deploys.js +++ b/source/swap-erc20/deploys.js @@ -1,20 +1,8 @@ module.exports = { - 1: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 31: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 41: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 56: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 97: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 137: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 8453: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 17000: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 42161: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 43113: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 43114: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 59140: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 59144: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 80001: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 84532: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 421613: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 421614: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', - 11155111: '0xD82a5ff379f20fc45e213F4ee1D1FCF47545665e', + 1: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 56: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 137: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 43114: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 59144: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 11155111: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index 540c2dc36..bca7624c8 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/swap-erc20", - "version": "4.2.1", + "version": "4.3.0", "description": "AirSwap: Atomic ERC20 Token Swap", "license": "MIT", "repository": { @@ -26,11 +26,11 @@ "owners": "hardhat run ./scripts/owner.js" }, "dependencies": { - "solady": "0.0.172" + "solady": "0.0.173" }, "devDependencies": { "@airswap/staking": "4.2.1", - "@airswap/utils": "4.2.10", + "@airswap/utils": "4.3.0", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/swap/package.json b/source/swap/package.json index 553127902..8d1f95bef 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -32,7 +32,7 @@ "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.10", + "@airswap/utils": "4.3.0", "@nomicfoundation/hardhat-network-helpers": "^1.0.7" }, "publishConfig": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index ccdc61b96..dc6dae7e3 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -28,11 +28,11 @@ "owners": "hardhat run ./scripts/owner.js" }, "dependencies": { - "@airswap/swap-erc20": "4.2.1", + "@airswap/swap-erc20": "4.3.0", "@openzeppelin/contracts": "^4.8.3" }, "devDependencies": { - "@airswap/utils": "4.2.10", + "@airswap/utils": "4.3.0", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 2fcb35471..64d1ee9de 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.2.13", + "version": "4.3.0", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -28,8 +28,8 @@ "@airswap/pool": "4.2.1", "@airswap/staking": "4.2.1", "@airswap/swap": "4.2.1", - "@airswap/swap-erc20": "4.2.1", - "@airswap/utils": "4.2.10", + "@airswap/swap-erc20": "4.3.0", + "@airswap/utils": "4.3.0", "@airswap/wrapper": "4.2.1", "browser-or-node": "^2.1.1", "ethers": "^5.7.2", diff --git a/tools/stores/package.json b/tools/stores/package.json index 4b9f5fade..a04105467 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -22,7 +22,7 @@ "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/utils": "4.2.10", + "@airswap/utils": "4.3.0", "redis": "^4.6.13" }, "devDependencies": { diff --git a/tools/utils/package.json b/tools/utils/package.json index c4fad2797..e46aaa52f 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.2.10", + "version": "4.3.0", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", diff --git a/tools/utils/src/constants.ts b/tools/utils/src/constants.ts index f213c62bf..820b0222d 100644 --- a/tools/utils/src/constants.ts +++ b/tools/utils/src/constants.ts @@ -1,5 +1,5 @@ export const DOMAIN_NAME_SWAP_ERC20 = 'SWAP_ERC20' -export const DOMAIN_VERSION_SWAP_ERC20 = '4.2' +export const DOMAIN_VERSION_SWAP_ERC20 = '4.3' export const DOMAIN_NAME_SWAP = 'SWAP' export const DOMAIN_VERSION_SWAP = '4.2' export const ADDRESS_ZERO = '0x0000000000000000000000000000000000000000' @@ -239,6 +239,7 @@ export const ownerAddresses: Record = { [ChainIds.ARBITRUM]: '0xed669F5fe2A37Ef204DB178c7a982717B9f03Ec2', [ChainIds.AVALANCHE]: '0xed669F5fe2A37Ef204DB178c7a982717B9f03Ec2', [ChainIds.LINEA]: '0xed669F5fe2A37Ef204DB178c7a982717B9f03Ec2', + [ChainIds.SEPOLIA]: '0xed669F5fe2A37Ef204DB178c7a982717B9f03Ec2', } export const protocolFeeReceiverAddresses: Record = { diff --git a/yarn.lock b/yarn.lock index 70655ff2d..b640fa052 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,11 @@ # yarn lockfile v1 +"@aashutoshrathi/word-wrap@^1.2.3": + version "1.2.6" + resolved "https://registry.yarnpkg.com/@aashutoshrathi/word-wrap/-/word-wrap-1.2.6.tgz#bd9154aec9983f77b3a034ecaa015c2e4201f6cf" + integrity sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA== + "@airswap/jsonrpc-client-websocket@0.0.1": version "0.0.1" resolved "https://registry.yarnpkg.com/@airswap/jsonrpc-client-websocket/-/jsonrpc-client-websocket-0.0.1.tgz#e75932a0f19cb6c23cf145834277211cce150400" @@ -19,62 +24,27 @@ web3-utils "^1.3.1" "@babel/code-frame@^7.0.0": - version "7.21.4" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.21.4.tgz#d0fa9e4413aca81f2b23b9442797bda1826edb39" - integrity sha512-LYvhNKfwWSPpocw8GI7gpK2nq3HSDuEPC/uSYaALSJu9xjsalaaYFOq0Pwt5KmVqwEbZlDu81aLXwBOmD/Fv9g== + version "7.23.5" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.23.5.tgz#9009b69a8c602293476ad598ff53e4562e15c244" + integrity sha512-CgH3s1a96LipHCmSUmYFPwY7MNx8C3avkq7i4Wl3cfa662ldtUe4VM1TPXX70pfmrlWTb6jLqTYrZyT2ZTJBgA== dependencies: - "@babel/highlight" "^7.18.6" + "@babel/highlight" "^7.23.4" + chalk "^2.4.2" -"@babel/helper-validator-identifier@^7.18.6": - version "7.19.1" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz#7eea834cf32901ffdc1a7ee555e2f9c27e249ca2" - integrity sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w== +"@babel/helper-validator-identifier@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz#c4ae002c61d2879e724581d96665583dbc1dc0e0" + integrity sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A== -"@babel/highlight@^7.18.6": - version "7.18.6" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.18.6.tgz#81158601e93e2563795adcbfbdf5d64be3f2ecdf" - integrity sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g== +"@babel/highlight@^7.23.4": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.23.4.tgz#edaadf4d8232e1a961432db785091207ead0621b" + integrity sha512-acGdbYSfp2WheJoJm/EBBBLh/ID8KDc64ISZ9DYtBmC8/Q204PZJLHyzeB5qMzJ5trcOkybd78M4x2KWsUq++A== dependencies: - "@babel/helper-validator-identifier" "^7.18.6" - chalk "^2.0.0" + "@babel/helper-validator-identifier" "^7.22.20" + chalk "^2.4.2" js-tokens "^4.0.0" -"@chainsafe/as-sha256@^0.3.1": - version "0.3.1" - resolved "https://registry.yarnpkg.com/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz#3639df0e1435cab03f4d9870cc3ac079e57a6fc9" - integrity sha512-hldFFYuf49ed7DAakWVXSJODuq3pzJEguD8tQ7h+sGkM18vja+OFoJI9krnGmgzyuZC2ETX0NOIcCTy31v2Mtg== - -"@chainsafe/persistent-merkle-tree@^0.4.2": - version "0.4.2" - resolved "https://registry.yarnpkg.com/@chainsafe/persistent-merkle-tree/-/persistent-merkle-tree-0.4.2.tgz#4c9ee80cc57cd3be7208d98c40014ad38f36f7ff" - integrity sha512-lLO3ihKPngXLTus/L7WHKaw9PnNJWizlOF1H9NNzHP6Xvh82vzg9F2bzkXhYIFshMZ2gTCEz8tq6STe7r5NDfQ== - dependencies: - "@chainsafe/as-sha256" "^0.3.1" - -"@chainsafe/persistent-merkle-tree@^0.5.0": - version "0.5.0" - resolved "https://registry.yarnpkg.com/@chainsafe/persistent-merkle-tree/-/persistent-merkle-tree-0.5.0.tgz#2b4a62c9489a5739dedd197250d8d2f5427e9f63" - integrity sha512-l0V1b5clxA3iwQLXP40zYjyZYospQLZXzBVIhhr9kDg/1qHZfzzHw0jj4VPBijfYCArZDlPkRi1wZaV2POKeuw== - dependencies: - "@chainsafe/as-sha256" "^0.3.1" - -"@chainsafe/ssz@0.9.4", "@chainsafe/ssz@^0.9.2": - version "0.9.4" - resolved "https://registry.yarnpkg.com/@chainsafe/ssz/-/ssz-0.9.4.tgz#696a8db46d6975b600f8309ad3a12f7c0e310497" - integrity sha512-77Qtg2N1ayqs4Bg/wvnWfg5Bta7iy7IRh8XqXh7oNMeP2HBbBwx8m6yTpA8p0EHItWPEBkgZd5S5/LSlp3GXuQ== - dependencies: - "@chainsafe/as-sha256" "^0.3.1" - "@chainsafe/persistent-merkle-tree" "^0.4.2" - case "^1.6.3" - -"@chainsafe/ssz@^0.10.0": - version "0.10.2" - resolved "https://registry.yarnpkg.com/@chainsafe/ssz/-/ssz-0.10.2.tgz#c782929e1bb25fec66ba72e75934b31fd087579e" - integrity sha512-/NL3Lh8K+0q7A3LsiFq09YXS9fPE+ead2rr7vM2QK8PLzrNsw3uqrif9bpRX5UxgeRjM+vYi+boCM3+GM4ovXg== - dependencies: - "@chainsafe/as-sha256" "^0.3.1" - "@chainsafe/persistent-merkle-tree" "^0.5.0" - "@cspotcode/source-map-support@^0.8.0": version "0.8.1" resolved "https://registry.yarnpkg.com/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz#00629c35a688e05a88b1cda684fb9d5e73f000a1" @@ -82,26 +52,42 @@ dependencies: "@jridgewell/trace-mapping" "0.3.9" -"@eslint-community/eslint-utils@^4.2.0": +"@ensdomains/ens@^0.4.4": + version "0.4.5" + resolved "https://registry.yarnpkg.com/@ensdomains/ens/-/ens-0.4.5.tgz#e0aebc005afdc066447c6e22feb4eda89a5edbfc" + integrity sha512-JSvpj1iNMFjK6K+uVl4unqMoa9rf5jopb8cya5UGBWz23Nw8hSNT7efgUx4BTlAPAgpNlEioUfeTyQ6J9ZvTVw== + dependencies: + bluebird "^3.5.2" + eth-ens-namehash "^2.0.8" + solc "^0.4.20" + testrpc "0.0.1" + web3-utils "^1.0.0-beta.31" + +"@ensdomains/resolver@^0.2.4": + version "0.2.4" + resolved "https://registry.yarnpkg.com/@ensdomains/resolver/-/resolver-0.2.4.tgz#c10fe28bf5efbf49bff4666d909aed0265efbc89" + integrity sha512-bvaTH34PMCbv6anRa9I/0zjLJgY4EuznbEMgbV77JBCQ9KNC46rzi0avuxpOfu+xDjPEtSFGqVEOr5GlUSGudA== + +"@eslint-community/eslint-utils@^4.2.0", "@eslint-community/eslint-utils@^4.4.0": version "4.4.0" resolved "https://registry.yarnpkg.com/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz#a23514e8fb9af1269d5f7788aa556798d61c6b59" integrity sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA== dependencies: eslint-visitor-keys "^3.3.0" -"@eslint-community/regexpp@^4.4.0": - version "4.5.0" - resolved "https://registry.yarnpkg.com/@eslint-community/regexpp/-/regexpp-4.5.0.tgz#f6f729b02feee2c749f57e334b7a1b5f40a81724" - integrity sha512-vITaYzIcNmjn5tF5uxcZ/ft7/RXGrMUIS9HalWckEOF6ESiwXKoMzAQf2UW0aVd6rnOeExTJVd5hmWXucBKGXQ== +"@eslint-community/regexpp@^4.5.1", "@eslint-community/regexpp@^4.6.1": + version "4.10.0" + resolved "https://registry.yarnpkg.com/@eslint-community/regexpp/-/regexpp-4.10.0.tgz#548f6de556857c8bb73bbee70c35dc82a2e74d63" + integrity sha512-Cu96Sd2By9mCNTx2iyKOmq10v22jUVQv0lQnlGNy16oE9589yE+QADPbrMGCkA51cKZSg3Pu/aTJVTGfL/qjUA== -"@eslint/eslintrc@^2.0.2": - version "2.0.2" - resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-2.0.2.tgz#01575e38707add677cf73ca1589abba8da899a02" - integrity sha512-3W4f5tDUra+pA+FzgugqL2pRimUTDJWKr7BINqOpkZrC0uYI0NIc0/JFgBROCU07HR6GieA5m3/rsPIhDmCXTQ== +"@eslint/eslintrc@^2.1.4": + version "2.1.4" + resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-2.1.4.tgz#388a269f0f25c1b6adc317b5a2c55714894c70ad" + integrity sha512-269Z39MS6wVJtsoUl10L60WdkhJVdPG24Q4eZTH3nnF6lpvSShEK3wQjDX9JRWAUPvPh7COouPpU9IrqaZFvtQ== dependencies: ajv "^6.12.4" debug "^4.3.2" - espree "^9.5.1" + espree "^9.6.0" globals "^13.19.0" ignore "^5.2.0" import-fresh "^3.2.1" @@ -109,10 +95,10 @@ minimatch "^3.1.2" strip-json-comments "^3.1.1" -"@eslint/js@8.38.0": - version "8.38.0" - resolved "https://registry.yarnpkg.com/@eslint/js/-/js-8.38.0.tgz#73a8a0d8aa8a8e6fe270431c5e72ae91b5337892" - integrity sha512-IoD2MfUnOV58ghIHCiil01PcohxjbYR/qCxsoC+xNgUwh1EY8jOOrYmu3d3a71+tJJ23uscEV4X2HJWMsPJu4g== +"@eslint/js@8.57.0": + version "8.57.0" + resolved "https://registry.yarnpkg.com/@eslint/js/-/js-8.57.0.tgz#a5417ae8427873f1dd08b70b3574b453e67b5f7f" + integrity sha512-Ys+3g2TaW7gADOJzPt83SJtCDhMjndcDMFVQ/Tj9iA1BfJzFKD9mAUXT3OenpuPHbI6P/myECxRJrofUsDx/5g== "@ethereum-waffle/chai@4.0.10": version "4.0.10" @@ -228,16 +214,7 @@ "@ethereumjs/common" "^2.6.4" ethereumjs-util "^7.1.5" -"@ethereumjs/util@^8.0.0": - version "8.0.5" - resolved "https://registry.yarnpkg.com/@ethereumjs/util/-/util-8.0.5.tgz#b9088fc687cc13f0c1243d6133d145dfcf3fe446" - integrity sha512-259rXKK3b3D8HRVdRmlOEi6QFvwxdt304hhrEAmpZhsj7ufXEOTIc9JRZPMnXatKjECokdLNBcDOFBeBSzAIaw== - dependencies: - "@chainsafe/ssz" "0.9.4" - "@ethereumjs/rlp" "^4.0.1" - ethereum-cryptography "^1.1.2" - -"@ethereumjs/util@^8.1.0": +"@ethereumjs/util@^8.0.6", "@ethereumjs/util@^8.1.0": version "8.1.0" resolved "https://registry.yarnpkg.com/@ethereumjs/util/-/util-8.1.0.tgz#299df97fb6b034e0577ce9f94c7d9d1004409ed4" integrity sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA== @@ -264,7 +241,7 @@ merkle-patricia-tree "^4.2.2" rustbn.js "~0.2.0" -"@ethersproject/abi@5.7.0", "@ethersproject/abi@^5.0.0-beta.146", "@ethersproject/abi@^5.0.9", "@ethersproject/abi@^5.1.2", "@ethersproject/abi@^5.7.0": +"@ethersproject/abi@5.7.0", "@ethersproject/abi@^5.0.9", "@ethersproject/abi@^5.1.2", "@ethersproject/abi@^5.7.0": version "5.7.0" resolved "https://registry.yarnpkg.com/@ethersproject/abi/-/abi-5.7.0.tgz#b3f3e045bbbeed1af3947335c247ad625a44e449" integrity sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA== @@ -455,7 +432,7 @@ dependencies: "@ethersproject/logger" "^5.7.0" -"@ethersproject/providers@5.7.2", "@ethersproject/providers@^5.7.1", "@ethersproject/providers@^5.7.2": +"@ethersproject/providers@5.7.2", "@ethersproject/providers@^5.7.2": version "5.7.2" resolved "https://registry.yarnpkg.com/@ethersproject/providers/-/providers-5.7.2.tgz#f8b1a4f275d7ce58cf0a2eec222269a08beb18cb" integrity sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg== @@ -607,9 +584,9 @@ "@ethersproject/strings" "^5.7.0" "@fastify/busboy@^2.0.0": - version "2.1.0" - resolved "https://registry.yarnpkg.com/@fastify/busboy/-/busboy-2.1.0.tgz#0709e9f4cb252351c609c6e6d8d6779a8d25edff" - integrity sha512-+KpH+QxZU7O4675t3mnkQKcZZg56u+K/Ct2K+N2AZYNVK8kyeo/bI18tI8aPm3tvNNRyTWfj6s5tnGNlcbQRsA== + version "2.1.1" + resolved "https://registry.yarnpkg.com/@fastify/busboy/-/busboy-2.1.1.tgz#b9da6a878a371829a0502c9b6c1c143ef6663f4d" + integrity sha512-vBZP4NlzfOlerQTnba4aqZoMhE/a9HY7HRqoOPaETQcSQuWEIyZMHGfVu6w9wGtGK5fED5qRs2DteVCjOH60sA== "@ganache/ethereum-address@0.1.4": version "0.1.4" @@ -678,13 +655,13 @@ resolved "https://registry.yarnpkg.com/@gar/promisify/-/promisify-1.1.3.tgz#555193ab2e3bb3b6adc3d551c9c030d9e860daf6" integrity sha512-k2Ty1JcVojjJFwrg/ThKi2ujJ7XNLYaFGNB/bWT9wGR+oSMJHMa5w+CUq6p/pVrKeNNgA7pCqEcjSnHVoqJQFw== -"@humanwhocodes/config-array@^0.11.8": - version "0.11.8" - resolved "https://registry.yarnpkg.com/@humanwhocodes/config-array/-/config-array-0.11.8.tgz#03595ac2075a4dc0f191cc2131de14fbd7d410b9" - integrity sha512-UybHIJzJnR5Qc/MsD9Kr+RpO2h+/P1GhOwdiLPXK5TWk5sgTdu88bTD9UP+CKbPPh5Rni1u0GjAdYQLemG8g+g== +"@humanwhocodes/config-array@^0.11.14": + version "0.11.14" + resolved "https://registry.yarnpkg.com/@humanwhocodes/config-array/-/config-array-0.11.14.tgz#d78e481a039f7566ecc9660b4ea7fe6b1fec442b" + integrity sha512-3T8LkOmg45BV5FICb15QQMsyUSWrQ8AygVfC7ZG32zOalnqrilm018ZVCw0eapXux8FtA33q8PSRSstjee3jSg== dependencies: - "@humanwhocodes/object-schema" "^1.2.1" - debug "^4.1.1" + "@humanwhocodes/object-schema" "^2.0.2" + debug "^4.3.1" minimatch "^3.0.5" "@humanwhocodes/module-importer@^1.0.1": @@ -692,10 +669,10 @@ resolved "https://registry.yarnpkg.com/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz#af5b2691a22b44be847b0ca81641c5fb6ad0172c" integrity sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA== -"@humanwhocodes/object-schema@^1.2.1": - version "1.2.1" - resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz#b520529ec21d8e5945a1851dfd1c32e94e39ff45" - integrity sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA== +"@humanwhocodes/object-schema@^2.0.2": + version "2.0.2" + resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-2.0.2.tgz#d9fae00a2d5cb40f92cfe64b47ad749fbc38f917" + integrity sha512-6EwiSjwWYP7pTckG6I5eyFANjPhmPjUX9JRLUSfNPC7FX7zK9gyZAfUEaECL6ALTpGX5AjnBq3C9XmVWPitNpw== "@hutson/parse-repository-url@^3.0.0": version "3.0.2" @@ -722,9 +699,9 @@ "@sinclair/typebox" "^0.27.8" "@jridgewell/resolve-uri@^3.0.3": - version "3.1.1" - resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.1.tgz#c08679063f279615a3326583ba3a90d1d82cc721" - integrity sha512-dSYZh7HhCDtCKm4QakX0xFpsRDqjjtZf/kjI/v3T3Nwt5r8/qz/M19F9ySyOqU94SXBmeG9ttTul+YnR4LOxFA== + version "3.1.2" + resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz#7a0ee601f60f99a20c7c7c5ff0c80388c1189bd6" + integrity sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw== "@jridgewell/sourcemap-codec@^1.4.10": version "1.4.15" @@ -739,21 +716,21 @@ "@jridgewell/resolve-uri" "^3.0.3" "@jridgewell/sourcemap-codec" "^1.4.10" -"@lerna/child-process@7.3.0": - version "7.3.0" - resolved "https://registry.yarnpkg.com/@lerna/child-process/-/child-process-7.3.0.tgz#c56488a8a881f22a64793bf9339c5a2450a18559" - integrity sha512-rA+fGUo2j/LEq6w1w8s6oVikLbJTWoIDVpYMc7bUCtwDOUuZKMQiRtjmpavY3fTm7ltu42f4AKflc2A70K4wvA== +"@lerna/child-process@7.4.2": + version "7.4.2" + resolved "https://registry.yarnpkg.com/@lerna/child-process/-/child-process-7.4.2.tgz#a2fd013ac2150dc288270d3e0d0b850c06bec511" + integrity sha512-je+kkrfcvPcwL5Tg8JRENRqlbzjdlZXyaR88UcnCdNW0AJ1jX9IfHRys1X7AwSroU2ug8ESNC+suoBw1vX833Q== dependencies: chalk "^4.1.0" execa "^5.0.0" strong-log-transformer "^2.1.0" -"@lerna/create@7.3.0": - version "7.3.0" - resolved "https://registry.yarnpkg.com/@lerna/create/-/create-7.3.0.tgz#5438c231f617b8e825731390d394f8684af471d5" - integrity sha512-fjgiKjg9VXwQ4ZKKsrXICEKRiC3yo6+FprR0mc55uz0s5e9xupoSGLobUTTBdE7ncNB3ibqml8dfaAn/+ESajQ== +"@lerna/create@7.4.2": + version "7.4.2" + resolved "https://registry.yarnpkg.com/@lerna/create/-/create-7.4.2.tgz#f845fad1480e46555af98bd39af29571605dddc9" + integrity sha512-1wplFbQ52K8E/unnqB0Tq39Z4e+NEoNrpovEnl6GpsTUrC6WDp8+w0Le2uCBV0hXyemxChduCkLz4/y1H1wTeg== dependencies: - "@lerna/child-process" "7.3.0" + "@lerna/child-process" "7.4.2" "@npmcli/run-script" "6.0.2" "@nx/devkit" ">=16.5.1 < 17" "@octokit/plugin-enterprise-rest" "6.0.1" @@ -831,25 +808,17 @@ tweetnacl-util "^0.15.1" "@metamask/eth-sig-util@^5.0.2": - version "5.0.2" - resolved "https://registry.yarnpkg.com/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz#c518279a6e17a88135a13d53a0b970f145ff8bce" - integrity sha512-RU6fG/H6/UlBol221uBkq5C7w3TwLK611nEZliO2u+kO0vHKGBXnIPlhI0tzKUigjhUeOd9mhCNbNvhh0LKt9Q== + version "5.1.0" + resolved "https://registry.yarnpkg.com/@metamask/eth-sig-util/-/eth-sig-util-5.1.0.tgz#a47f62800ee1917fef976ba67544a0ccd7d1bd6b" + integrity sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ== dependencies: - "@ethereumjs/util" "^8.0.0" - bn.js "^4.11.8" - ethereum-cryptography "^1.1.2" + "@ethereumjs/util" "^8.0.6" + bn.js "^4.12.0" + ethereum-cryptography "^2.0.0" ethjs-util "^0.1.6" tweetnacl "^1.0.3" tweetnacl-util "^0.15.1" -"@morgan-stanley/ts-mocking-bird@^0.6.2": - version "0.6.4" - resolved "https://registry.yarnpkg.com/@morgan-stanley/ts-mocking-bird/-/ts-mocking-bird-0.6.4.tgz#2e4b60d42957bab3b50b67dbf14c3da2f62a39f7" - integrity sha512-57VJIflP8eR2xXa9cD1LUawh+Gh+BVQfVu0n6GALyg/AqV/Nz25kDRvws3i9kIe1PTrbsZZOYpsYp6bXPd6nVA== - dependencies: - lodash "^4.17.16" - uuid "^7.0.3" - "@noble/curves@1.3.0", "@noble/curves@~1.3.0": version "1.3.0" resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.3.0.tgz#01be46da4fd195822dab821e72f71bf4aeec635e" @@ -893,147 +862,164 @@ "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" -"@nomicfoundation/ethereumjs-block@5.0.2": - version "5.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-block/-/ethereumjs-block-5.0.2.tgz#13a7968f5964f1697da941281b7f7943b0465d04" - integrity sha512-hSe6CuHI4SsSiWWjHDIzWhSiAVpzMUcDRpWYzN0T9l8/Rz7xNn3elwVOJ/tAyS0LqL6vitUD78Uk7lQDXZun7Q== - dependencies: - "@nomicfoundation/ethereumjs-common" "4.0.2" - "@nomicfoundation/ethereumjs-rlp" "5.0.2" - "@nomicfoundation/ethereumjs-trie" "6.0.2" - "@nomicfoundation/ethereumjs-tx" "5.0.2" - "@nomicfoundation/ethereumjs-util" "9.0.2" +"@nomicfoundation/ethereumjs-block@5.0.4": + version "5.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-block/-/ethereumjs-block-5.0.4.tgz#ff2acb98a86b9290e35e315a6abfb9aebb9cf39e" + integrity sha512-AcyacJ9eX/uPEvqsPiB+WO1ymE+kyH48qGGiGV+YTojdtas8itUTW5dehDSOXEEItWGbbzEJ4PRqnQZlWaPvDw== + dependencies: + "@nomicfoundation/ethereumjs-common" "4.0.4" + "@nomicfoundation/ethereumjs-rlp" "5.0.4" + "@nomicfoundation/ethereumjs-trie" "6.0.4" + "@nomicfoundation/ethereumjs-tx" "5.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" ethereum-cryptography "0.1.3" - ethers "^5.7.1" -"@nomicfoundation/ethereumjs-blockchain@7.0.2": - version "7.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-blockchain/-/ethereumjs-blockchain-7.0.2.tgz#45323b673b3d2fab6b5008535340d1b8fea7d446" - integrity sha512-8UUsSXJs+MFfIIAKdh3cG16iNmWzWC/91P40sazNvrqhhdR/RtGDlFk2iFTGbBAZPs2+klZVzhRX8m2wvuvz3w== - dependencies: - "@nomicfoundation/ethereumjs-block" "5.0.2" - "@nomicfoundation/ethereumjs-common" "4.0.2" - "@nomicfoundation/ethereumjs-ethash" "3.0.2" - "@nomicfoundation/ethereumjs-rlp" "5.0.2" - "@nomicfoundation/ethereumjs-trie" "6.0.2" - "@nomicfoundation/ethereumjs-tx" "5.0.2" - "@nomicfoundation/ethereumjs-util" "9.0.2" - abstract-level "^1.0.3" +"@nomicfoundation/ethereumjs-blockchain@7.0.4": + version "7.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-blockchain/-/ethereumjs-blockchain-7.0.4.tgz#b77511b389290b186c8d999e70f4b15c27ef44ea" + integrity sha512-jYsd/kwzbmpnxx86tXsYV8wZ5xGvFL+7/P0c6OlzpClHsbFzeF41KrYA9scON8Rg6bZu3ZTv6JOAgj3t7USUfg== + dependencies: + "@nomicfoundation/ethereumjs-block" "5.0.4" + "@nomicfoundation/ethereumjs-common" "4.0.4" + "@nomicfoundation/ethereumjs-ethash" "3.0.4" + "@nomicfoundation/ethereumjs-rlp" "5.0.4" + "@nomicfoundation/ethereumjs-trie" "6.0.4" + "@nomicfoundation/ethereumjs-tx" "5.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" debug "^4.3.3" ethereum-cryptography "0.1.3" - level "^8.0.0" - lru-cache "^5.1.1" - memory-level "^1.0.0" + lru-cache "^10.0.0" -"@nomicfoundation/ethereumjs-common@4.0.2": - version "4.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-common/-/ethereumjs-common-4.0.2.tgz#a15d1651ca36757588fdaf2a7d381a150662a3c3" - integrity sha512-I2WGP3HMGsOoycSdOTSqIaES0ughQTueOsddJ36aYVpI3SN8YSusgRFLwzDJwRFVIYDKx/iJz0sQ5kBHVgdDwg== +"@nomicfoundation/ethereumjs-common@4.0.4": + version "4.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-common/-/ethereumjs-common-4.0.4.tgz#9901f513af2d4802da87c66d6f255b510bef5acb" + integrity sha512-9Rgb658lcWsjiicr5GzNCjI1llow/7r0k50dLL95OJ+6iZJcVbi15r3Y0xh2cIO+zgX0WIHcbzIu6FeQf9KPrg== dependencies: - "@nomicfoundation/ethereumjs-util" "9.0.2" - crc-32 "^1.2.0" + "@nomicfoundation/ethereumjs-util" "9.0.4" -"@nomicfoundation/ethereumjs-ethash@3.0.2": - version "3.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-ethash/-/ethereumjs-ethash-3.0.2.tgz#da77147f806401ee996bfddfa6487500118addca" - integrity sha512-8PfoOQCcIcO9Pylq0Buijuq/O73tmMVURK0OqdjhwqcGHYC2PwhbajDh7GZ55ekB0Px197ajK3PQhpKoiI/UPg== - dependencies: - "@nomicfoundation/ethereumjs-block" "5.0.2" - "@nomicfoundation/ethereumjs-rlp" "5.0.2" - "@nomicfoundation/ethereumjs-util" "9.0.2" - abstract-level "^1.0.3" - bigint-crypto-utils "^3.0.23" +"@nomicfoundation/ethereumjs-ethash@3.0.4": + version "3.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-ethash/-/ethereumjs-ethash-3.0.4.tgz#06cb2502b3012fb6c11cffd44af08aecf71310da" + integrity sha512-xvIrwIMl9sSaiYKRem68+O7vYdj7Q2XWv5P7JXiIkn83918QzWHvqbswTRsH7+r6X1UEvdsURRnZbvZszEjAaQ== + dependencies: + "@nomicfoundation/ethereumjs-block" "5.0.4" + "@nomicfoundation/ethereumjs-rlp" "5.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" + bigint-crypto-utils "^3.2.2" ethereum-cryptography "0.1.3" -"@nomicfoundation/ethereumjs-evm@2.0.2": - version "2.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-evm/-/ethereumjs-evm-2.0.2.tgz#4c2f4b84c056047102a4fa41c127454e3f0cfcf6" - integrity sha512-rBLcUaUfANJxyOx9HIdMX6uXGin6lANCulIm/pjMgRqfiCRMZie3WKYxTSd8ZE/d+qT+zTedBF4+VHTdTSePmQ== - dependencies: - "@ethersproject/providers" "^5.7.1" - "@nomicfoundation/ethereumjs-common" "4.0.2" - "@nomicfoundation/ethereumjs-tx" "5.0.2" - "@nomicfoundation/ethereumjs-util" "9.0.2" +"@nomicfoundation/ethereumjs-evm@2.0.4": + version "2.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-evm/-/ethereumjs-evm-2.0.4.tgz#c9c761767283ac53946185474362230b169f8f63" + integrity sha512-lTyZZi1KpeMHzaO6cSVisR2tjiTTedjo7PcmhI/+GNFo9BmyY6QYzGeSti0sFttmjbEMioHgXxl5yrLNRg6+1w== + dependencies: + "@nomicfoundation/ethereumjs-common" "4.0.4" + "@nomicfoundation/ethereumjs-statemanager" "2.0.4" + "@nomicfoundation/ethereumjs-tx" "5.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" + "@types/debug" "^4.1.9" debug "^4.3.3" ethereum-cryptography "0.1.3" - mcl-wasm "^0.7.1" - rustbn.js "~0.2.0" + rustbn-wasm "^0.2.0" -"@nomicfoundation/ethereumjs-rlp@5.0.2": - version "5.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-rlp/-/ethereumjs-rlp-5.0.2.tgz#4fee8dc58a53ac6ae87fb1fca7c15dc06c6b5dea" - integrity sha512-QwmemBc+MMsHJ1P1QvPl8R8p2aPvvVcKBbvHnQOKBpBztEo0omN0eaob6FeZS/e3y9NSe+mfu3nNFBHszqkjTA== +"@nomicfoundation/ethereumjs-rlp@5.0.4": + version "5.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-rlp/-/ethereumjs-rlp-5.0.4.tgz#66c95256fc3c909f6fb18f6a586475fc9762fa30" + integrity sha512-8H1S3s8F6QueOc/X92SdrA4RDenpiAEqMg5vJH99kcQaCy/a3Q6fgseo75mgWlbanGJXSlAPtnCeG9jvfTYXlw== -"@nomicfoundation/ethereumjs-statemanager@2.0.2": - version "2.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-statemanager/-/ethereumjs-statemanager-2.0.2.tgz#3ba4253b29b1211cafe4f9265fee5a0d780976e0" - integrity sha512-dlKy5dIXLuDubx8Z74sipciZnJTRSV/uHG48RSijhgm1V7eXYFC567xgKtsKiVZB1ViTP9iFL4B6Je0xD6X2OA== +"@nomicfoundation/ethereumjs-statemanager@2.0.4": + version "2.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-statemanager/-/ethereumjs-statemanager-2.0.4.tgz#bf14415e1f31b5ea8b98a0c027c547d0555059b6" + integrity sha512-HPDjeFrxw6llEi+BzqXkZ+KkvFnTOPczuHBtk21hRlDiuKuZz32dPzlhpRsDBGV1b5JTmRDUVqCS1lp3Gghw4Q== dependencies: - "@nomicfoundation/ethereumjs-common" "4.0.2" - "@nomicfoundation/ethereumjs-rlp" "5.0.2" + "@nomicfoundation/ethereumjs-common" "4.0.4" + "@nomicfoundation/ethereumjs-rlp" "5.0.4" + "@nomicfoundation/ethereumjs-trie" "6.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" debug "^4.3.3" ethereum-cryptography "0.1.3" - ethers "^5.7.1" js-sdsl "^4.1.4" + lru-cache "^10.0.0" -"@nomicfoundation/ethereumjs-trie@6.0.2": - version "6.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-trie/-/ethereumjs-trie-6.0.2.tgz#9a6dbd28482dca1bc162d12b3733acab8cd12835" - integrity sha512-yw8vg9hBeLYk4YNg5MrSJ5H55TLOv2FSWUTROtDtTMMmDGROsAu+0tBjiNGTnKRi400M6cEzoFfa89Fc5k8NTQ== +"@nomicfoundation/ethereumjs-trie@6.0.4": + version "6.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-trie/-/ethereumjs-trie-6.0.4.tgz#688a3f76646c209365ee6d959c3d7330ede5e609" + integrity sha512-3nSwQiFMvr2VFe/aZUyinuohYvtytUqZCUCvIWcPJ/BwJH6oQdZRB42aNFBJ/8nAh2s3OcroWpBLskzW01mFKA== dependencies: - "@nomicfoundation/ethereumjs-rlp" "5.0.2" - "@nomicfoundation/ethereumjs-util" "9.0.2" + "@nomicfoundation/ethereumjs-rlp" "5.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" "@types/readable-stream" "^2.3.13" ethereum-cryptography "0.1.3" + lru-cache "^10.0.0" readable-stream "^3.6.0" -"@nomicfoundation/ethereumjs-tx@5.0.2": - version "5.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-tx/-/ethereumjs-tx-5.0.2.tgz#117813b69c0fdc14dd0446698a64be6df71d7e56" - integrity sha512-T+l4/MmTp7VhJeNloMkM+lPU3YMUaXdcXgTGCf8+ZFvV9NYZTRLFekRwlG6/JMmVfIfbrW+dRRJ9A6H5Q/Z64g== - dependencies: - "@chainsafe/ssz" "^0.9.2" - "@ethersproject/providers" "^5.7.2" - "@nomicfoundation/ethereumjs-common" "4.0.2" - "@nomicfoundation/ethereumjs-rlp" "5.0.2" - "@nomicfoundation/ethereumjs-util" "9.0.2" +"@nomicfoundation/ethereumjs-tx@5.0.4": + version "5.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-tx/-/ethereumjs-tx-5.0.4.tgz#b0ceb58c98cc34367d40a30d255d6315b2f456da" + integrity sha512-Xjv8wAKJGMrP1f0n2PeyfFCCojHd7iS3s/Ab7qzF1S64kxZ8Z22LCMynArYsVqiFx6rzYy548HNVEyI+AYN/kw== + dependencies: + "@nomicfoundation/ethereumjs-common" "4.0.4" + "@nomicfoundation/ethereumjs-rlp" "5.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" ethereum-cryptography "0.1.3" -"@nomicfoundation/ethereumjs-util@9.0.2": - version "9.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-util/-/ethereumjs-util-9.0.2.tgz#16bdc1bb36f333b8a3559bbb4b17dac805ce904d" - integrity sha512-4Wu9D3LykbSBWZo8nJCnzVIYGvGCuyiYLIJa9XXNVt1q1jUzHdB+sJvx95VGCpPkCT+IbLecW6yfzy3E1bQrwQ== +"@nomicfoundation/ethereumjs-util@9.0.4": + version "9.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-util/-/ethereumjs-util-9.0.4.tgz#84c5274e82018b154244c877b76bc049a4ed7b38" + integrity sha512-sLOzjnSrlx9Bb9EFNtHzK/FJFsfg2re6bsGqinFinH1gCqVfz9YYlXiMWwDM4C/L4ywuHFCYwfKTVr/QHQcU0Q== dependencies: - "@chainsafe/ssz" "^0.10.0" - "@nomicfoundation/ethereumjs-rlp" "5.0.2" + "@nomicfoundation/ethereumjs-rlp" "5.0.4" ethereum-cryptography "0.1.3" -"@nomicfoundation/ethereumjs-vm@7.0.2": - version "7.0.2" - resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-vm/-/ethereumjs-vm-7.0.2.tgz#3b0852cb3584df0e18c182d0672a3596c9ca95e6" - integrity sha512-Bj3KZT64j54Tcwr7Qm/0jkeZXJMfdcAtRBedou+Hx0dPOSIgqaIr0vvLwP65TpHbak2DmAq+KJbW2KNtIoFwvA== - dependencies: - "@nomicfoundation/ethereumjs-block" "5.0.2" - "@nomicfoundation/ethereumjs-blockchain" "7.0.2" - "@nomicfoundation/ethereumjs-common" "4.0.2" - "@nomicfoundation/ethereumjs-evm" "2.0.2" - "@nomicfoundation/ethereumjs-rlp" "5.0.2" - "@nomicfoundation/ethereumjs-statemanager" "2.0.2" - "@nomicfoundation/ethereumjs-trie" "6.0.2" - "@nomicfoundation/ethereumjs-tx" "5.0.2" - "@nomicfoundation/ethereumjs-util" "9.0.2" +"@nomicfoundation/ethereumjs-verkle@0.0.2": + version "0.0.2" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-verkle/-/ethereumjs-verkle-0.0.2.tgz#7686689edec775b2efea5a71548f417c18f7dea4" + integrity sha512-bjnfZElpYGK/XuuVRmLS3yDvr+cDs85D9oonZ0YUa5A3lgFgokWMp76zXrxX2jVQ0BfHaw12y860n1+iOi6yFQ== + dependencies: + "@nomicfoundation/ethereumjs-rlp" "5.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" + lru-cache "^10.0.0" + rust-verkle-wasm "^0.0.1" + +"@nomicfoundation/ethereumjs-vm@7.0.4": + version "7.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/ethereumjs-vm/-/ethereumjs-vm-7.0.4.tgz#e5a6eec4877dc62dda93003c6d7afd1fe4b9625b" + integrity sha512-gsA4IhmtWHI4BofKy3kio9W+dqZQs5Ji5mLjLYxHCkat+JQBUt5szjRKra2F9nGDJ2XcI/wWb0YWUFNgln4zRQ== + dependencies: + "@nomicfoundation/ethereumjs-block" "5.0.4" + "@nomicfoundation/ethereumjs-blockchain" "7.0.4" + "@nomicfoundation/ethereumjs-common" "4.0.4" + "@nomicfoundation/ethereumjs-evm" "2.0.4" + "@nomicfoundation/ethereumjs-rlp" "5.0.4" + "@nomicfoundation/ethereumjs-statemanager" "2.0.4" + "@nomicfoundation/ethereumjs-trie" "6.0.4" + "@nomicfoundation/ethereumjs-tx" "5.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" debug "^4.3.3" ethereum-cryptography "0.1.3" - mcl-wasm "^0.7.1" - rustbn.js "~0.2.0" "@nomicfoundation/hardhat-network-helpers@^1.0.7": - version "1.0.8" - resolved "https://registry.yarnpkg.com/@nomicfoundation/hardhat-network-helpers/-/hardhat-network-helpers-1.0.8.tgz#e4fe1be93e8a65508c46d73c41fa26c7e9f84931" - integrity sha512-MNqQbzUJZnCMIYvlniC3U+kcavz/PhhQSsY90tbEtUyMj/IQqsLwIRZa4ctjABh3Bz0KCh9OXUZ7Yk/d9hr45Q== + version "1.0.10" + resolved "https://registry.yarnpkg.com/@nomicfoundation/hardhat-network-helpers/-/hardhat-network-helpers-1.0.10.tgz#c61042ceb104fdd6c10017859fdef6529c1d6585" + integrity sha512-R35/BMBlx7tWN5V6d/8/19QCwEmIdbnA4ZrsuXgvs8i2qFx5i7h6mH5pBS4Pwi4WigLH+upl6faYusrNPuzMrQ== dependencies: ethereumjs-util "^7.1.4" +"@nomicfoundation/hardhat-verify@^2.0.4": + version "2.0.4" + resolved "https://registry.yarnpkg.com/@nomicfoundation/hardhat-verify/-/hardhat-verify-2.0.4.tgz#65b86787fc7b47d38fd941862266065c7eb9bca4" + integrity sha512-B8ZjhOrmbbRWqJi65jvQblzjsfYktjqj2vmOm+oc2Vu8drZbT2cjeSCRHZKbS7lOtfW78aJZSFvw+zRLCiABJA== + dependencies: + "@ethersproject/abi" "^5.1.2" + "@ethersproject/address" "^5.0.2" + cbor "^8.1.0" + chalk "^2.4.2" + debug "^4.1.1" + lodash.clonedeep "^4.5.0" + semver "^6.3.0" + table "^6.8.0" + undici "^5.14.0" + "@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.1": version "0.1.1" resolved "https://registry.yarnpkg.com/@nomicfoundation/solidity-analyzer-darwin-arm64/-/solidity-analyzer-darwin-arm64-0.1.1.tgz#4c858096b1c17fe58a474fe81b46815f93645c15" @@ -1100,31 +1086,15 @@ "@nomicfoundation/solidity-analyzer-win32-ia32-msvc" "0.1.1" "@nomicfoundation/solidity-analyzer-win32-x64-msvc" "0.1.1" -"@nomiclabs/hardhat-ethers@^2.1.0": +"@nomiclabs/hardhat-ethers@^2.2.3": version "2.2.3" resolved "https://registry.yarnpkg.com/@nomiclabs/hardhat-ethers/-/hardhat-ethers-2.2.3.tgz#b41053e360c31a32c2640c9a45ee981a7e603fe0" integrity sha512-YhzPdzb612X591FOe68q+qXVXGG2ANZRvDo0RRUtimev85rCrAlv/TLMEZw5c+kq9AbzocLTVX/h2jVIFPL9Xg== -"@nomiclabs/hardhat-etherscan@^3.1.0": - version "3.1.7" - resolved "https://registry.yarnpkg.com/@nomiclabs/hardhat-etherscan/-/hardhat-etherscan-3.1.7.tgz#72e3d5bd5d0ceb695e097a7f6f5ff6fcbf062b9a" - integrity sha512-tZ3TvSgpvsQ6B6OGmo1/Au6u8BrAkvs1mIC/eURA3xgIfznUZBhmpne8hv7BXUzw9xNL3fXdpOYgOQlVMTcoHQ== - dependencies: - "@ethersproject/abi" "^5.1.2" - "@ethersproject/address" "^5.0.2" - cbor "^8.1.0" - chalk "^2.4.2" - debug "^4.1.1" - fs-extra "^7.0.1" - lodash "^4.17.11" - semver "^6.3.0" - table "^6.8.0" - undici "^5.14.0" - -"@nomiclabs/hardhat-waffle@^2.0.3": - version "2.0.5" - resolved "https://registry.yarnpkg.com/@nomiclabs/hardhat-waffle/-/hardhat-waffle-2.0.5.tgz#97c217f1db795395c04404291937edb528f3f218" - integrity sha512-U1RH9OQ1mWYQfb+moX5aTgGjpVVlOcpiFI47wwnaGG4kLhcTy90cNiapoqZenxcRAITVbr0/+QSduINL5EsUIQ== +"@nomiclabs/hardhat-waffle@^2.0.6": + version "2.0.6" + resolved "https://registry.yarnpkg.com/@nomiclabs/hardhat-waffle/-/hardhat-waffle-2.0.6.tgz#d11cb063a5f61a77806053e54009c40ddee49a54" + integrity sha512-+Wz0hwmJGSI17B+BhU/qFRZ1l6/xMW82QGXE/Gi+WTmwgJrQefuBs1lIf7hzQ1hLk6hpkvb/zwcNkpVKRYTQYg== "@npmcli/fs@^2.1.0": version "2.1.2" @@ -1142,9 +1112,9 @@ semver "^7.3.5" "@npmcli/git@^4.0.0": - version "4.0.4" - resolved "https://registry.yarnpkg.com/@npmcli/git/-/git-4.0.4.tgz#cdf74f21b1d440c0756fb28159d935129d9daa33" - integrity sha512-5yZghx+u5M47LghaybLCkdSyFzV/w4OuH12d96HO389Ik9CDsLaDZJVynSGGVJOLn6gy/k7Dz5XYcplM3uxXRg== + version "4.1.0" + resolved "https://registry.yarnpkg.com/@npmcli/git/-/git-4.1.0.tgz#ab0ad3fd82bc4d8c1351b6c62f0fa56e8fe6afa6" + integrity sha512-9hwoB3gStVfa0N31ymBmrX+GuDGdVA/QWShZVqE0HK2Af+7QGGrCTbZia/SW0ImUTjTne7SP91qxDmtXvDHRPQ== dependencies: "@npmcli/promise-spawn" "^6.0.0" lru-cache "^7.4.4" @@ -1183,7 +1153,7 @@ dependencies: which "^3.0.0" -"@npmcli/run-script@6.0.2": +"@npmcli/run-script@6.0.2", "@npmcli/run-script@^6.0.0": version "6.0.2" resolved "https://registry.yarnpkg.com/@npmcli/run-script/-/run-script-6.0.2.tgz#a25452d45ee7f7fb8c16dfaf9624423c0c0eb885" integrity sha512-NCcr1uQo1k5U+SYlnIrbAh3cxy+OQT1VtqiAbxdymSlptbzBb62AjH2xXgjNCoP073hoa1CfCAcwoZ8k96C4nA== @@ -1194,31 +1164,12 @@ read-package-json-fast "^3.0.0" which "^3.0.0" -"@npmcli/run-script@^6.0.0": - version "6.0.0" - resolved "https://registry.yarnpkg.com/@npmcli/run-script/-/run-script-6.0.0.tgz#f89e322c729e26ae29db6cc8cc76559074aac208" - integrity sha512-ql+AbRur1TeOdl1FY+RAwGW9fcr4ZwiVKabdvm93mujGREVuVLbdkXRJDrkTXSdCjaxYydr1wlA2v67jxWG5BQ== - dependencies: - "@npmcli/node-gyp" "^3.0.0" - "@npmcli/promise-spawn" "^6.0.0" - node-gyp "^9.0.0" - read-package-json-fast "^3.0.0" - which "^3.0.0" - -"@nrwl/devkit@*": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nrwl/devkit/-/devkit-16.9.0.tgz#5f47580f9f4950b85cc1606ede5772e43e591119" - integrity sha512-zf6qvW2FV5Rtk0xr2eQnTQ8UZJ/v20UNHnm0oFNz5fsAolKY0wiWSsXnycYvfFTWc6epukFw49hymf5Ei1lHiA== - dependencies: - "@nx/devkit" "16.9.0" - -"@nrwl/tao@*": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nrwl/tao/-/tao-16.9.0.tgz#0a99a0cac3822c074f60391860caafc663a259b1" - integrity sha512-2gkP2pKPgIfIsQXfly8ogRvbKpyiJTpYO6q0sIUCdir+MN1HvZH1Ymm8JVlzNasy+TpMYKE5YWgAJW5gVBrrtg== +"@nrwl/devkit@16.10.0": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nrwl/devkit/-/devkit-16.10.0.tgz#ac8c5b4db00f12c4b817c937be2f7c4eb8f2593c" + integrity sha512-fRloARtsDQoQgQ7HKEy0RJiusg/HSygnmg4gX/0n/Z+SUS+4KoZzvHjXc6T5ZdEiSjvLypJ+HBM8dQzIcVACPQ== dependencies: - nx "16.9.0" - tslib "^2.3.0" + "@nx/devkit" "16.10.0" "@nrwl/tao@16.10.0": version "16.10.0" @@ -1228,12 +1179,12 @@ nx "16.10.0" tslib "^2.3.0" -"@nx/devkit@16.9.0", "@nx/devkit@>=16.5.1 < 17": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/devkit/-/devkit-16.9.0.tgz#e37fcbe675a48e503ef8712cb9f56a154d796db7" - integrity sha512-cqCLyiX9he+4XPalUysIfuDZ+b+JbnuFRwo0xIcrk86SwskVWBHGXgXthC7KoEK0ToCQXP+cEbXZqa5zZmuGbQ== +"@nx/devkit@16.10.0", "@nx/devkit@>=16.5.1 < 17": + version "16.10.0" + resolved "https://registry.yarnpkg.com/@nx/devkit/-/devkit-16.10.0.tgz#7e466be2dee2dcb1ccaf286786ca2a0a639aa007" + integrity sha512-IvKQqRJFDDiaj33SPfGd3ckNHhHi6ceEoqCbAP4UuMXOPPVOX6H0KVk+9tknkPb48B7jWIw6/AgOeWkBxPRO5w== dependencies: - "@nrwl/devkit" "*" + "@nrwl/devkit" "16.10.0" ejs "^3.1.7" enquirer "~2.3.6" ignore "^5.0.4" @@ -1246,107 +1197,55 @@ resolved "https://registry.yarnpkg.com/@nx/nx-darwin-arm64/-/nx-darwin-arm64-16.10.0.tgz#0c73010cac7a502549483b12bad347da9014e6f1" integrity sha512-YF+MIpeuwFkyvM5OwgY/rTNRpgVAI/YiR0yTYCZR+X3AAvP775IVlusNgQ3oedTBRUzyRnI4Tknj1WniENFsvQ== -"@nx/nx-darwin-arm64@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-darwin-arm64/-/nx-darwin-arm64-16.9.0.tgz#26fc149f14c867d130dd06dea8cf89f8ff4e754b" - integrity sha512-I+045kSIQgdHMfqpJ/bplWzTc82DM/c7VOM/XlrBUwaM9nsDchIC2mo1F93HDe/oJ+oxz9awHbED4GUzS6uc5g== - "@nx/nx-darwin-x64@16.10.0": version "16.10.0" resolved "https://registry.yarnpkg.com/@nx/nx-darwin-x64/-/nx-darwin-x64-16.10.0.tgz#2ccf270418d552fd0a8e0d6089aee4944315adaa" integrity sha512-ypi6YxwXgb0kg2ixKXE3pwf5myVNUgWf1CsV5OzVccCM8NzheMO51KDXTDmEpXdzUsfT0AkO1sk5GZeCjhVONg== -"@nx/nx-darwin-x64@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-darwin-x64/-/nx-darwin-x64-16.9.0.tgz#806fb83384fa01a7ebe8993a53d2b2dfe3e6a87e" - integrity sha512-Yop/nZlJ+j4RIDB5bfuse583lWLiHtyL7bRPj2IsXAWiQHvXfrNnJJwYH7cGHgtR4ctSAZdOi7SZWlmgHO7Hyw== - "@nx/nx-freebsd-x64@16.10.0": version "16.10.0" resolved "https://registry.yarnpkg.com/@nx/nx-freebsd-x64/-/nx-freebsd-x64-16.10.0.tgz#c3ee6914256e69493fed9355b0d6661d0e86da44" integrity sha512-UeEYFDmdbbDkTQamqvtU8ibgu5jQLgFF1ruNb/U4Ywvwutw2d4ruOMl2e0u9hiNja9NFFAnDbvzrDcMo7jYqYw== -"@nx/nx-freebsd-x64@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-freebsd-x64/-/nx-freebsd-x64-16.9.0.tgz#2865cd20e309c21880def9b05a6c66af834c53e3" - integrity sha512-qDg7Sd4V6edRuqR4Y+eEPec0J0Nf5ebGGGDegKjV7X4OfgagOb7k8o3cAGiKkKXuaAUg1OnqVw5nF7JysAmrLQ== - "@nx/nx-linux-arm-gnueabihf@16.10.0": version "16.10.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm-gnueabihf/-/nx-linux-arm-gnueabihf-16.10.0.tgz#a961eccbb38acb2da7fc125b29d1fead0b39152f" integrity sha512-WV3XUC2DB6/+bz1sx+d1Ai9q2Cdr+kTZRN50SOkfmZUQyEBaF6DRYpx/a4ahhxH3ktpNfyY8Maa9OEYxGCBkQA== -"@nx/nx-linux-arm-gnueabihf@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm-gnueabihf/-/nx-linux-arm-gnueabihf-16.9.0.tgz#819bf24fc493d053711502a3bebe95c7eeae3c80" - integrity sha512-eyG4PP5jSyDkO8Hm3zrchjm/coVY2L66/ExalfO8j+FSqwlipFIWwkpQM3Tw2fYrrMZpWXa7VlHj10Eu2xF5pQ== - "@nx/nx-linux-arm64-gnu@16.10.0": version "16.10.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-gnu/-/nx-linux-arm64-gnu-16.10.0.tgz#795f20072549d03822b5c4639ef438e473dbb541" integrity sha512-aWIkOUw995V3ItfpAi5FuxQ+1e9EWLS1cjWM1jmeuo+5WtaKToJn5itgQOkvSlPz+HSLgM3VfXMvOFALNk125g== -"@nx/nx-linux-arm64-gnu@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-gnu/-/nx-linux-arm64-gnu-16.9.0.tgz#ee064ab6f7a2fe747844ee73a51c9eac8abf27f2" - integrity sha512-oJBf2J1qwfACoSN+Hutb6iq0XvIllRdR+52HUXriCWLe6At4kaDW/p+sBcmtlsdgVY3BRs32rqTgYb8qJ1CJRA== - "@nx/nx-linux-arm64-musl@16.10.0": version "16.10.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-musl/-/nx-linux-arm64-musl-16.10.0.tgz#f2428ee6dbe2b2c326e8973f76c97666def33607" integrity sha512-uO6Gg+irqpVcCKMcEPIQcTFZ+tDI02AZkqkP7koQAjniLEappd8DnUBSQdcn53T086pHpdc264X/ZEpXFfrKWQ== -"@nx/nx-linux-arm64-musl@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-arm64-musl/-/nx-linux-arm64-musl-16.9.0.tgz#f2b071ea4ac4e3d31c79cd9d41b214f7e1e8edac" - integrity sha512-RxAI0ls5Zy/HyL51PMmbaTX+tbZklgAeMqtQhziyjD/awao/9Jt783IqVPFfKoWTNmDq6/bjOG8obcnQlLKsaw== - "@nx/nx-linux-x64-gnu@16.10.0": version "16.10.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-gnu/-/nx-linux-x64-gnu-16.10.0.tgz#d36c2bcf94d49eaa24e3880ddaf6f1f617de539b" integrity sha512-134PW/u/arNFAQKpqMJniC7irbChMPz+W+qtyKPAUXE0XFKPa7c1GtlI/wK2dvP9qJDZ6bKf0KtA0U/m2HMUOA== -"@nx/nx-linux-x64-gnu@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-gnu/-/nx-linux-x64-gnu-16.9.0.tgz#f3c58d41a8e8ffe5b54414dc5c5a3a5031da530f" - integrity sha512-xFaA3lOQn1hZ4mzXdCUe/CCioEjRJ0E18AekD2g0r9mMRVyrxEk0KH71jMQwbbVYzkvG9a2Vjiptp8hjmEejAw== - "@nx/nx-linux-x64-musl@16.10.0": version "16.10.0" resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-musl/-/nx-linux-x64-musl-16.10.0.tgz#78bd2ab97a583b3d4ea3387b67fd7b136907493c" integrity sha512-q8sINYLdIJxK/iUx9vRk5jWAWb/2O0PAbOJFwv4qkxBv4rLoN7y+otgCZ5v0xfx/zztFgk/oNY4lg5xYjIso2Q== -"@nx/nx-linux-x64-musl@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-linux-x64-musl/-/nx-linux-x64-musl-16.9.0.tgz#0c7fdcf459d10dc17d8b489724ab72fe4145b4ca" - integrity sha512-8tfqvCajTOH5Tt/NFMNJRePwkoUbGYUK7qHJU2LDAazDUsjvpawdvEM8FkJWsNgIsQBej+zcSYA16+sffjsY2g== - "@nx/nx-win32-arm64-msvc@16.10.0": version "16.10.0" resolved "https://registry.yarnpkg.com/@nx/nx-win32-arm64-msvc/-/nx-win32-arm64-msvc-16.10.0.tgz#ef20ec8d0c83d66e73e20df12d2c788b8f866396" integrity sha512-moJkL9kcqxUdJSRpG7dET3UeLIciwrfP08mzBQ12ewo8K8FzxU8ZUsTIVVdNrwt01CXOdXoweGfdQLjJ4qTURA== -"@nx/nx-win32-arm64-msvc@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-win32-arm64-msvc/-/nx-win32-arm64-msvc-16.9.0.tgz#0ba710f46ac64028a13288c6a414379fec55e3b3" - integrity sha512-tUCu1rg76zHdCmov25K2uHUK2rZBTnzbe58r8Wieytmywijp6vGW53RZzYT86YIvInvPJsH7tULdbZpPW56Ruw== - "@nx/nx-win32-x64-msvc@16.10.0": version "16.10.0" resolved "https://registry.yarnpkg.com/@nx/nx-win32-x64-msvc/-/nx-win32-x64-msvc-16.10.0.tgz#7410a51d0f8be631eec9552f01b2e5946285927c" integrity sha512-5iV2NKZnzxJwZZ4DM5JVbRG/nkhAbzEskKaLBB82PmYGKzaDHuMHP1lcPoD/rtYMlowZgNA/RQndfKvPBPwmXA== -"@nx/nx-win32-x64-msvc@16.9.0": - version "16.9.0" - resolved "https://registry.yarnpkg.com/@nx/nx-win32-x64-msvc/-/nx-win32-x64-msvc-16.9.0.tgz#495a46e64f7c33377f9e8417ade50b9d9a823a79" - integrity sha512-YTYDZIvqo+2aZl6/ovnBFsEfxoQ/M2sYICJ3zyp00i13VkMdttrIqf8MFqNCD4K+usDQxSpq5M9QLSZ4yltydQ== - "@octokit/auth-token@^3.0.0": - version "3.0.3" - resolved "https://registry.yarnpkg.com/@octokit/auth-token/-/auth-token-3.0.3.tgz#ce7e48a3166731f26068d7a7a7996b5da58cbe0c" - integrity sha512-/aFM2M4HVDBT/jjDBa84sJniv1t9Gm/rLkalaz9htOm+L+8JMj1k9w0CkUdcxNyNxZPlTxKPVko+m1VlM58ZVA== - dependencies: - "@octokit/types" "^9.0.0" + version "3.0.4" + resolved "https://registry.yarnpkg.com/@octokit/auth-token/-/auth-token-3.0.4.tgz#70e941ba742bdd2b49bdb7393e821dea8520a3db" + integrity sha512-TWFX7cZF2LXoCvdmJWY7XVPi74aSY0+FfBZNSXEXFkMpjcqsQwDSYVv5FhRFaI0V1ECnwbz4j59T/G+rXNWaIQ== "@octokit/core@^4.2.1": version "4.2.4" @@ -1362,28 +1261,23 @@ universal-user-agent "^6.0.0" "@octokit/endpoint@^7.0.0": - version "7.0.5" - resolved "https://registry.yarnpkg.com/@octokit/endpoint/-/endpoint-7.0.5.tgz#2bb2a911c12c50f10014183f5d596ce30ac67dd1" - integrity sha512-LG4o4HMY1Xoaec87IqQ41TQ+glvIeTKqfjkCEmt5AIwDZJwQeVZFIEYXrYY6yLwK+pAScb9Gj4q+Nz2qSw1roA== + version "7.0.6" + resolved "https://registry.yarnpkg.com/@octokit/endpoint/-/endpoint-7.0.6.tgz#791f65d3937555141fb6c08f91d618a7d645f1e2" + integrity sha512-5L4fseVRUsDFGR00tMWD/Trdeeihn999rTMGRMC1G/Ldi1uWlWJzI98H4Iak5DB/RVvQuyMYKqSK/R6mbSOQyg== dependencies: "@octokit/types" "^9.0.0" is-plain-object "^5.0.0" universal-user-agent "^6.0.0" "@octokit/graphql@^5.0.0": - version "5.0.5" - resolved "https://registry.yarnpkg.com/@octokit/graphql/-/graphql-5.0.5.tgz#a4cb3ea73f83b861893a6370ee82abb36e81afd2" - integrity sha512-Qwfvh3xdqKtIznjX9lz2D458r7dJPP8l6r4GQkIdWQouZwHQK0mVT88uwiU2bdTU2OtT1uOlKpRciUWldpG0yQ== + version "5.0.6" + resolved "https://registry.yarnpkg.com/@octokit/graphql/-/graphql-5.0.6.tgz#9eac411ac4353ccc5d3fca7d76736e6888c5d248" + integrity sha512-Fxyxdy/JH0MnIB5h+UQ3yCoh1FG4kWXfFKkpWqjZHw/p+Kc8Y44Hu/kCgNBT6nU1shNumEchmW/sUO1JuQnPcw== dependencies: "@octokit/request" "^6.0.0" "@octokit/types" "^9.0.0" universal-user-agent "^6.0.0" -"@octokit/openapi-types@^16.0.0": - version "16.0.0" - resolved "https://registry.yarnpkg.com/@octokit/openapi-types/-/openapi-types-16.0.0.tgz#d92838a6cd9fb4639ca875ddb3437f1045cc625e" - integrity sha512-JbFWOqTJVLHZSUUoF4FzAZKYtqdxWu9Z5m2QQnOyEa04fOFljvyh7D3GYKbfuaSWisqehImiVIMG4eyJeP5VEA== - "@octokit/openapi-types@^18.0.0": version "18.1.1" resolved "https://registry.yarnpkg.com/@octokit/openapi-types/-/openapi-types-18.1.1.tgz#09bdfdabfd8e16d16324326da5148010d765f009" @@ -1424,9 +1318,9 @@ once "^1.4.0" "@octokit/request@^6.0.0": - version "6.2.3" - resolved "https://registry.yarnpkg.com/@octokit/request/-/request-6.2.3.tgz#76d5d6d44da5c8d406620a4c285d280ae310bdb4" - integrity sha512-TNAodj5yNzrrZ/VxP+H5HiYaZep0H3GU0O7PaF+fhDrt8FPrnkei9Aal/txsN/1P7V3CPiThG0tIvpPDYUsyAA== + version "6.2.8" + resolved "https://registry.yarnpkg.com/@octokit/request/-/request-6.2.8.tgz#aaf480b32ab2b210e9dadd8271d187c93171d8eb" + integrity sha512-ow4+pkVQ+6XVVsekSYBzJC0VTVvh/FCTUUgTsboGq+DTeWdyIFV8WSCdo0RIxk6wSkBTHqIK1mYuY7nOBXOchw== dependencies: "@octokit/endpoint" "^7.0.0" "@octokit/request-error" "^3.0.0" @@ -1457,14 +1351,7 @@ dependencies: "@octokit/openapi-types" "^18.0.0" -"@octokit/types@^9.0.0": - version "9.0.0" - resolved "https://registry.yarnpkg.com/@octokit/types/-/types-9.0.0.tgz#6050db04ddf4188ec92d60e4da1a2ce0633ff635" - integrity sha512-LUewfj94xCMH2rbD5YJ+6AQ4AVjFYTgpp6rboWM5T7N3IsIF65SBEOVcYMGAEzO/kKNiNaW4LoWtoThOhH06gw== - dependencies: - "@octokit/openapi-types" "^16.0.0" - -"@octokit/types@^9.2.3": +"@octokit/types@^9.0.0", "@octokit/types@^9.2.3": version "9.3.2" resolved "https://registry.yarnpkg.com/@octokit/types/-/types-9.3.2.tgz#3f5f89903b69f6a2d196d78ec35f888c0013cac5" integrity sha512-D4iHGTdAnEEVsB8fl95m1hiz7D5YiRdQ9b/OEb3BYRVwbLsGHcRVPz+u+BgRLNk0Q0/4iZCBqDN96j2XNxfXrA== @@ -1524,12 +1411,12 @@ integrity sha512-IFjIgTusQym2B5IZJG3XKr5llka7ey84fw/NOYqESP5WUfQs9zz1ww/9+qoz4ka/S6KcGBodzlCeZ5UImKbscg== "@relaycorp/ws-mock@^5.2.6": - version "5.2.6" - resolved "https://registry.yarnpkg.com/@relaycorp/ws-mock/-/ws-mock-5.2.6.tgz#eaabaf22e4c6d607d17c9e0ca65e3c76f7f6f4e1" - integrity sha512-qgwroa5EDCCUouzdz0IKOz8odIJekzn5JXwketTLx/M7ScCtxonqpBGni1M5K7vE72v5IJc+J17vJatHakbw8Q== + version "5.2.10" + resolved "https://registry.yarnpkg.com/@relaycorp/ws-mock/-/ws-mock-5.2.10.tgz#2e619a25cebddfbce1d2ba36f5161217b925e0e2" + integrity sha512-gJ02HJe9GKEyo4hIbm4Snufnts1muaqWb878gBslm3KTZPlZ3MckGYCr6X58rYMNgT4RwdlNp9v9IdAcPgH4Qg== dependencies: buffer-to-arraybuffer "0.0.6" - ws "^8.13.0" + ws "^8.16.0" "@resolver-engine/core@^0.3.3": version "0.3.3" @@ -1568,7 +1455,7 @@ path-browserify "^1.0.0" url "^0.11.0" -"@scure/base@~1.1.0", "@scure/base@~1.1.4": +"@scure/base@^1.1.1", "@scure/base@~1.1.0", "@scure/base@~1.1.4": version "1.1.5" resolved "https://registry.yarnpkg.com/@scure/base/-/base-1.1.5.tgz#1d85d17269fe97694b9c592552dd9e5e33552157" integrity sha512-Brj9FiG2W1MRQSTB212YVPRrcbjkv48FoZi/u4l/zds/ieRrqsh7aUf6CLwkAq61oKXr/ZlTzlY66gLIj3TFTQ== @@ -1723,12 +1610,19 @@ dependencies: type-detect "4.0.8" -"@sinonjs/fake-timers@^10.0.2": - version "10.0.2" - resolved "https://registry.yarnpkg.com/@sinonjs/fake-timers/-/fake-timers-10.0.2.tgz#d10549ed1f423d80639c528b6c7f5a1017747d0c" - integrity sha512-SwUDyjWnah1AaNl7kxsa7cfLhlTYoiyhDAIgyh+El30YvXs/o7OLXpYH88Zdhyx9JExKrmHDJ+10bwIcY80Jmw== +"@sinonjs/commons@^3.0.0": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-3.0.1.tgz#1029357e44ca901a615585f6d27738dbc89084cd" + integrity sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ== dependencies: - "@sinonjs/commons" "^2.0.0" + type-detect "4.0.8" + +"@sinonjs/fake-timers@^11.2.2": + version "11.2.2" + resolved "https://registry.yarnpkg.com/@sinonjs/fake-timers/-/fake-timers-11.2.2.tgz#50063cc3574f4a27bd8453180a04171c85cc9699" + integrity sha512-G2piCSxQ7oWOxwGSAyFHfPIsyeJGXYtc6mFbnFA+kRXkiEnTl8c/8jul2S329iFBnDI9HGoeWWAZvuvOkZccgw== + dependencies: + "@sinonjs/commons" "^3.0.0" "@sinonjs/fake-timers@^9.1.2": version "9.1.2" @@ -1746,7 +1640,7 @@ lodash.get "^4.4.2" type-detect "^4.0.8" -"@sinonjs/text-encoding@^0.7.1": +"@sinonjs/text-encoding@^0.7.2": version "0.7.2" resolved "https://registry.yarnpkg.com/@sinonjs/text-encoding/-/text-encoding-0.7.2.tgz#5981a8db18b56ba38ef0efb7d995b12aa7b51918" integrity sha512-sXXKG+uL9IrKqViTtao2Ws6dy0znu9sOaP1di/jKGW1M6VssO8vlpXCQcpZ+jisQ1tTFAC5Jo/EOzFbggBagFQ== @@ -1758,12 +1652,15 @@ dependencies: antlr4ts "^0.5.0-alpha.4" -"@solidity-parser/parser@^0.16.0": - version "0.16.0" - resolved "https://registry.yarnpkg.com/@solidity-parser/parser/-/parser-0.16.0.tgz#1fb418c816ca1fc3a1e94b08bcfe623ec4e1add4" - integrity sha512-ESipEcHyRHg4Np4SqBCfcXwyxxna1DgFVz69bgpLV8vzl/NP1DtcKsJ4dJZXWQhY/Z4J2LeKBiOkOVZn9ct33Q== - dependencies: - antlr4ts "^0.5.0-alpha.4" +"@solidity-parser/parser@^0.17.0": + version "0.17.0" + resolved "https://registry.yarnpkg.com/@solidity-parser/parser/-/parser-0.17.0.tgz#52a2fcc97ff609f72011014e4c5b485ec52243ef" + integrity sha512-Nko8R0/kUo391jsEHHxrGM07QFdnPGvlmox4rmH0kNiNAashItAilhy4Mv4pK5gQmW5f4sXAF58fwJbmlkGcVw== + +"@solidity-parser/parser@^0.18.0": + version "0.18.0" + resolved "https://registry.yarnpkg.com/@solidity-parser/parser/-/parser-0.18.0.tgz#8e77a02a09ecce957255a2f48c9a7178ec191908" + integrity sha512-yfORGUIPgLck41qyN7nbwJRAx17/jAIXCTanHOJZhB6PJ1iAk/84b/xlsVKFSyNyLXIj0dhppoE0+CRws7wlzA== "@tootallnate/once@2": version "2.0.0" @@ -1800,9 +1697,9 @@ integrity sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow== "@tsconfig/node16@^1.0.2": - version "1.0.3" - resolved "https://registry.yarnpkg.com/@tsconfig/node16/-/node16-1.0.3.tgz#472eaab5f15c1ffdd7f8628bd4c4f753995ec79e" - integrity sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ== + version "1.0.4" + resolved "https://registry.yarnpkg.com/@tsconfig/node16/-/node16-1.0.4.tgz#0b92dcc0cc1c81f6f306a381f28e31b1a56536e9" + integrity sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA== "@tufjs/canonical-json@1.0.0": version "1.0.0" @@ -1825,25 +1722,25 @@ lodash "^4.17.15" ts-essentials "^7.0.1" -"@typechain/ethers-v5@^10.2.0": - version "10.2.0" - resolved "https://registry.yarnpkg.com/@typechain/ethers-v5/-/ethers-v5-10.2.0.tgz#68f5963efb5214cb2d881477228e4b5b315473e1" - integrity sha512-ikaq0N/w9fABM+G01OFmU3U3dNnyRwEahkdvi9mqy1a3XwKiPZaF/lu54OcNaEWnpvEYyhhS0N7buCtLQqC92w== +"@typechain/ethers-v5@^11.1.2": + version "11.1.2" + resolved "https://registry.yarnpkg.com/@typechain/ethers-v5/-/ethers-v5-11.1.2.tgz#82510c1744f37a2f906b9e0532ac18c0b74ffe69" + integrity sha512-ID6pqWkao54EuUQa0P5RgjvfA3MYqxUQKpbGKERbsjBW5Ra7EIXvbMlPp2pcP5IAdUkyMCFYsP2SN5q7mPdLDQ== dependencies: lodash "^4.17.15" ts-essentials "^7.0.1" -"@typechain/hardhat@^6.1.5": - version "6.1.5" - resolved "https://registry.yarnpkg.com/@typechain/hardhat/-/hardhat-6.1.5.tgz#caad58a1d3e9cd88061a584eb4f4fa763d5dcad1" - integrity sha512-lg7LW4qDZpxFMknp3Xool61Fg6Lays8F8TXdFGBG+MxyYcYU5795P1U2XdStuzGq9S2Dzdgh+1jGww9wvZ6r4Q== +"@typechain/hardhat@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@typechain/hardhat/-/hardhat-7.0.0.tgz#ffa7465328150e793007fee616ae7b76ed20784d" + integrity sha512-XB79i5ewg9Met7gMVGfgVkmypicbnI25T5clJBEooMoW2161p4zvKFpoS2O+lBppQyMrPIZkdvl2M3LMDayVcA== dependencies: fs-extra "^9.1.0" "@types/abstract-leveldown@*": - version "7.2.1" - resolved "https://registry.yarnpkg.com/@types/abstract-leveldown/-/abstract-leveldown-7.2.1.tgz#bb16403c17754b0c4d5772d71d03b924a03d4c80" - integrity sha512-YK8irIC+eMrrmtGx0H4ISn9GgzLd9dojZWJaMbjp1YHLl2VqqNFBNrL5Q3KjGf4VE3sf/4hmq6EhQZ7kZp1NoQ== + version "7.2.5" + resolved "https://registry.yarnpkg.com/@types/abstract-leveldown/-/abstract-leveldown-7.2.5.tgz#db2cf364c159fb1f12be6cd3549f56387eaf8d73" + integrity sha512-/2B0nQF4UdupuxeKTJA2+Rj1D+uDemo6P4kMwKCpbfpnzeVaWSELTsAw4Lxn3VJD6APtRrZOCuYo+4nHUQfTfg== "@types/bn.js@^4.11.3": version "4.11.6" @@ -1860,9 +1757,9 @@ "@types/node" "*" "@types/chai@*": - version "4.3.4" - resolved "https://registry.yarnpkg.com/@types/chai/-/chai-4.3.4.tgz#e913e8175db8307d78b4e8fa690408ba6b65dee4" - integrity sha512-KnRanxnpfpjUTqTCXslZSEdLfXExwgNxYPdiO2WGUj8+HDjFi8R3k5RVKPeSCzLjCcshCAtVO2QBbVuAV4kTnw== + version "4.3.12" + resolved "https://registry.yarnpkg.com/@types/chai/-/chai-4.3.12.tgz#b192fe1c553b54f45d20543adc2ab88455a07d5e" + integrity sha512-zNKDHG/1yxm8Il6uCCVsm+dRdEsJlFoDu73X17y09bId6UwoYww+vFBsAcRzl8knM1sab3Dp1VRikFQwDOtDDw== "@types/concat-stream@^1.6.0": version "1.6.1" @@ -1872,12 +1769,19 @@ "@types/node" "*" "@types/connect@^3.4.33": - version "3.4.35" - resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.35.tgz#5fcf6ae445e4021d1fc2219a4873cc73a3bb2ad1" - integrity sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ== + version "3.4.38" + resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.38.tgz#5ba7f3bc4fbbdeaff8dded952e5ff2cc53f8d858" + integrity sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug== dependencies: "@types/node" "*" +"@types/debug@^4.1.9": + version "4.1.12" + resolved "https://registry.yarnpkg.com/@types/debug/-/debug-4.1.12.tgz#a155f21690871953410df4b6b6f53187f0500917" + integrity sha512-vIChWdVG3LG1SMxEvI/AK+FWJthlrqlTu7fbrlywTkkaONwk/UAGaULXRlf8vkzFBLVm0zkMdCquhL5aOjhXPQ== + dependencies: + "@types/ms" "*" + "@types/ethereumjs-util@^6.1.0": version "6.1.0" resolved "https://registry.yarnpkg.com/@types/ethereumjs-util/-/ethereumjs-util-6.1.0.tgz#9dabd7302ec9728a7d99be15f4143977c33cd5ac" @@ -1900,15 +1804,15 @@ "@types/minimatch" "*" "@types/node" "*" -"@types/json-schema@^7.0.9": - version "7.0.11" - resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.11.tgz#d421b6c527a3037f7c84433fd2c4229e016863d3" - integrity sha512-wOuvG1SN4Us4rez+tylwwwCV1psiNVOkJeM3AUWUNWg/jDQY2+HE/444y5gc+jBmRqASOm2Oeh5c1axHobwRKQ== +"@types/json-schema@^7.0.12": + version "7.0.15" + resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.15.tgz#596a1747233694d50f6ad8a7869fcb6f56cf5841" + integrity sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA== "@types/level-errors@*": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@types/level-errors/-/level-errors-3.0.0.tgz#15c1f4915a5ef763b51651b15e90f6dc081b96a8" - integrity sha512-/lMtoq/Cf/2DVOm6zE6ORyOM+3ZVm/BvzEZVxUhf6bgh8ZHglXlBqxbxSlJeVp8FCbD3IVvk/VbsaNmDjrQvqQ== + version "3.0.2" + resolved "https://registry.yarnpkg.com/@types/level-errors/-/level-errors-3.0.2.tgz#f33ec813c50780b547463da9ad8acac89ee457d9" + integrity sha512-gyZHbcQ2X5hNXf/9KS2qGEmgDe9EN2WDM3rJ5Ele467C0nA1sLhtmv1bZiPMDYfAYCfPWft0uQIaTvXbASSTRA== "@types/levelup@^4.3.0": version "4.3.3" @@ -1920,9 +1824,9 @@ "@types/node" "*" "@types/lodash@*": - version "4.14.194" - resolved "https://registry.yarnpkg.com/@types/lodash/-/lodash-4.14.194.tgz#b71eb6f7a0ff11bff59fc987134a093029258a76" - integrity sha512-r22s9tAS7imvBt2lyHC9B8AGwWnXaYb1tY09oyLkXDs4vArpYJzw09nj8MLx5VfciBPGIb+ZwG0ssYnEPJxn/g== + version "4.14.202" + resolved "https://registry.yarnpkg.com/@types/lodash/-/lodash-4.14.202.tgz#f09dbd2fb082d507178b2f2a5c7e74bd72ff98f8" + integrity sha512-OvlIYQK9tNneDlS0VN54LLd5uiPCBOp7gS5Z0f1mjoJYBrtStzgmJBxONW3U6OZqdtNzZPmn9BS/7WI7BFFcFQ== "@types/lru-cache@5.1.1", "@types/lru-cache@^5.1.0": version "5.1.1" @@ -1940,9 +1844,9 @@ integrity sha512-Klz949h02Gz2uZCMGwDUSDS1YBlTdDDgbWHi+81l29tQALUtvz4rAYi5uoVhE5Lagoq6DeqAUlbrHvW/mXDgdQ== "@types/minimist@^1.2.0": - version "1.2.2" - resolved "https://registry.yarnpkg.com/@types/minimist/-/minimist-1.2.2.tgz#ee771e2ba4b3dc5b372935d549fd9617bf345b8c" - integrity sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ== + version "1.2.5" + resolved "https://registry.yarnpkg.com/@types/minimist/-/minimist-1.2.5.tgz#ec10755e871497bcd83efe927e43ec46e8c0747e" + integrity sha512-hov8bUuiLiyFPGyFPE1lwWhmzYbirOXQNNo40+y3zow8aFVTeyn3VWL0VFFfdNddA8S4Vf0Tc062rzyNr7Paag== "@types/mkdirp@^0.5.2": version "0.5.2" @@ -1952,29 +1856,34 @@ "@types/node" "*" "@types/mocha@^10.0.1": - version "10.0.1" - resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-10.0.1.tgz#2f4f65bb08bc368ac39c96da7b2f09140b26851b" - integrity sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q== + version "10.0.6" + resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-10.0.6.tgz#818551d39113081048bdddbef96701b4e8bb9d1b" + integrity sha512-dJvrYWxP/UcXm36Qn36fxhUKu8A/xMRXVT2cliFF1Z7UA9liG5Psj3ezNSZw+5puH2czDXRLcXQxf8JbJt0ejg== "@types/mock-require@^2.0.0": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@types/mock-require/-/mock-require-2.0.1.tgz#1546819af1d8d5b124f5f70aff130cc77c53573e" - integrity sha512-O7U5DVGboY/Crueb5/huUCIRjKtRVRaLmRDbZJBlDQgJn966z3aiFDN+6AtYviu2ExwMkl34LjT/IiC0OPtKuQ== + version "2.0.3" + resolved "https://registry.yarnpkg.com/@types/mock-require/-/mock-require-2.0.3.tgz#00470eaeebd3f933b7d7a9d992ee16b6a098ac15" + integrity sha512-0Hd1krmO7Dwa8haImu+eZXZ6FeCtixS8S1xvM6LWNJE5DFV5A92/zpAkQCDPOA/Z13d1xY3LqS7hpSWqlDzxrQ== dependencies: "@types/node" "*" +"@types/ms@*": + version "0.7.34" + resolved "https://registry.yarnpkg.com/@types/ms/-/ms-0.7.34.tgz#10964ba0dee6ac4cd462e2795b6bebd407303433" + integrity sha512-nG96G3Wp6acyAgJqGasjODb+acrI7KltPiRxzHPXnP3NgI28bpQDRv53olbqGXbfcgF5aiiHmO3xpwEpS5Ld9g== + "@types/node-fetch@^2.6.1": - version "2.6.4" - resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.6.4.tgz#1bc3a26de814f6bf466b25aeb1473fa1afe6a660" - integrity sha512-1ZX9fcN4Rvkvgv4E6PAY5WXUFWFcRWxZa3EW83UjycOB9ljJCedb2CupIP4RZMEwF/M3eTcCihbBRgwtGbg5Rg== + version "2.6.11" + resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.6.11.tgz#9b39b78665dae0e82a08f02f4967d62c66f95d24" + integrity sha512-24xFj9R5+rfQJLRyM56qh+wnVSYhyXC2tkoBndtY0U+vubqNsYXGjufB2nn8Q6gt0LrARwL6UBtMCSVCwl4B1g== dependencies: "@types/node" "*" - form-data "^3.0.0" + form-data "^4.0.0" "@types/node@*": - version "20.10.5" - resolved "https://registry.yarnpkg.com/@types/node/-/node-20.10.5.tgz#47ad460b514096b7ed63a1dae26fad0914ed3ab2" - integrity sha512-nNPsNE65wjMxEKI93yOP+NPGGBJz/PoN3kZsVLee0XMiJolxSekEVD8wRwBUBqkwc7UWop0edW50yrCQW4CyRw== + version "20.11.24" + resolved "https://registry.yarnpkg.com/@types/node/-/node-20.11.24.tgz#cc207511104694e84e9fb17f9a0c4c42d4517792" + integrity sha512-Kza43ewS3xoLgCEpQrsT+xRo/EJej1y0kVYGiLFE1NEODXGzTfwiC6tXTLMQskn1X4/Rjlh0MQUvx9W+L9long== dependencies: undici-types "~5.26.4" @@ -1994,9 +1903,11 @@ integrity sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ== "@types/node@^18.15.11": - version "18.15.11" - resolved "https://registry.yarnpkg.com/@types/node/-/node-18.15.11.tgz#b3b790f09cb1696cffcec605de025b088fa4225f" - integrity sha512-E5Kwq2n4SbMzQOn6wnmBjuK9ouqlURrcZDVfbo9ftDDTFt3nk7ZKK4GMOzoYgnpQJKcxwQw+lGaBvvlMo0qN/Q== + version "18.19.21" + resolved "https://registry.yarnpkg.com/@types/node/-/node-18.19.21.tgz#f4ca1ac8ffb05ee4b89163c2d6fac9a1a59ee149" + integrity sha512-2Q2NeB6BmiTFQi4DHBzncSoq/cJMLDdhPaAoJFnFCyD9a8VPZRf7a1GAwp1Edb7ROaZc5Jz/tnZyL6EsWMRaqw== + dependencies: + undici-types "~5.26.4" "@types/node@^8.0.0": version "8.10.66" @@ -2004,9 +1915,9 @@ integrity sha512-tktOkFUA4kXx2hhhrB8bIFb5TbwzS4uOhKEmwiD+NoiL0qtP2OQ9mFldbgD4dV1djrlBYP6eBuQZiWjuHUpqFw== "@types/normalize-package-data@^2.4.0": - version "2.4.1" - resolved "https://registry.yarnpkg.com/@types/normalize-package-data/-/normalize-package-data-2.4.1.tgz#d3357479a0fdfdd5907fe67e17e0a85c906e1301" - integrity sha512-Gj7cI7z+98M282Tqmp2K5EIsoouUEzbBJhQQzDE3jSIRk6r9gsz0oUokqIUR4u1R3dMHo0pDHM7sNOHyhulypw== + version "2.4.4" + resolved "https://registry.yarnpkg.com/@types/normalize-package-data/-/normalize-package-data-2.4.4.tgz#56e2cc26c397c038fab0e3a917a12d5c5909e901" + integrity sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA== "@types/pbkdf2@^3.0.0": version "3.1.2" @@ -2016,14 +1927,14 @@ "@types/node" "*" "@types/prettier@^2.1.1": - version "2.7.2" - resolved "https://registry.yarnpkg.com/@types/prettier/-/prettier-2.7.2.tgz#6c2324641cc4ba050a8c710b2b251b377581fbf0" - integrity sha512-KufADq8uQqo1pYKVIYzfKbJfBAc0sOeXqGbFaSpv8MRmC/zXgowNZmFcbngndGk922QDmOASEXUZCaY48gs4cg== + version "2.7.3" + resolved "https://registry.yarnpkg.com/@types/prettier/-/prettier-2.7.3.tgz#3e51a17e291d01d17d3fc61422015a933af7a08f" + integrity sha512-+68kP9yzs4LMp7VNh8gdzMSPZFL44MLGqiHWvttYJe+6qnuVr4Ek9wSBQoveqY/r+LwjCcU29kNVkidwim+kYA== "@types/qs@^6.2.31": - version "6.9.7" - resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.7.tgz#63bb7d067db107cc1e457c303bc25d511febf6cb" - integrity sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw== + version "6.9.12" + resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.12.tgz#afa96b383a3a6fdc859453a1892d41b607fc7756" + integrity sha512-bZcOkJ6uWrL0Qb2NAWKa7TBU+mJHPzhx9jjLL1KHF+XpzEcR7EXHvjbHlGtR/IsP1vyPrehuS6XqkmaePy//mg== "@types/readable-stream@^2.3.13": version "2.3.15" @@ -2045,22 +1956,30 @@ resolved "https://registry.yarnpkg.com/@types/seedrandom/-/seedrandom-3.0.1.tgz#1254750a4fec4aff2ebec088ccd0bb02e91fedb4" integrity sha512-giB9gzDeiCeloIXDgzFBCgjj1k4WxcDrZtGl6h1IqmUPlxF+Nx8Ve+96QCyDZ/HseB/uvDsKbpib9hU5cU53pw== -"@types/semver@^7.3.12": - version "7.3.13" - resolved "https://registry.yarnpkg.com/@types/semver/-/semver-7.3.13.tgz#da4bfd73f49bd541d28920ab0e2bf0ee80f71c91" - integrity sha512-21cFJr9z3g5dW8B0CVI9g2O9beqaThGQ6ZFBqHfwhzLDKUxaqTIy3vnfah/UPkfOiF2pLq+tGz+W8RyCskuslw== +"@types/semver@^7.5.0": + version "7.5.8" + resolved "https://registry.yarnpkg.com/@types/semver/-/semver-7.5.8.tgz#8268a8c57a3e4abd25c165ecd36237db7948a55e" + integrity sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ== + +"@types/sinon-chai@^3.2.12": + version "3.2.12" + resolved "https://registry.yarnpkg.com/@types/sinon-chai/-/sinon-chai-3.2.12.tgz#c7cb06bee44a534ec84f3a5534c3a3a46fd779b6" + integrity sha512-9y0Gflk3b0+NhQZ/oxGtaAJDvRywCa5sIyaVnounqLvmf93yBF4EgIRspePtkMs3Tr844nCclYMlcCNmLCvjuQ== + dependencies: + "@types/chai" "*" + "@types/sinon" "*" "@types/sinon@*": - version "10.0.13" - resolved "https://registry.yarnpkg.com/@types/sinon/-/sinon-10.0.13.tgz#60a7a87a70d9372d0b7b38cc03e825f46981fb83" - integrity sha512-UVjDqJblVNQYvVNUsj0PuYYw0ELRmgt1Nt5Vk0pT5f16ROGfcKJY8o1HVuMOJOpD727RrGB9EGvoaTQE5tgxZQ== + version "17.0.3" + resolved "https://registry.yarnpkg.com/@types/sinon/-/sinon-17.0.3.tgz#9aa7e62f0a323b9ead177ed23a36ea757141a5fa" + integrity sha512-j3uovdn8ewky9kRBG19bOwaZbexJu/XjtkHyjvUgt4xfPFz18dcORIMqnYh66Fx3Powhcr85NT5+er3+oViapw== dependencies: "@types/sinonjs__fake-timers" "*" "@types/sinonjs__fake-timers@*": - version "8.1.2" - resolved "https://registry.yarnpkg.com/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.2.tgz#bf2e02a3dbd4aecaf95942ecd99b7402e03fad5e" - integrity sha512-9GcLXF0/v3t80caGs5p2rRfkB+a8VBGLJZVih6CNFkx8IZ994wiKKLSRs9nuFwk1HevWs/1mnUmkApGrSGsShA== + version "8.1.5" + resolved "https://registry.yarnpkg.com/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.5.tgz#5fd3592ff10c1e9695d377020c033116cc2889f2" + integrity sha512-mQkU2jY8jJEF7YHjHvsQO8+3ughTL1mcnn96igfhONmR+fUPSKIkefQYpSe8bsly2Ep7oQbn/6VG5/9/0qcArQ== "@types/ws@^7.4.4": version "7.4.7" @@ -2069,89 +1988,96 @@ dependencies: "@types/node" "*" -"@typescript-eslint/eslint-plugin@^5.58.0": - version "5.58.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.58.0.tgz#b1d4b0ad20243269d020ef9bbb036a40b0849829" - integrity sha512-vxHvLhH0qgBd3/tW6/VccptSfc8FxPQIkmNTVLWcCOVqSBvqpnKkBTYrhcGlXfSnd78azwe+PsjYFj0X34/njA== - dependencies: - "@eslint-community/regexpp" "^4.4.0" - "@typescript-eslint/scope-manager" "5.58.0" - "@typescript-eslint/type-utils" "5.58.0" - "@typescript-eslint/utils" "5.58.0" +"@typescript-eslint/eslint-plugin@^7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-7.1.0.tgz#22bb999a8d59893c0ea07923e8a21f9d985ad740" + integrity sha512-j6vT/kCulhG5wBmGtstKeiVr1rdXE4nk+DT1k6trYkwlrvW9eOF5ZbgKnd/YR6PcM4uTEXa0h6Fcvf6X7Dxl0w== + dependencies: + "@eslint-community/regexpp" "^4.5.1" + "@typescript-eslint/scope-manager" "7.1.0" + "@typescript-eslint/type-utils" "7.1.0" + "@typescript-eslint/utils" "7.1.0" + "@typescript-eslint/visitor-keys" "7.1.0" debug "^4.3.4" - grapheme-splitter "^1.0.4" - ignore "^5.2.0" - natural-compare-lite "^1.4.0" - semver "^7.3.7" - tsutils "^3.21.0" + graphemer "^1.4.0" + ignore "^5.2.4" + natural-compare "^1.4.0" + semver "^7.5.4" + ts-api-utils "^1.0.1" -"@typescript-eslint/parser@^5.58.0": - version "5.58.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.58.0.tgz#2ac4464cf48bef2e3234cb178ede5af352dddbc6" - integrity sha512-ixaM3gRtlfrKzP8N6lRhBbjTow1t6ztfBvQNGuRM8qH1bjFFXIJ35XY+FC0RRBKn3C6cT+7VW1y8tNm7DwPHDQ== +"@typescript-eslint/parser@^7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-7.1.0.tgz#b89dab90840f7d2a926bf4c23b519576e8c31970" + integrity sha512-V1EknKUubZ1gWFjiOZhDSNToOjs63/9O0puCgGS8aDOgpZY326fzFu15QAUjwaXzRZjf/qdsdBrckYdv9YxB8w== dependencies: - "@typescript-eslint/scope-manager" "5.58.0" - "@typescript-eslint/types" "5.58.0" - "@typescript-eslint/typescript-estree" "5.58.0" + "@typescript-eslint/scope-manager" "7.1.0" + "@typescript-eslint/types" "7.1.0" + "@typescript-eslint/typescript-estree" "7.1.0" + "@typescript-eslint/visitor-keys" "7.1.0" debug "^4.3.4" -"@typescript-eslint/scope-manager@5.58.0": - version "5.58.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.58.0.tgz#5e023a48352afc6a87be6ce3c8e763bc9e2f0bc8" - integrity sha512-b+w8ypN5CFvrXWQb9Ow9T4/6LC2MikNf1viLkYTiTbkQl46CnR69w7lajz1icW0TBsYmlpg+mRzFJ4LEJ8X9NA== +"@typescript-eslint/scope-manager@7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-7.1.0.tgz#e4babaa39a3d612eff0e3559f3e99c720a2b4a54" + integrity sha512-6TmN4OJiohHfoOdGZ3huuLhpiUgOGTpgXNUPJgeZOZR3DnIpdSgtt83RS35OYNNXxM4TScVlpVKC9jyQSETR1A== dependencies: - "@typescript-eslint/types" "5.58.0" - "@typescript-eslint/visitor-keys" "5.58.0" + "@typescript-eslint/types" "7.1.0" + "@typescript-eslint/visitor-keys" "7.1.0" -"@typescript-eslint/type-utils@5.58.0": - version "5.58.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.58.0.tgz#f7d5b3971483d4015a470d8a9e5b8a7d10066e52" - integrity sha512-FF5vP/SKAFJ+LmR9PENql7fQVVgGDOS+dq3j+cKl9iW/9VuZC/8CFmzIP0DLKXfWKpRHawJiG70rVH+xZZbp8w== +"@typescript-eslint/type-utils@7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-7.1.0.tgz#372dfa470df181bcee0072db464dc778b75ed722" + integrity sha512-UZIhv8G+5b5skkcuhgvxYWHjk7FW7/JP5lPASMEUoliAPwIH/rxoUSQPia2cuOj9AmDZmwUl1usKm85t5VUMew== dependencies: - "@typescript-eslint/typescript-estree" "5.58.0" - "@typescript-eslint/utils" "5.58.0" + "@typescript-eslint/typescript-estree" "7.1.0" + "@typescript-eslint/utils" "7.1.0" debug "^4.3.4" - tsutils "^3.21.0" + ts-api-utils "^1.0.1" -"@typescript-eslint/types@5.58.0": - version "5.58.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.58.0.tgz#54c490b8522c18986004df7674c644ffe2ed77d8" - integrity sha512-JYV4eITHPzVQMnHZcYJXl2ZloC7thuUHrcUmxtzvItyKPvQ50kb9QXBkgNAt90OYMqwaodQh2kHutWZl1fc+1g== +"@typescript-eslint/types@7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-7.1.0.tgz#52a86d6236fda646e7e5fe61154991dc0dc433ef" + integrity sha512-qTWjWieJ1tRJkxgZYXx6WUYtWlBc48YRxgY2JN1aGeVpkhmnopq+SUC8UEVGNXIvWH7XyuTjwALfG6bFEgCkQA== -"@typescript-eslint/typescript-estree@5.58.0": - version "5.58.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.58.0.tgz#4966e6ff57eaf6e0fce2586497edc097e2ab3e61" - integrity sha512-cRACvGTodA+UxnYM2uwA2KCwRL7VAzo45syNysqlMyNyjw0Z35Icc9ihPJZjIYuA5bXJYiJ2YGUB59BqlOZT1Q== +"@typescript-eslint/typescript-estree@7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-7.1.0.tgz#419b1310f061feee6df676c5bed460537310c593" + integrity sha512-k7MyrbD6E463CBbSpcOnwa8oXRdHzH1WiVzOipK3L5KSML92ZKgUBrTlehdi7PEIMT8k0bQixHUGXggPAlKnOQ== dependencies: - "@typescript-eslint/types" "5.58.0" - "@typescript-eslint/visitor-keys" "5.58.0" + "@typescript-eslint/types" "7.1.0" + "@typescript-eslint/visitor-keys" "7.1.0" debug "^4.3.4" globby "^11.1.0" is-glob "^4.0.3" - semver "^7.3.7" - tsutils "^3.21.0" + minimatch "9.0.3" + semver "^7.5.4" + ts-api-utils "^1.0.1" -"@typescript-eslint/utils@5.58.0": - version "5.58.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.58.0.tgz#430d7c95f23ec457b05be5520c1700a0dfd559d5" - integrity sha512-gAmLOTFXMXOC+zP1fsqm3VceKSBQJNzV385Ok3+yzlavNHZoedajjS4UyS21gabJYcobuigQPs/z71A9MdJFqQ== +"@typescript-eslint/utils@7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-7.1.0.tgz#710ecda62aff4a3c8140edabf3c5292d31111ddd" + integrity sha512-WUFba6PZC5OCGEmbweGpnNJytJiLG7ZvDBJJoUcX4qZYf1mGZ97mO2Mps6O2efxJcJdRNpqweCistDbZMwIVHw== + dependencies: + "@eslint-community/eslint-utils" "^4.4.0" + "@types/json-schema" "^7.0.12" + "@types/semver" "^7.5.0" + "@typescript-eslint/scope-manager" "7.1.0" + "@typescript-eslint/types" "7.1.0" + "@typescript-eslint/typescript-estree" "7.1.0" + semver "^7.5.4" + +"@typescript-eslint/visitor-keys@7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-7.1.0.tgz#576c4ad462ca1378135a55e2857d7aced96ce0a0" + integrity sha512-FhUqNWluiGNzlvnDZiXad4mZRhtghdoKW6e98GoEOYSu5cND+E39rG5KwJMUzeENwm1ztYBRqof8wMLP+wNPIA== dependencies: - "@eslint-community/eslint-utils" "^4.2.0" - "@types/json-schema" "^7.0.9" - "@types/semver" "^7.3.12" - "@typescript-eslint/scope-manager" "5.58.0" - "@typescript-eslint/types" "5.58.0" - "@typescript-eslint/typescript-estree" "5.58.0" - eslint-scope "^5.1.1" - semver "^7.3.7" + "@typescript-eslint/types" "7.1.0" + eslint-visitor-keys "^3.4.1" -"@typescript-eslint/visitor-keys@5.58.0": - version "5.58.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.58.0.tgz#eb9de3a61d2331829e6761ce7fd13061781168b4" - integrity sha512-/fBraTlPj0jwdyTwLyrRTxv/3lnU2H96pNTVM6z3esTWLtA5MZ9ghSMJ7Rb+TtUAdtEw9EyJzJ0EydIMKxQ9gA== - dependencies: - "@typescript-eslint/types" "5.58.0" - eslint-visitor-keys "^3.3.0" +"@ungap/structured-clone@^1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@ungap/structured-clone/-/structured-clone-1.2.0.tgz#756641adb587851b5ccb3e095daf27ae581c8406" + integrity sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ== "@uniswap/lib@1.1.1": version "1.1.1" @@ -2159,9 +2085,9 @@ integrity sha512-2yK7sLpKIT91TiS5sewHtOa7YuM8IuBXVl4GZv2jZFys4D2sY7K5vZh6MqD25TPA95Od+0YzCVq6cTF2IKrOmg== "@uniswap/token-lists@^1.0.0-beta.24": - version "1.0.0-beta.31" - resolved "https://registry.yarnpkg.com/@uniswap/token-lists/-/token-lists-1.0.0-beta.31.tgz#ff3852bd505ec7b4c276625c762ea79a93a919ec" - integrity sha512-BQVoelKCRf64IToPEs1wxiXOnhr/ukwPOF78XG11PrTAOL4F8umjYKFb8ZPv1/dIJsPaC7GhLSriEqyp94SasQ== + version "1.0.0-beta.33" + resolved "https://registry.yarnpkg.com/@uniswap/token-lists/-/token-lists-1.0.0-beta.33.tgz#966ba96c9ccc8f0e9e09809890b438203f2b1911" + integrity sha512-JQkXcpRI3jFG8y3/CGC4TS8NkDgcxXaOQuYW8Qdvd6DcDiIyg2vVYCG9igFEzF0G6UvxgHkBKC7cWCgzZNYvQg== "@uniswap/v2-core@1.0.0": version "1.0.0" @@ -2214,19 +2140,6 @@ abbrev@1.0.x: resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz#91b4792588a7738c25f35dd6f63752a2f8776135" integrity sha512-LEyx4aLEC3x6T0UguF6YILf+ntvmOaWsVfENmIW0E9H09vKlLDGelMjjSm0jkDHALj8A8quZ/HapKNigzwge+Q== -abstract-level@^1.0.0, abstract-level@^1.0.2, abstract-level@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/abstract-level/-/abstract-level-1.0.3.tgz#78a67d3d84da55ee15201486ab44c09560070741" - integrity sha512-t6jv+xHy+VYwc4xqZMn2Pa9DjcdzvzZmQGRjTFc8spIbRGHgBrEKbPq+rYXc7CCo0lxgYvSgKVg9qZAhpVQSjA== - dependencies: - buffer "^6.0.3" - catering "^2.1.0" - is-buffer "^2.0.5" - level-supports "^4.0.0" - level-transcoder "^1.0.1" - module-error "^1.0.1" - queue-microtask "^1.2.3" - abstract-leveldown@^6.2.1: version "6.3.0" resolved "https://registry.yarnpkg.com/abstract-leveldown/-/abstract-leveldown-6.3.0.tgz#d25221d1e6612f820c35963ba4bd739928f6026a" @@ -2275,25 +2188,20 @@ acorn-jsx@^5.3.2: integrity sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ== acorn-walk@^8.1.1: - version "8.2.0" - resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-8.2.0.tgz#741210f2e2426454508853a2f44d0ab83b7f69c1" - integrity sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA== + version "8.3.2" + resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-8.3.2.tgz#7703af9415f1b6db9315d6895503862e231d34aa" + integrity sha512-cjkyv4OtNCIeqhHrfS81QWXoCBPExR/J62oyEqepVw8WaQeSqpW2uhuLPh1m9eWhDuOo/jUXVTlifvesOWp/4A== -acorn@^8.4.1, acorn@^8.8.0: - version "8.8.2" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.8.2.tgz#1b2f25db02af965399b9776b0c2c391276d37c4a" - integrity sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw== +acorn@^8.4.1, acorn@^8.9.0: + version "8.11.3" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.11.3.tgz#71e0b14e13a4ec160724b38fb7b0f233b1b81d7a" + integrity sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg== add-stream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/add-stream/-/add-stream-1.0.0.tgz#6a7990437ca736d5e1288db92bd3266d5f5cb2aa" integrity sha512-qQLMr+8o0WC4FZGQTcJiKBVC59JylcPSrTtk6usvmIDFUOCKegapy1VHQwRbFMOFyb/inzUVqHs+eMYKDM1YeQ== -address@^1.0.1: - version "1.2.2" - resolved "https://registry.yarnpkg.com/address/-/address-1.2.2.tgz#2b5248dac5485a6390532c6a517fda2e3faac89e" - integrity sha512-4B/qKCfeE/ODUaAUpSwfzazo5x29WD4r3vXiWsB7I2mSDAihwEqKO+g8GELZUQSSAo5e1XTYh3ZVfLyxBc12nA== - adm-zip@^0.4.16: version "0.4.16" resolved "https://registry.yarnpkg.com/adm-zip/-/adm-zip-0.4.16.tgz#cf4c508fdffab02c269cbc7f471a875f05570365" @@ -2312,12 +2220,10 @@ agent-base@6, agent-base@^6.0.2: debug "4" agentkeepalive@^4.2.1: - version "4.3.0" - resolved "https://registry.yarnpkg.com/agentkeepalive/-/agentkeepalive-4.3.0.tgz#bb999ff07412653c1803b3ced35e50729830a255" - integrity sha512-7Epl1Blf4Sy37j4v9f9FjICCh4+KAQOyXgHEwlyBiAQLbhKdq/i2QQU3amQalS/wPhdPzDXPL5DMR5bkn+YeWg== + version "4.5.0" + resolved "https://registry.yarnpkg.com/agentkeepalive/-/agentkeepalive-4.5.0.tgz#2673ad1389b3c418c5a20c5d7364f93ca04be923" + integrity sha512-5GG/5IbQQpC9FpkRGsSvZI5QYeSCzlJHdpBQntCsuTOxhKD8lqKhrleg2Yi7yvMIf82Ycmmqln9U8V9qwEiJew== dependencies: - debug "^4.1.0" - depd "^2.0.0" humanize-ms "^1.2.1" aggregate-error@^3.0.0: @@ -2328,7 +2234,7 @@ aggregate-error@^3.0.0: clean-stack "^2.0.0" indent-string "^4.0.0" -ajv@^6.10.0, ajv@^6.12.3, ajv@^6.12.4: +ajv@^6.12.3, ajv@^6.12.4: version "6.12.6" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== @@ -2353,6 +2259,13 @@ amdefine@>=0.0.4: resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" integrity sha512-S2Hw0TtNkMJhIabBwIojKL9YHO5T0n5eNqWJ7Lrlel/zDbftQpxpapi8tZs3X1HWa+u+QeydGmzzNU0m09+Rcg== +ansi-align@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/ansi-align/-/ansi-align-3.0.1.tgz#0cdf12e111ace773a86e9a1fad1225c43cb19a59" + integrity sha512-IOfwwBF5iczOjp/WeY4YxyjqAFMQoZufdQWDd19SEExbVLNXqvpzSJ/M7Za4/sCPmQ0+GRquoA7bGcINcxew6w== + dependencies: + string-width "^4.1.0" + ansi-bgblack@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/ansi-bgblack/-/ansi-bgblack-0.1.1.tgz#a68ba5007887701b6aafbe3fa0dadfdfa8ee3ca2" @@ -2430,11 +2343,6 @@ ansi-bold@^0.1.1: dependencies: ansi-wrap "0.1.0" -ansi-colors@3.2.3: - version "3.2.3" - resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-3.2.3.tgz#57d35b8686e851e2cc04c403f1c00203976a1813" - integrity sha512-LEHHyuhlPY3TmuUYMh2oz89lTShfvgbmzaBcxve9t/9Wuy7Dwf4yoAKcND7KFT1HAQfqZ12qtc+DUrBMeKF9nw== - ansi-colors@4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-4.1.1.tgz#cbb9ae256bf750af1eab344f229aa27fe94ba348" @@ -2555,16 +2463,16 @@ ansi-red@^0.1.1: dependencies: ansi-wrap "0.1.0" +ansi-regex@^2.0.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" + integrity sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA== + ansi-regex@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.1.tgz#123d6479e92ad45ad897d4054e3c7ca7db4944e1" integrity sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw== -ansi-regex@^4.1.0: - version "4.1.1" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.1.tgz#164daac87ab2d6f6db3a29875e2d1766582dabed" - integrity sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g== - ansi-regex@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" @@ -2589,7 +2497,7 @@ ansi-strikethrough@^0.1.1: dependencies: ansi-wrap "0.1.0" -ansi-styles@^3.2.0, ansi-styles@^3.2.1: +ansi-styles@^3.2.1: version "3.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== @@ -2644,7 +2552,7 @@ antlr4ts@^0.5.0-alpha.4: resolved "https://registry.yarnpkg.com/antlr4ts/-/antlr4ts-0.5.0-alpha.4.tgz#71702865a87478ed0b40c0709f422cf14d51652a" integrity sha512-WPQDt1B74OfPv/IMS2ekXAKkTZIHl88uMetg6q3OTqgFxZ/dxDXI0EWLyZid/1Pe6hTftyg5N7gel5wNAGxXyQ== -anymatch@~3.1.1, anymatch@~3.1.2: +anymatch@~3.1.2: version "3.1.3" resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.3.tgz#790c58b19ba1720a84205b57c618d5ad8524973e" integrity sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw== @@ -2704,14 +2612,6 @@ array-back@^4.0.1, array-back@^4.0.2: resolved "https://registry.yarnpkg.com/array-back/-/array-back-4.0.2.tgz#8004e999a6274586beeb27342168652fdb89fa1e" integrity sha512-NbdMezxqf94cnNfWLL7V/im0Ub+Anbb0IoZhvzie8+4HJ4nMQuzHuy49FkGYCJK2yAloZ3meiB6AVMClbrI1vg== -array-buffer-byte-length@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz#fabe8bc193fea865f317fe7807085ee0dee5aead" - integrity sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A== - dependencies: - call-bind "^1.0.2" - is-array-buffer "^3.0.1" - array-differ@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-3.0.0.tgz#3cbb3d0f316810eafcc47624734237d6aee4ae6b" @@ -2737,17 +2637,6 @@ array-uniq@1.0.3: resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" integrity sha512-MNha4BWQ6JbwhFhj03YK552f7cb3AzoE8SzeljgChvL1dl3IcvggXVz1DilzySZkCja+CXuZbdW7yATchWn8/Q== -array.prototype.reduce@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/array.prototype.reduce/-/array.prototype.reduce-1.0.5.tgz#6b20b0daa9d9734dd6bc7ea66b5bbce395471eac" - integrity sha512-kDdugMl7id9COE8R7MHF5jWk7Dqt/fs4Pv+JXoICnYwqpjjjbUurz6w5fT5IG6brLdJhv6/VoHB0H7oyIBXd+Q== - dependencies: - call-bind "^1.0.2" - define-properties "^1.1.4" - es-abstract "^1.20.4" - es-array-method-boxes-properly "^1.0.0" - is-string "^1.0.7" - arrify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" @@ -2805,9 +2694,9 @@ async@^2.4.0: lodash "^4.17.14" async@^3.2.3: - version "3.2.4" - resolved "https://registry.yarnpkg.com/async/-/async-3.2.4.tgz#2d22e00f8cddeb5fde5dd33522b56d1cf569a81c" - integrity sha512-iAB+JbDEGXhyIUavoDl9WP/Jj106Kz9DEn1DPgYw5ruDn0e3Wgi3sKFm55sASdGBNOQB8F59d9qQ7deqrHA8wQ== + version "3.2.5" + resolved "https://registry.yarnpkg.com/async/-/async-3.2.5.tgz#ebd52a8fdaf7a2289a24df399f8d8485c8a46b66" + integrity sha512-baNZyqaaLhyLVKm/DlvdW051MSgO6b8eVfIezl9E5PqWxFgzLm/wQntEW4zOytVburDEr0JlALEpdOFwvErLsg== asynckit@^0.4.0: version "0.4.0" @@ -2819,11 +2708,6 @@ at-least-node@^1.0.0: resolved "https://registry.yarnpkg.com/at-least-node/-/at-least-node-1.0.0.tgz#602cd4b46e844ad4effc92a8011a3c46e0238dc2" integrity sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg== -available-typed-arrays@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz#92f95616501069d07d10edb2fc37d3e1c65123b7" - integrity sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw== - aws-sign2@~0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" @@ -2834,12 +2718,12 @@ aws4@^1.8.0: resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.12.0.tgz#ce1c9d143389679e253b314241ea9aa5cec980d3" integrity sha512-NmWvPnx0F1SfrQbYwOi7OeaNGokp9XhzNioJ/CSBs8Qa4vxug81mhJEAVZwxXuBmYB5KDRfMq/F3RR0BIU7sWg== -axios@^1.0.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/axios/-/axios-1.6.0.tgz#f1e5292f26b2fd5c2e66876adc5b06cdbd7d2102" - integrity sha512-EZ1DYihju9pwVB+jg67ogm+Tmqc6JmhamRN6I4Zt8DfZu5lbcQGw3ozH9lFejSJgs/ibaef3A9PMXPLeefFGJg== +axios@^1.0.0, axios@^1.5.1: + version "1.6.7" + resolved "https://registry.yarnpkg.com/axios/-/axios-1.6.7.tgz#7b48c2e27c96f9c68a2f8f31e2ab19f59b06b0a7" + integrity sha512-/hDJGff6/c7u0hDkvkGxR/oy6CbCs8ziCsC7SqmhjfozqiJGc8Z11wrv9z9lYfY4K8l+H9TpjcMDX0xOZmx+RA== dependencies: - follow-redirects "^1.15.0" + follow-redirects "^1.15.4" form-data "^4.0.0" proxy-from-env "^1.1.0" @@ -2877,15 +2761,15 @@ before-after-hook@^2.2.0: resolved "https://registry.yarnpkg.com/before-after-hook/-/before-after-hook-2.2.3.tgz#c51e809c81a4e354084422b9b26bad88249c517c" integrity sha512-NzUnlZexiaH/46WDhANlyR2bXRopNg4F/zuSA3OpZnllCUgRaOF2znDioDWrmbNVsuZk6l9pMquQB38cfBZwkQ== -bigint-crypto-utils@^3.0.23: +bigint-crypto-utils@^3.2.2: version "3.3.0" resolved "https://registry.yarnpkg.com/bigint-crypto-utils/-/bigint-crypto-utils-3.3.0.tgz#72ad00ae91062cf07f2b1def9594006c279c1d77" integrity sha512-jOTSb+drvEDxEq6OuUybOAv/xxoh3cuYRUIPyu8sSHQNKM303UQ2R1DAo45o1AkcIXw6fzbaFI1+xGGdaXs2lg== bignumber.js@^9.0.0, bignumber.js@^9.0.1: - version "9.1.1" - resolved "https://registry.yarnpkg.com/bignumber.js/-/bignumber.js-9.1.1.tgz#c4df7dc496bd849d4c9464344c1aa74228b4dac6" - integrity sha512-pHm4LsMJ6lzgNGVfZHjMoO8sdoRhOzOH4MLmY65Jg70bpxCKu5iOHNJyfF6OyvYw7t8Fpf35RuzUyqnQsj8Vig== + version "9.1.2" + resolved "https://registry.yarnpkg.com/bignumber.js/-/bignumber.js-9.1.2.tgz#b7c4242259c008903b13707983b5f4bbd31eda0c" + integrity sha512-2/mKyZH9K85bzOEfhXDBFZTGd1CTs+5IHpeFQo9luiBG7hghdC851Pj2WAhb6E3R6b9tZj/XKhbg4fum+Kepug== binary-extensions@^2.0.0: version "2.2.0" @@ -2916,12 +2800,17 @@ blakejs@^1.1.0: resolved "https://registry.yarnpkg.com/blakejs/-/blakejs-1.2.1.tgz#5057e4206eadb4a97f7c0b6e197a505042fc3814" integrity sha512-QXUSXI3QVc/gJME0dBpXrag1kbzOqCjCX8/b54ntNyW6sjtoqxqRk3LTmXzaJoh71zMsDCjM+47jS7XiwN/+fQ== +bluebird@^3.5.2: + version "3.7.2" + resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.7.2.tgz#9f229c15be272454ffa973ace0dbee79a1b0c36f" + integrity sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg== + bn.js@4.11.6: version "4.11.6" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.6.tgz#53344adb14617a13f6e8dd2ce28905d1c0ba3215" integrity sha512-XWwnNNFCuuSQ0m3r3C4LE3EiORltHd9M05pq6FOlVeiophzRbMo50Sbz1ehl8K3Z+jw9+vmgnXefY1hz8X+2wA== -bn.js@^4.0.0, bn.js@^4.11.0, bn.js@^4.11.1, bn.js@^4.11.8, bn.js@^4.11.9: +bn.js@^4.0.0, bn.js@^4.11.0, bn.js@^4.11.1, bn.js@^4.11.8, bn.js@^4.11.9, bn.js@^4.12.0: version "4.12.0" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.12.0.tgz#775b3f278efbb9718eec7361f483fb36fbbfea88" integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== @@ -2931,25 +2820,7 @@ bn.js@^5.1.2, bn.js@^5.2.0, bn.js@^5.2.1: resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.2.1.tgz#0bc527a6a0d18d0aa8d5b0538ce4a77dccfa7b70" integrity sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ== -body-parser@1.20.1: - version "1.20.1" - resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.20.1.tgz#b1812a8912c195cd371a3ee5e66faa2338a5c668" - integrity sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw== - dependencies: - bytes "3.1.2" - content-type "~1.0.4" - debug "2.6.9" - depd "2.0.0" - destroy "1.2.0" - http-errors "2.0.0" - iconv-lite "0.4.24" - on-finished "2.4.1" - qs "6.11.0" - raw-body "2.5.1" - type-is "~1.6.18" - unpipe "1.0.0" - -body-parser@^1.20.1: +body-parser@1.20.2, body-parser@^1.20.1: version "1.20.2" resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.20.2.tgz#6feb0e21c4724d06de7ff38da36dad4f57a747fd" integrity sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA== @@ -2967,6 +2838,20 @@ body-parser@^1.20.1: type-is "~1.6.18" unpipe "1.0.0" +boxen@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/boxen/-/boxen-5.1.2.tgz#788cb686fc83c1f486dfa8a40c68fc2b831d2b50" + integrity sha512-9gYgQKXx+1nP8mP7CzFyaUARhg7D3n1dF/FnErWmu9l6JvGpNUN278h0aSb+QjoiKSWG+iZ3uHrcqk0qrY9RQQ== + 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" + brace-expansion@^1.1.7: version "1.1.11" resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" @@ -2994,16 +2879,6 @@ brorand@^1.0.1, brorand@^1.1.0: resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f" integrity sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w== -browser-level@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/browser-level/-/browser-level-1.0.1.tgz#36e8c3183d0fe1c405239792faaab5f315871011" - integrity sha512-XECYKJ+Dbzw0lbydyQuJzwNXtOpbMSq737qxJN11sIRTErOMShvDpbzTlgju7orJKvx4epULolZAuJGLzCmWRQ== - dependencies: - abstract-level "^1.0.2" - catering "^2.1.1" - module-error "^1.0.2" - run-parallel-limit "^1.1.0" - browser-or-node@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/browser-or-node/-/browser-or-node-2.1.1.tgz#738790b3a86a8fc020193fa581273fbe65eaea0f" @@ -3088,9 +2963,9 @@ bufferutil@4.0.5: node-gyp-build "^4.3.0" bufferutil@^4.0.1: - version "4.0.7" - resolved "https://registry.yarnpkg.com/bufferutil/-/bufferutil-4.0.7.tgz#60c0d19ba2c992dd8273d3f73772ffc894c153ad" - integrity sha512-kukuqc39WOHtdxtw4UScxF/WVnMFVSQVKhtx3AjZJzhd0RGZZldcrfSEbVsWWe6KNH253574cq5F+wpv0G9pJw== + version "4.0.8" + resolved "https://registry.yarnpkg.com/bufferutil/-/bufferutil-4.0.8.tgz#1de6a71092d65d7766c4d8a522b261a6e787e8ea" + integrity sha512-4T53u4PdgsXqKaIctwF8ifXlRTTmEPJ8iEPWFdGZvcf7sbwYo6FKFEX9eNNAnzFZ7EzJAQ3CJeOtCRA4rDp7Pw== dependencies: node-gyp-build "^4.3.0" @@ -3141,40 +3016,33 @@ cacache@^16.1.0: unique-filename "^2.0.0" cacache@^17.0.0: - version "17.0.5" - resolved "https://registry.yarnpkg.com/cacache/-/cacache-17.0.5.tgz#6dbec26c11f1f6a2b558bc11ed3316577c339ebc" - integrity sha512-Y/PRQevNSsjAPWykl9aeGz8Pr+OI6BYM9fYDNMvOkuUiG9IhG4LEmaYrZZZvioMUEQ+cBCxT0v8wrnCURccyKA== + version "17.1.4" + resolved "https://registry.yarnpkg.com/cacache/-/cacache-17.1.4.tgz#b3ff381580b47e85c6e64f801101508e26604b35" + integrity sha512-/aJwG2l3ZMJ1xNAnqbMpA40of9dj/pIH3QfiuQSqjfPJF747VR0J/bHn+/KdNnHKc6XQcWt/AfRSBft82W1d2A== dependencies: "@npmcli/fs" "^3.1.0" fs-minipass "^3.0.0" - glob "^9.3.1" + glob "^10.2.2" lru-cache "^7.7.1" - minipass "^4.0.0" + minipass "^7.0.3" minipass-collect "^1.0.2" minipass-flush "^1.0.5" minipass-pipeline "^1.2.4" p-map "^4.0.0" - promise-inflight "^1.0.1" ssri "^10.0.0" tar "^6.1.11" unique-filename "^3.0.0" -call-bind@^1.0.0: - version "1.0.5" - resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.5.tgz#6fa2b7845ce0ea49bf4d8b9ef64727a2c2e2e513" - integrity sha512-C3nQxfFZxFRVoJoGKKI8y3MOEo129NQ+FgQ08iye+Mk4zNZZGdjfs06bVTr+DBSlA66Q2VEcMki/cUCP4SercQ== +call-bind@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.7.tgz#06016599c40c56498c18769d2730be242b6fa3b9" + integrity sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w== dependencies: + es-define-property "^1.0.0" + es-errors "^1.3.0" function-bind "^1.1.2" - get-intrinsic "^1.2.1" - set-function-length "^1.1.1" - -call-bind@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" - integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== - dependencies: - function-bind "^1.1.1" - get-intrinsic "^1.0.2" + get-intrinsic "^1.2.4" + set-function-length "^1.2.1" callsites@^3.0.0: version "3.1.0" @@ -3190,27 +3058,27 @@ camelcase-keys@^6.2.2: map-obj "^4.0.0" quick-lru "^4.0.1" -camelcase@^5.0.0, camelcase@^5.3.1: +camelcase@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" + integrity sha512-4nhGqUkc4BqbBBB4Q6zLuD7lzzrHYrjKGeYaEji/3tFR5VdJu9v+LilhGIVe8wxEJPPOeWo7eg8dwY13TZ1BNg== + +camelcase@^5.3.1: version "5.3.1" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== -camelcase@^6.0.0: +camelcase@^6.0.0, camelcase@^6.2.0: version "6.3.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.3.0.tgz#5685b95eb209ac9c0c177467778c9c84df58ba9a" integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== -case@^1.6.3: - version "1.6.3" - resolved "https://registry.yarnpkg.com/case/-/case-1.6.3.tgz#0a4386e3e9825351ca2e6216c60467ff5f1ea1c9" - integrity sha512-mzDSXIPaFwVDvZAHqZ9VlbyF4yyXRuX6IvB06WvPYkqJVO24kX1PPhv9bfpKNFZyxYFmmgo03HUiD8iklmJYRQ== - caseless@^0.12.0, caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" integrity sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw== -catering@^2.0.0, catering@^2.1.0, catering@^2.1.1: +catering@^2.0.0, catering@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/catering/-/catering-2.1.1.tgz#66acba06ed5ee28d5286133982a927de9a04b510" integrity sha512-K7Qy8O9p76sL3/3m7/zLKbRkyOlSZAgzEaLhyj2mXS8PsCud2Eo4hAb8aLtZqHh0QGqLcb9dlJSu6lHRVENm1w== @@ -3223,17 +3091,17 @@ cbor@^8.1.0: nofilter "^3.1.0" chai@^4.3.6: - version "4.3.7" - resolved "https://registry.yarnpkg.com/chai/-/chai-4.3.7.tgz#ec63f6df01829088e8bf55fca839bcd464a8ec51" - integrity sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A== + version "4.4.1" + resolved "https://registry.yarnpkg.com/chai/-/chai-4.4.1.tgz#3603fa6eba35425b0f2ac91a009fe924106e50d1" + integrity sha512-13sOfMv2+DWduEU+/xbun3LScLoqN17nBeTLUsmDfKdoiC1fr0n9PU4guu4AhRcOVFk/sW8LyZWHuhWtQZiF+g== dependencies: assertion-error "^1.1.0" - check-error "^1.0.2" - deep-eql "^4.1.2" - get-func-name "^2.0.0" - loupe "^2.3.1" + check-error "^1.0.3" + deep-eql "^4.1.3" + get-func-name "^2.0.2" + loupe "^2.3.6" pathval "^1.1.1" - type-detect "^4.0.5" + type-detect "^4.0.8" chalk@4.1.0: version "4.1.0" @@ -3243,7 +3111,7 @@ chalk@4.1.0: ansi-styles "^4.1.0" supports-color "^7.1.0" -chalk@^2.0.0, chalk@^2.4.2: +chalk@^2.4.2: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== @@ -3270,10 +3138,12 @@ chardet@^0.7.0: resolved "https://registry.yarnpkg.com/charenc/-/charenc-0.0.2.tgz#c0a1d2f3a7092e03774bfa83f14c0fc5790a8667" integrity sha512-yrLQ/yVUFXkzg7EDQsPieE/53+0RlaWTs+wBrvW36cyilJ2SaDWfl4Yj7MtLTXleV9uEKefbAGUPv2/iWSooRA== -check-error@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/check-error/-/check-error-1.0.2.tgz#574d312edd88bb5dd8912e9286dd6c0aed4aac82" - integrity sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA== +check-error@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/check-error/-/check-error-1.0.3.tgz#a6502e4312a7ee969f646e83bb3ddd56281bd694" + integrity sha512-iKEoDYaRmd1mxM90a2OEfWhjsjPpYPuQ+lMYsoxB126+t8fw7ySEO48nmDg5COTjxDI65/Y2OWpeEHk3ZOe8zg== + dependencies: + get-func-name "^2.0.2" choices-separator@^2.0.0: version "2.0.0" @@ -3284,25 +3154,25 @@ choices-separator@^2.0.0: debug "^2.6.6" strip-color "^0.1.0" -chokidar@3.3.0: - version "3.3.0" - resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.3.0.tgz#12c0714668c55800f659e262d4962a97faf554a6" - integrity sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A== +chokidar@3.5.3: + version "3.5.3" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.5.3.tgz#1cf37c8707b932bd1af1ae22c0432e2acd1903bd" + integrity sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw== dependencies: - anymatch "~3.1.1" + anymatch "~3.1.2" braces "~3.0.2" - glob-parent "~5.1.0" + glob-parent "~5.1.2" is-binary-path "~2.1.0" is-glob "~4.0.1" normalize-path "~3.0.0" - readdirp "~3.2.0" + readdirp "~3.6.0" optionalDependencies: - fsevents "~2.1.1" + fsevents "~2.3.2" -chokidar@3.5.3, chokidar@^3.4.0: - version "3.5.3" - resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.5.3.tgz#1cf37c8707b932bd1af1ae22c0432e2acd1903bd" - integrity sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw== +chokidar@^3.4.0: + version "3.6.0" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.6.0.tgz#197c6cc669ef2a8dc5e7b4d97ee4e092c3eb0d5b" + integrity sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw== dependencies: anymatch "~3.1.2" braces "~3.0.2" @@ -3325,9 +3195,9 @@ ci-info@^2.0.0: integrity sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ== ci-info@^3.2.0, ci-info@^3.6.1: - version "3.8.0" - resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-3.8.0.tgz#81408265a5380c929f0bc665d62256628ce9ef91" - integrity sha512-eXTggHWSooYhq49F2opQhuHWgzucfF2YgODK4e1566GQs5BIfP30B0oenwBJHfWxAs2fyPB1s7Mg949zLf61Yw== + version "3.9.0" + resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-3.9.0.tgz#4279a62028a7b1f262f3473fc9605f5e218c59b4" + integrity sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ== cipher-base@^1.0.0, cipher-base@^1.0.1, cipher-base@^1.0.3: version "1.0.4" @@ -3337,22 +3207,16 @@ cipher-base@^1.0.0, cipher-base@^1.0.1, cipher-base@^1.0.3: inherits "^2.0.1" safe-buffer "^5.0.1" -classic-level@^1.2.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/classic-level/-/classic-level-1.3.0.tgz#5e36680e01dc6b271775c093f2150844c5edd5c8" - integrity sha512-iwFAJQYtqRTRM0F6L8h4JCt00ZSGdOyqh7yVrhhjrOpFhmBjNlRUey64MCiyo6UmQHMJ+No3c81nujPv+n9yrg== - dependencies: - abstract-level "^1.0.2" - catering "^2.1.0" - module-error "^1.0.1" - napi-macros "^2.2.2" - node-gyp-build "^4.3.0" - clean-stack@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/clean-stack/-/clean-stack-2.2.0.tgz#ee8472dbb129e727b31e8a10a427dee9dfe4008b" integrity sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A== +cli-boxes@^2.2.1: + version "2.2.1" + resolved "https://registry.yarnpkg.com/cli-boxes/-/cli-boxes-2.2.1.tgz#ddd5035d25094fce220e9cab40a45840a440318f" + integrity sha512-y4coMcylgSCdVinjiDBuR8PCC2bLjyGTwEmPb9NHR/QaNU6EUOXcTY/s6VjGMD6ENSEaeQYHCY0GNGS5jfMwPw== + cli-cursor@3.1.0, cli-cursor@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-3.1.0.tgz#264305a7ae490d1d03bf0c9ba7c925d1753af307" @@ -3366,9 +3230,9 @@ cli-spinners@2.6.1: integrity sha512-x/5fWmGMnbKQAaNwN+UZlV79qBLM9JFnJuJ03gIi5whrob0xV0ofNVHy9DhwGdsMJQc2OKv0oGmLzvaqvAVv+g== cli-spinners@^2.5.0: - version "2.8.0" - resolved "https://registry.yarnpkg.com/cli-spinners/-/cli-spinners-2.8.0.tgz#e97a3e2bd00e6d85aa0c13d7f9e3ce236f7787fc" - integrity sha512-/eG5sJcvEIwxcdYM86k5tPwn0MUzkX5YY3eImTGpJOZgVe4SdTMY14vQpcxgBzJ0wXwAYrS8E+c3uHeK4JNyzQ== + version "2.9.2" + resolved "https://registry.yarnpkg.com/cli-spinners/-/cli-spinners-2.9.2.tgz#1773a8f4b9c4d6ac31563df53b3fc1d79462fe41" + integrity sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg== cli-table3@^0.5.0: version "0.5.1" @@ -3385,14 +3249,14 @@ cli-width@^3.0.0: resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-3.0.0.tgz#a2f48437a2caa9a22436e794bf071ec9e61cedf6" integrity sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw== -cliui@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/cliui/-/cliui-5.0.0.tgz#deefcfdb2e800784aa34f46fa08e06851c7bbbc5" - integrity sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA== +cliui@^3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-3.2.0.tgz#120601537a916d29940f934da3b48d585a39213d" + integrity sha512-0yayqDxWQbqk3ojkYqUKqaAQ6AfNKeKWRNA8kR0WXzAsdHpP4BIaOmMAG87JGuO6qcobyW4GjxHd9PmhEd+T9w== dependencies: - string-width "^3.1.0" - strip-ansi "^5.2.0" - wrap-ansi "^5.1.0" + string-width "^1.0.1" + strip-ansi "^3.0.1" + wrap-ansi "^2.0.0" cliui@^7.0.2: version "7.0.4" @@ -3446,6 +3310,11 @@ cmd-shim@6.0.1: resolved "https://registry.yarnpkg.com/cmd-shim/-/cmd-shim-6.0.1.tgz#a65878080548e1dca760b3aea1e21ed05194da9d" integrity sha512-S9iI9y0nKR4hwEQsVWpyxld/6kRfGepGfzff83FcaiEBpmvlbA2nnGe7Cylgrx2f/p1P5S5wpRm9oL8z1PbS3Q== +code-point-at@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" + integrity sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA== + collection-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" @@ -3552,9 +3421,9 @@ compare-func@^2.0.0: dot-prop "^5.1.0" component-emitter@^1.2.1: - version "1.3.0" - resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.3.0.tgz#16e4070fba8ae29b679f2215853ee181ab2eabc0" - integrity sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg== + version "1.3.1" + resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.3.1.tgz#ef1d5796f7d93f135ee6fb684340b26403c97d17" + integrity sha512-T0+barUSQRTUQASh8bx02dl+DhF54GtIDY13Y3m9oWTklKbb3Wv974meRpeZ3lp1JpLVECWWNHC4vaG2XHXouQ== concat-map@0.0.1: version "0.0.1" @@ -3598,10 +3467,10 @@ content-type@~1.0.4, content-type@~1.0.5: resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.5.tgz#8b773162656d1d1086784c8f23a54ce6d73d7918" integrity sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA== -conventional-changelog-angular@6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/conventional-changelog-angular/-/conventional-changelog-angular-6.0.0.tgz#a9a9494c28b7165889144fd5b91573c4aa9ca541" - integrity sha512-6qLgrBF4gueoC7AFVHu51nHL9pF9FRjXrH+ceVf7WmAfH3gs+gEYOkvxhjMPjZu57I4AGUGoNTY8V7Hrgf1uqg== +conventional-changelog-angular@7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/conventional-changelog-angular/-/conventional-changelog-angular-7.0.0.tgz#5eec8edbff15aa9b1680a8dcfbd53e2d7eb2ba7a" + integrity sha512-ROjNchA9LgfNMTTFSIWPzebCwOGFdgkEq45EnvvrmSLvCtAw0HSmrCs7/ty+wAeYUZyNay0YMUNYFTRL72PkBQ== dependencies: compare-func "^2.0.0" @@ -3692,9 +3561,9 @@ copy-descriptor@^0.1.0: integrity sha512-XgZ0pFcakEUlbwQEVNg3+QAis1FyTL3Qel9FYy8pSkQqoG3PNoT0bOCQtOXcOkur21r2Eq2kI+IE+gsmAEVlYw== core-js-pure@^3.0.1: - version "3.30.1" - resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.30.1.tgz#7d93dc89e7d47b8ef05d7e79f507b0e99ea77eec" - integrity sha512-nXBEVpmUnNRhz83cHd9JRQC52cTMcuXAmR56+9dSMpRdpeA4I1PX6yjmhd71Eyc/wXNsdBdUDIj1QTIeZpU5Tg== + version "3.36.0" + resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.36.0.tgz#ffb34330b14e594d6a9835cf5843b4123f1d95db" + integrity sha512-cN28qmhRNgbMZZMc/RFu5w8pK9VJzpb2rJVR/lHuZJKwmXnoWOpXmMkxqBB514igkp1Hu8WGROsiOAzUcKdHOQ== core-util-is@1.0.2: version "1.0.2" @@ -3800,13 +3669,6 @@ debug@2.6.9, debug@^2.2.0, debug@^2.6.6, debug@^2.6.8: dependencies: ms "2.0.0" -debug@3.2.6: - version "3.2.6" - resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.6.tgz#e83d17de16d8a7efb7717edbe5fb10135eee629b" - integrity sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ== - dependencies: - ms "^2.1.1" - debug@4, debug@4.3.4, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.3, debug@^4.3.4: version "4.3.4" resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" @@ -3829,7 +3691,7 @@ decamelize-keys@^1.1.0: decamelize "^1.1.0" map-obj "^1.0.0" -decamelize@^1.1.0, decamelize@^1.2.0: +decamelize@^1.1.0, decamelize@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" integrity sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA== @@ -3844,7 +3706,7 @@ dedent@0.7.0: resolved "https://registry.yarnpkg.com/dedent/-/dedent-0.7.0.tgz#2495ddbaf6eb874abb0e1be9df22d2e5a544326c" integrity sha512-Q6fKUPqnAHAyhiUgFU7BUzLiv0kd8saH9al7tnu5Q/okj6dnupxyTgFIBjVzJATdfIAm9NAsvXNzjaKa+bxVyA== -deep-eql@^4.1.2: +deep-eql@^4.1.3: version "4.1.3" resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-4.1.3.tgz#7c7775513092f7df98d8df9996dd085eb668cc6d" integrity sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw== @@ -3876,28 +3738,20 @@ deferred-leveldown@~5.3.0: abstract-leveldown "~6.2.1" inherits "^2.0.3" -define-data-property@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/define-data-property/-/define-data-property-1.1.1.tgz#c35f7cd0ab09883480d12ac5cb213715587800b3" - integrity sha512-E7uGkTzkk1d0ByLeSc6ZsFS79Axg+m1P/VsgYsxHgiuc3tFSj+MjMIwe90FC4lOAZzNBdY7kkO2P2wKdsQ1vgQ== +define-data-property@^1.1.2: + version "1.1.4" + resolved "https://registry.yarnpkg.com/define-data-property/-/define-data-property-1.1.4.tgz#894dc141bb7d3060ae4366f6a0107e68fbe48c5e" + integrity sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A== dependencies: - get-intrinsic "^1.2.1" + es-define-property "^1.0.0" + es-errors "^1.3.0" gopd "^1.0.1" - has-property-descriptors "^1.0.0" define-lazy-prop@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/define-lazy-prop/-/define-lazy-prop-2.0.0.tgz#3f7ae421129bcaaac9bc74905c98a0009ec9ee7f" integrity sha512-Ds09qNh8yw3khSjiJjiUInaGX9xlqZDY7JVryGxdxV7NPeuqQfplOpQ66yJFZut3jLa5zOwkXw1g9EI2uKh4Og== -define-properties@^1.1.2, define-properties@^1.1.3, define-properties@^1.1.4: - version "1.2.0" - resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.2.0.tgz#52988570670c9eacedd8064f4a990f2405849bd5" - integrity sha512-xvqAVKGfT1+UAvPwKTVw/njhdQ8ZhXK4lI0bCIuCMrp2up9nPnaDftrLtmpTazqd1o+UY4zgzU+avtMbDP+ldA== - dependencies: - has-property-descriptors "^1.0.0" - object-keys "^1.1.1" - define-property@^0.2.5: version "0.2.5" resolved "https://registry.yarnpkg.com/define-property/-/define-property-0.2.5.tgz#c35b1ef918ec3c990f9a5bc57be04aacec5c8116" @@ -3935,7 +3789,7 @@ delegates@^1.0.0: resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" integrity sha512-bd2L678uiWATM6m5Z1VzNCErI3jiGzt6HGY8OVICs40JQq/HALfbyNJmp0UDakEY4pMMaN0Ly5om/B1VI/+xfQ== -depd@2.0.0, depd@^2.0.0: +depd@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/depd/-/depd-2.0.0.tgz#b696163cc757560d09cf22cc8fad1571b79e76df" integrity sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw== @@ -3955,24 +3809,11 @@ detect-indent@^5.0.0: resolved "https://registry.yarnpkg.com/detect-indent/-/detect-indent-5.0.0.tgz#3871cc0a6a002e8c3e5b3cf7f336264675f06b9d" integrity sha512-rlpvsxUtM0PQvy9iZe640/IWwWYyBsTApREbA1pHOpmOUIl9MkP/U4z7vTtg4Oaojvqhxt7sdufnT0EzGaR31g== -detect-port@^1.3.0: - version "1.5.1" - resolved "https://registry.yarnpkg.com/detect-port/-/detect-port-1.5.1.tgz#451ca9b6eaf20451acb0799b8ab40dff7718727b" - integrity sha512-aBzdj76lueB6uUst5iAs7+0H/oOjqI5D16XUWxlWMIMROhcM0rfsNVk93zTngq1dDNpoXRr++Sus7ETAExppAQ== - dependencies: - address "^1.0.1" - debug "4" - diff-sequences@^29.6.3: version "29.6.3" resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-29.6.3.tgz#4deaf894d11407c51efc8418012f9e70b84ea921" integrity sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q== -diff@3.5.0: - version "3.5.0" - resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" - integrity sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA== - diff@5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/diff/-/diff-5.0.0.tgz#7ed6ad76d859d030787ec35855f5b1daf31d852b" @@ -3984,9 +3825,9 @@ diff@^4.0.1: integrity sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A== diff@^5.0.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/diff/-/diff-5.1.0.tgz#bc52d298c5ea8df9194800224445ed43ffc87e40" - integrity sha512-D+mk+qE8VC/PAUrlAU34N+VfXev0ghe5ywmpqrawphmVZc1bEfn56uo9qpyGp1p4xpzOHkSW4ztBd6L7Xx4ACw== + version "5.2.0" + resolved "https://registry.yarnpkg.com/diff/-/diff-5.2.0.tgz#26ded047cd1179b78b9537d5ef725503ce1ae531" + integrity sha512-uIFDxqpRZGZ6ThOk84hEfqWoHx2devRFvpTZcTHur85vImfaxUbTW9Ryh4CpCuDnToOP1CEtXKIgytHBPVff5A== difflib@^0.2.4: version "0.2.4" @@ -4022,14 +3863,14 @@ dotenv-expand@~10.0.0: integrity sha512-GopVGCpVS1UKH75VKHGuQFqS1Gusej0z4FyQkPdwjil2gNIv+LNsqBlboOzpJFZKVT95GkCyWJbBSdFEFUWI2A== dotenv@^16.0.1: - version "16.0.3" - resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.0.3.tgz#115aec42bac5053db3c456db30cc243a5a836a07" - integrity sha512-7GO6HghkA5fYG9TYnNxi14/7K9f5occMlp3zXAuSxn7CKCxt9xbNWG7yF8hTCSUchlfWSe3uLmlPfigevRItzQ== + version "16.4.5" + resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.4.5.tgz#cdd3b3b604cb327e286b4762e13502f717cb099f" + integrity sha512-ZmdL2rui+eB2YwhsWzjInR8LldtZHGDoQ1ugH85ppHKwpUHL7j7rN0Ti9NCnGiQbhaZ11FpR+7ao1dNsmduNUg== dotenv@~16.3.1: - version "16.3.1" - resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.3.1.tgz#369034de7d7e5b120972693352a3bf112172cc3e" - integrity sha512-IPzF4w4/Rd94bA9imS68tZBaYyBWSCE47V1RGuMrB94iyTOIEwRmVL2x/4An+6mETpLrKJ5hQkB8W4kFAadeIQ== + version "16.3.2" + resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.3.2.tgz#3cb611ce5a63002dbabf7c281bc331f69d28f03f" + integrity sha512-HTlk5nmhkm8F6JcdXvHIzaorzCoziNQT9mGxLPVXW8wJF1TiGSL60ZGB4gHWabHOaMmWmhvk2/lPHfnBiT78AQ== duplexer@^0.1.1: version "0.1.2" @@ -4079,11 +3920,6 @@ emittery@0.10.0: resolved "https://registry.yarnpkg.com/emittery/-/emittery-0.10.0.tgz#bb373c660a9d421bb44706ec4967ed50c02a8026" integrity sha512-AGvFfs+d0JKCJQ4o01ASQLGPmSCxgfU9RFXvzPvZdjKK8oscynksuJhWrSTSw7j7Ep/sZct5b5ZhYCi8S/t0HQ== -emoji-regex@^7.0.1: - version "7.0.3" - resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" - integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA== - emoji-regex@^8.0.0: version "8.0.0" resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" @@ -4160,7 +3996,7 @@ errno@~0.1.1: dependencies: prr "~1.0.1" -error-ex@^1.3.1: +error-ex@^1.2.0, error-ex@^1.3.1: version "1.3.2" resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== @@ -4172,73 +4008,22 @@ error-symbol@^0.1.0: resolved "https://registry.yarnpkg.com/error-symbol/-/error-symbol-0.1.0.tgz#0a4dae37d600d15a29ba453d8ef920f1844333f6" integrity sha512-VyjaKxUmeDX/m2lxm/aknsJ1GWDWUO2Ze2Ad8S1Pb9dykAm9TjSKp5CjrNyltYqZ5W/PO6TInAmO2/BfwMyT1g== -es-abstract@^1.19.0, es-abstract@^1.20.4: - version "1.21.2" - resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.21.2.tgz#a56b9695322c8a185dc25975aa3b8ec31d0e7eff" - integrity sha512-y/B5POM2iBnIxCiernH1G7rC9qQoM77lLIMQLuob0zhp8C56Po81+2Nj0WFKnd0pNReDTnkYryc+zhOzpEIROg== - dependencies: - array-buffer-byte-length "^1.0.0" - available-typed-arrays "^1.0.5" - call-bind "^1.0.2" - es-set-tostringtag "^2.0.1" - es-to-primitive "^1.2.1" - function.prototype.name "^1.1.5" - get-intrinsic "^1.2.0" - get-symbol-description "^1.0.0" - globalthis "^1.0.3" - gopd "^1.0.1" - has "^1.0.3" - has-property-descriptors "^1.0.0" - has-proto "^1.0.1" - has-symbols "^1.0.3" - internal-slot "^1.0.5" - is-array-buffer "^3.0.2" - is-callable "^1.2.7" - is-negative-zero "^2.0.2" - is-regex "^1.1.4" - is-shared-array-buffer "^1.0.2" - is-string "^1.0.7" - is-typed-array "^1.1.10" - is-weakref "^1.0.2" - object-inspect "^1.12.3" - object-keys "^1.1.1" - object.assign "^4.1.4" - regexp.prototype.flags "^1.4.3" - safe-regex-test "^1.0.0" - string.prototype.trim "^1.2.7" - string.prototype.trimend "^1.0.6" - string.prototype.trimstart "^1.0.6" - typed-array-length "^1.0.4" - unbox-primitive "^1.0.2" - which-typed-array "^1.1.9" - -es-array-method-boxes-properly@^1.0.0: +es-define-property@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/es-array-method-boxes-properly/-/es-array-method-boxes-properly-1.0.0.tgz#873f3e84418de4ee19c5be752990b2e44718d09e" - integrity sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA== - -es-set-tostringtag@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz#338d502f6f674301d710b80c8592de8a15f09cd8" - integrity sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg== + resolved "https://registry.yarnpkg.com/es-define-property/-/es-define-property-1.0.0.tgz#c7faefbdff8b2696cf5f46921edfb77cc4ba3845" + integrity sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ== dependencies: - get-intrinsic "^1.1.3" - has "^1.0.3" - has-tostringtag "^1.0.0" + get-intrinsic "^1.2.4" -es-to-primitive@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.2.1.tgz#e55cd4c9cdc188bcefb03b366c736323fc5c898a" - integrity sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA== - dependencies: - is-callable "^1.1.4" - is-date-object "^1.0.1" - is-symbol "^1.0.2" +es-errors@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/es-errors/-/es-errors-1.3.0.tgz#05f75a25dab98e4fb1dcd5e1472c0546d5057c8f" + integrity sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw== es5-ext@^0.10.35, es5-ext@^0.10.50, es5-ext@^0.10.62, es5-ext@~0.10.14: - version "0.10.63" - resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.63.tgz#9c222a63b6a332ac80b1e373b426af723b895bd6" - integrity sha512-hUCZd2Byj/mNKjfP9jXrdVZ62B8KuA/VoK7X8nUh5qT+AxDmcbvZz041oDVZdbIN1qW6XY9VDNwzkvKnZvK2TQ== + version "0.10.64" + resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.64.tgz#12e4ffb48f1ba2ea777f1fcdd1918ef73ea21714" + integrity sha512-p2snDhiLaXe6dahss1LddxqEm+SkuDvV8dnIQG0MWjyHpcMNfXKPE+/Cc0y+PhxJX3A4xGNeFCj5oc0BUh6deg== dependencies: es6-iterator "^2.0.3" es6-symbol "^3.1.3" @@ -4275,25 +4060,25 @@ es6-symbol@^3.1.1, es6-symbol@^3.1.3: ext "^1.1.2" escalade@^3.1.1: - version "3.1.1" - resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40" - integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== + version "3.1.2" + resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.2.tgz#54076e9ab29ea5bf3d8f1ed62acffbb88272df27" + integrity sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA== escape-html@~1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/escape-html/-/escape-html-1.0.3.tgz#0258eae4d3d0c0974de1c169188ef0051d1d1988" integrity sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow== -escape-string-regexp@1.0.5, escape-string-regexp@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" - integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== - escape-string-regexp@4.0.0, escape-string-regexp@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== +escape-string-regexp@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" + integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== + escodegen@1.8.x: version "1.8.1" resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.8.1.tgz#5a5b53af4693110bebb0867aa3430dd3b70a1018" @@ -4307,9 +4092,9 @@ escodegen@1.8.x: source-map "~0.2.0" eslint-config-prettier@^8.5.0: - version "8.8.0" - resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-8.8.0.tgz#bfda738d412adc917fd7b038857110efe98c9348" - integrity sha512-wLbQiFre3tdGgpDv67NQKnJuTlcUVYHas3k+DZCc2U2BadthoEY4B7hLPvAxaqdyOGCzuLfii2fqGph10va7oA== + version "8.10.0" + resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-8.10.0.tgz#3a06a662130807e2502fc3ff8b4143d8a0658e11" + integrity sha512-SM8AMJdeQqRYT9O9zguiruQZaN7+z+E4eAP9oiLNGKMtomwaB1E9dcgUD6ZAn/eQAb52USbvezbiljfZUhbJcg== eslint-plugin-prettier@^4.2.1: version "4.2.1" @@ -4318,48 +4103,41 @@ eslint-plugin-prettier@^4.2.1: dependencies: prettier-linter-helpers "^1.0.0" -eslint-scope@^5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" - integrity sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw== - dependencies: - esrecurse "^4.3.0" - estraverse "^4.1.1" - -eslint-scope@^7.1.1: - version "7.2.0" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-7.2.0.tgz#f21ebdafda02352f103634b96dd47d9f81ca117b" - integrity sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw== +eslint-scope@^7.2.2: + version "7.2.2" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-7.2.2.tgz#deb4f92563390f32006894af62a22dba1c46423f" + integrity sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg== dependencies: esrecurse "^4.3.0" estraverse "^5.2.0" -eslint-visitor-keys@^3.3.0, eslint-visitor-keys@^3.4.0: - version "3.4.0" - resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.4.0.tgz#c7f0f956124ce677047ddbc192a68f999454dedc" - integrity sha512-HPpKPUBQcAsZOsHAFwTtIKcYlCje62XB7SEAcxjtmW6TD1WVpkS6i6/hOVtTZIl4zGj/mBqpFVGvaDneik+VoQ== +eslint-visitor-keys@^3.3.0, eslint-visitor-keys@^3.4.1, eslint-visitor-keys@^3.4.3: + version "3.4.3" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz#0cd72fe8550e3c2eae156a96a4dddcd1c8ac5800" + integrity sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag== eslint@^8.20.0: - version "8.38.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.38.0.tgz#a62c6f36e548a5574dd35728ac3c6209bd1e2f1a" - integrity sha512-pIdsD2jwlUGf/U38Jv97t8lq6HpaU/G9NKbYmpWpZGw3LdTNhZLbJePqxOXGB5+JEKfOPU/XLxYxFh03nr1KTg== + version "8.57.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.57.0.tgz#c786a6fd0e0b68941aaf624596fb987089195668" + integrity sha512-dZ6+mexnaTIbSBZWgou51U6OmzIhYM2VcNdtiTtI7qPNZm35Akpr0f6vtw3w1Kmn5PYo+tZVfh13WrhpS6oLqQ== dependencies: "@eslint-community/eslint-utils" "^4.2.0" - "@eslint-community/regexpp" "^4.4.0" - "@eslint/eslintrc" "^2.0.2" - "@eslint/js" "8.38.0" - "@humanwhocodes/config-array" "^0.11.8" + "@eslint-community/regexpp" "^4.6.1" + "@eslint/eslintrc" "^2.1.4" + "@eslint/js" "8.57.0" + "@humanwhocodes/config-array" "^0.11.14" "@humanwhocodes/module-importer" "^1.0.1" "@nodelib/fs.walk" "^1.2.8" - ajv "^6.10.0" + "@ungap/structured-clone" "^1.2.0" + ajv "^6.12.4" chalk "^4.0.0" cross-spawn "^7.0.2" debug "^4.3.2" doctrine "^3.0.0" escape-string-regexp "^4.0.0" - eslint-scope "^7.1.1" - eslint-visitor-keys "^3.4.0" - espree "^9.5.1" + eslint-scope "^7.2.2" + eslint-visitor-keys "^3.4.3" + espree "^9.6.1" esquery "^1.4.2" esutils "^2.0.2" fast-deep-equal "^3.1.3" @@ -4367,22 +4145,19 @@ eslint@^8.20.0: find-up "^5.0.0" glob-parent "^6.0.2" globals "^13.19.0" - grapheme-splitter "^1.0.4" + graphemer "^1.4.0" ignore "^5.2.0" - import-fresh "^3.0.0" imurmurhash "^0.1.4" is-glob "^4.0.0" is-path-inside "^3.0.3" - js-sdsl "^4.1.4" js-yaml "^4.1.0" json-stable-stringify-without-jsonify "^1.0.1" levn "^0.4.1" lodash.merge "^4.6.2" minimatch "^3.1.2" natural-compare "^1.4.0" - optionator "^0.9.1" + optionator "^0.9.3" strip-ansi "^6.0.1" - strip-json-comments "^3.1.0" text-table "^0.2.0" esniff@^2.0.1: @@ -4395,14 +4170,14 @@ esniff@^2.0.1: event-emitter "^0.3.5" type "^2.7.2" -espree@^9.5.1: - version "9.5.1" - resolved "https://registry.yarnpkg.com/espree/-/espree-9.5.1.tgz#4f26a4d5f18905bf4f2e0bd99002aab807e96dd4" - integrity sha512-5yxtHSZXRSW5pvv3hAlXM5+/Oswi1AUFqBmbibKb5s6bp3rGIDkyXU6xCoyuuLhijr4SFwPrXRoZjz0AZDN9tg== +espree@^9.6.0, espree@^9.6.1: + version "9.6.1" + resolved "https://registry.yarnpkg.com/espree/-/espree-9.6.1.tgz#a2a17b8e434690a5432f2f8018ce71d331a48c6f" + integrity sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ== dependencies: - acorn "^8.8.0" + acorn "^8.9.0" acorn-jsx "^5.3.2" - eslint-visitor-keys "^3.4.0" + eslint-visitor-keys "^3.4.1" esprima@2.7.x, esprima@^2.7.1: version "2.7.3" @@ -4433,11 +4208,6 @@ estraverse@^1.9.1: resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-1.9.3.tgz#af67f2dc922582415950926091a4005d29c9bb44" integrity sha512-25w1fMXQrGdoquWnScXZGckOv+Wes+JDnuN/+7ex3SauFRS72r2lFDec0EKPt2YD1wUJ/IrfEex+9yp4hfSOJA== -estraverse@^4.1.1: - version "4.3.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" - integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== - estraverse@^5.1.0, estraverse@^5.2.0: version "5.3.0" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.3.0.tgz#2eea5290702f26ab8fe5370370ff86c965d21123" @@ -4453,24 +4223,30 @@ etag@~1.8.1: resolved "https://registry.yarnpkg.com/etag/-/etag-1.8.1.tgz#41ae2eeb65efa62268aebfea83ac7d79299b0887" integrity sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg== +eth-ens-namehash@^2.0.8: + version "2.0.8" + resolved "https://registry.yarnpkg.com/eth-ens-namehash/-/eth-ens-namehash-2.0.8.tgz#229ac46eca86d52e0c991e7cb2aef83ff0f68bcf" + integrity sha512-VWEI1+KJfz4Km//dadyvBBoBeSQ0MHTXPvr8UIXiLW6IanxvAV+DmlZAijZwAyggqGUfwQBeHf7tc9wzc1piSw== + dependencies: + idna-uts46-hx "^2.3.1" + js-sha3 "^0.5.7" + eth-gas-reporter@^0.2.25: - version "0.2.25" - resolved "https://registry.yarnpkg.com/eth-gas-reporter/-/eth-gas-reporter-0.2.25.tgz#546dfa946c1acee93cb1a94c2a1162292d6ff566" - integrity sha512-1fRgyE4xUB8SoqLgN3eDfpDfwEfRxh2Sz1b7wzFbyQA+9TekMmvSjjoRu9SKcSVyK+vLkLIsVbJDsTWjw195OQ== + version "0.2.27" + resolved "https://registry.yarnpkg.com/eth-gas-reporter/-/eth-gas-reporter-0.2.27.tgz#928de8548a674ed64c7ba0bf5795e63079150d4e" + integrity sha512-femhvoAM7wL0GcI8ozTdxfuBtBFJ9qsyIAsmKVjlWAHUbdnnXHt+lKzz/kmldM5lA9jLuNHGwuIxorNpLbR1Zw== dependencies: - "@ethersproject/abi" "^5.0.0-beta.146" "@solidity-parser/parser" "^0.14.0" + axios "^1.5.1" cli-table3 "^0.5.0" colors "1.4.0" ethereum-cryptography "^1.0.3" - ethers "^4.0.40" + ethers "^5.7.2" fs-readdir-recursive "^1.1.0" lodash "^4.17.14" markdown-table "^1.1.3" - mocha "^7.1.1" + mocha "^10.2.0" req-cwd "^2.0.0" - request "^2.88.0" - request-promise-native "^1.0.5" sha1 "^1.1.1" sync-request "^6.0.0" @@ -4502,7 +4278,7 @@ ethereum-cryptography@0.1.3, ethereum-cryptography@^0.1.3: secp256k1 "^4.0.1" setimmediate "^1.0.5" -ethereum-cryptography@^1.0.3, ethereum-cryptography@^1.1.2: +ethereum-cryptography@^1.0.3: version "1.2.0" resolved "https://registry.yarnpkg.com/ethereum-cryptography/-/ethereum-cryptography-1.2.0.tgz#5ccfa183e85fdaf9f9b299a79430c044268c9b3a" integrity sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw== @@ -4542,7 +4318,7 @@ ethereumjs-abi@0.6.8, ethereumjs-abi@^0.6.8: bn.js "^4.11.8" ethereumjs-util "^6.0.0" -ethereumjs-util@*, ethereumjs-util@^7.0.7, ethereumjs-util@^7.1.0, ethereumjs-util@^7.1.1, ethereumjs-util@^7.1.3, ethereumjs-util@^7.1.4, ethereumjs-util@^7.1.5: +ethereumjs-util@*, ethereumjs-util@^7.0.7, ethereumjs-util@^7.1.1, ethereumjs-util@^7.1.3, ethereumjs-util@^7.1.4, ethereumjs-util@^7.1.5: version "7.1.5" resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-7.1.5.tgz#9ecf04861e4fbbeed7465ece5f23317ad1129181" integrity sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg== @@ -4577,22 +4353,7 @@ ethereumjs-util@^6.0.0, ethereumjs-util@^6.2.1: ethjs-util "0.1.6" rlp "^2.2.3" -ethers@^4.0.40: - version "4.0.49" - resolved "https://registry.yarnpkg.com/ethers/-/ethers-4.0.49.tgz#0eb0e9161a0c8b4761be547396bbe2fb121a8894" - integrity sha512-kPltTvWiyu+OktYy1IStSO16i2e7cS9D9OxZ81q2UUaiNPVrm/RTcbxamCXF9VUSKzJIdJV68EAIhTEVBalRWg== - 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" - -ethers@^5.7.1, ethers@^5.7.2: +ethers@^5.7.2: version "5.7.2" resolved "https://registry.yarnpkg.com/ethers/-/ethers-5.7.2.tgz#3a7deeabbb8c030d4126b24f84e525466145872e" integrity sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg== @@ -4695,14 +4456,19 @@ execa@^5.0.0: signal-exit "^3.0.3" strip-final-newline "^2.0.0" +exponential-backoff@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/exponential-backoff/-/exponential-backoff-3.1.1.tgz#64ac7526fe341ab18a39016cd22c787d01e00bf6" + integrity sha512-dX7e/LHVJ6W3DE1MHWi9S1EYzDESENfLrYohG2G++ovZrYOkm4Knwa0mc1cn84xJOR4KEU0WSchhLbd0UklbHw== + express@^4.18.2: - version "4.18.2" - resolved "https://registry.yarnpkg.com/express/-/express-4.18.2.tgz#3fabe08296e930c796c19e3c516979386ba9fd59" - integrity sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ== + version "4.18.3" + resolved "https://registry.yarnpkg.com/express/-/express-4.18.3.tgz#6870746f3ff904dee1819b82e4b51509afffb0d4" + integrity sha512-6VyCijWQ+9O7WuVMTRBTl+cjNNIzD5cY5mQ1WM8r/LEkI2u8EYpOotESNwzNlyCn3g+dmjKYI6BmNneSr/FSRw== dependencies: accepts "~1.3.8" array-flatten "1.1.1" - body-parser "1.20.1" + body-parser "1.20.2" content-disposition "0.5.4" content-type "~1.0.4" cookie "0.5.0" @@ -4795,14 +4561,14 @@ fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== fast-diff@^1.1.2: - version "1.2.0" - resolved "https://registry.yarnpkg.com/fast-diff/-/fast-diff-1.2.0.tgz#73ee11982d86caaf7959828d519cfe927fac5f03" - integrity sha512-xJuoT5+L99XlZ8twedaRf6Ax2TgQVxvgZOYoPKqZufmJib0tL2tegPBOZb1pVNgIhlqDlA0eO0c3wBvQcmzx4w== + version "1.3.0" + resolved "https://registry.yarnpkg.com/fast-diff/-/fast-diff-1.3.0.tgz#ece407fa550a64d638536cd727e129c61616e0f0" + integrity sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw== fast-glob@^3.0.3, fast-glob@^3.2.9: - version "3.2.12" - resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.12.tgz#7f39ec99c2e6ab030337142da9e0c18f37afae80" - integrity sha512-DVj4CQIYYow0BlaelwK1pHl5n5cRSJfM60UA0zK891sVInoPri2Ekj7+e1CT3/3qxXenpI+nBBmQAcJPJgaj4w== + version "3.3.2" + resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.3.2.tgz#a904501e57cfdd2ffcded45e99a54fef55e46129" + integrity sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow== dependencies: "@nodelib/fs.stat" "^2.0.2" "@nodelib/fs.walk" "^1.2.3" @@ -4821,9 +4587,9 @@ fast-levenshtein@^2.0.6, fast-levenshtein@~2.0.6: integrity sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw== fastq@^1.6.0: - version "1.15.0" - resolved "https://registry.yarnpkg.com/fastq/-/fastq-1.15.0.tgz#d04d07c6a2a68fe4599fea8d2e103a937fae6b3a" - integrity sha512-wBrocU2LCXXa+lWBt8RoIRD89Fi8OdABODa/kEnyeyjS5aZO5/GNvI5sEINADqP/h8M29UHTHUb53sUu5Ihqdw== + version "1.17.1" + resolved "https://registry.yarnpkg.com/fastq/-/fastq-1.17.1.tgz#2a523f07a4e7b1e81a42b91b8bf2254107753b47" + integrity sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w== dependencies: reusify "^1.0.4" @@ -4841,7 +4607,7 @@ file-entry-cache@^6.0.1: dependencies: flat-cache "^3.0.4" -filelist@^1.0.1: +filelist@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/filelist/-/filelist-1.0.4.tgz#f78978a1e944775ff9e62e744424f215e58352b5" integrity sha512-w1cEuf3S+DrLCQL7ET6kz+gmlJdbq9J7yXCSjK/OZCPA+qEN1WyF4ZAf0YYJa4/shHJra2t/d/r8SV4Ji+x+8Q== @@ -4875,13 +4641,6 @@ find-replace@^3.0.0: dependencies: array-back "^3.0.1" -find-up@3.0.0, find-up@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/find-up/-/find-up-3.0.0.tgz#49169f1d7993430646da61ecc5ae355c21c97b73" - integrity sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg== - dependencies: - locate-path "^3.0.0" - find-up@5.0.0, find-up@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/find-up/-/find-up-5.0.0.tgz#4c92819ecb7083561e4f4a240a86be5198f536fc" @@ -4890,6 +4649,14 @@ find-up@5.0.0, find-up@^5.0.0: locate-path "^6.0.0" path-exists "^4.0.0" +find-up@^1.0.0: + version "1.1.2" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-1.1.2.tgz#6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f" + integrity sha512-jvElSjyuo4EMQGoTwo1uJU5pQMwTW5lS1x05zzfJuTIyLR3zwO27LYrxNg+dlvKpGOuGy/MzBdXh80g0ve5+HA== + dependencies: + path-exists "^2.0.0" + pinkie-promise "^2.0.0" + find-up@^2.0.0, find-up@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/find-up/-/find-up-2.1.0.tgz#45d1b7e506c717ddd482775a2b77920a3c0c57a7" @@ -4906,41 +4673,28 @@ find-up@^4.0.0, find-up@^4.1.0: path-exists "^4.0.0" flat-cache@^3.0.4: - version "3.0.4" - resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-3.0.4.tgz#61b0338302b2fe9f957dcc32fc2a87f1c3048b11" - integrity sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg== + version "3.2.0" + resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-3.2.0.tgz#2c0c2d5040c99b1632771a9d105725c0115363ee" + integrity sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw== dependencies: - flatted "^3.1.0" + flatted "^3.2.9" + keyv "^4.5.3" rimraf "^3.0.2" -flat@^4.1.0: - version "4.1.1" - resolved "https://registry.yarnpkg.com/flat/-/flat-4.1.1.tgz#a392059cc382881ff98642f5da4dde0a959f309b" - integrity sha512-FmTtBsHskrU6FJ2VxCnsDb84wu9zhmO3cUX2kGFb5tuwhfXxGciiT0oRY+cck35QmG+NmGh5eLz6lLCpWTqwpA== - dependencies: - is-buffer "~2.0.3" - flat@^5.0.2: version "5.0.2" resolved "https://registry.yarnpkg.com/flat/-/flat-5.0.2.tgz#8ca6fe332069ffa9d324c327198c598259ceb241" integrity sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ== -flatted@^3.1.0: - version "3.2.7" - resolved "https://registry.yarnpkg.com/flatted/-/flatted-3.2.7.tgz#609f39207cb614b89d0765b477cb2d437fbf9787" - integrity sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ== - -follow-redirects@^1.12.1, follow-redirects@^1.15.0: - version "1.15.4" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.4.tgz#cdc7d308bf6493126b17ea2191ea0ccf3e535adf" - integrity sha512-Cr4D/5wlrb0z9dgERpUL3LrmPKVDsETIJhaCMeDfuFYcqa5bldGV6wBsAN6X/vxlXQtFBMrXdXxdL8CbDTGniw== +flatted@^3.2.9: + version "3.3.1" + resolved "https://registry.yarnpkg.com/flatted/-/flatted-3.3.1.tgz#21db470729a6734d4997002f439cb308987f567a" + integrity sha512-X8cqMLLie7KsNUDSdzeN8FYK9rEt4Dt67OsG/DNGnYTSDBG4uFAJFBnUeiV+zCVAvwFy56IjM9sH51jVaEhNxw== -for-each@^0.3.3: - version "0.3.3" - resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e" - integrity sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw== - dependencies: - is-callable "^1.1.3" +follow-redirects@^1.12.1, follow-redirects@^1.15.4: + version "1.15.5" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.5.tgz#54d4d6d062c0fa7d9d17feb008461550e3ba8020" + integrity sha512-vSFWUON1B+yAw1VN4xMfxgn5fTUiaOzAJCKBwIIgT/+7CuGy9+r+5gITvP62j3RmaD5Ph65UaERdOSRGUzZtgw== for-in@^0.1.3: version "0.1.8" @@ -4981,15 +4735,6 @@ form-data@^2.2.0: combined-stream "^1.0.6" mime-types "^2.1.12" -form-data@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-3.0.1.tgz#ebd53791b78356a99af9a300d4282c4d5eb9755f" - integrity sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg== - dependencies: - asynckit "^0.4.0" - combined-stream "^1.0.8" - mime-types "^2.1.12" - form-data@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.0.tgz#93919daeaf361ee529584b9b31664dc12c9fa452" @@ -5045,9 +4790,9 @@ fs-extra@^0.30.0: rimraf "^2.2.8" fs-extra@^11.1.0, fs-extra@^11.1.1: - version "11.1.1" - resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-11.1.1.tgz#da69f7c39f3b002378b0954bb6ae7efdc0876e2d" - integrity sha512-MGIE4HOvQCeUCzmlHs0vXpih4ysz4wg9qiSAu6cd42lVwPbTM1TjV7RusoyQqMmk/95gdQZX72u+YW+c3eEpFQ== + version "11.2.0" + resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-11.2.0.tgz#e70e17dfad64232287d01929399e0ea7c86b0e5b" + integrity sha512-PmDi3uwK5nFuXh7XDTlVnS17xJS7vW36is2+w3xcv8SVxiB4NyATf4ctkVY5bkSjX0Y4nbvZCq1/EjtEyr9ktw== dependencies: graceful-fs "^4.2.0" jsonfile "^6.0.1" @@ -5089,11 +4834,11 @@ fs-minipass@^2.0.0, fs-minipass@^2.1.0: minipass "^3.0.0" fs-minipass@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-3.0.1.tgz#853809af15b6d03e27638d1ab6432e6b378b085d" - integrity sha512-MhaJDcFRTuLidHrIttu0RDGyyXs/IYHVmlcxfLAEFIWjc1vdLAkdwT7Ace2u7DbitWC0toKMl5eJZRYNVreIMw== + version "3.0.3" + resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-3.0.3.tgz#79a85981c4dc120065e96f62086bf6f9dc26cc54" + integrity sha512-XUBA9XClHbnJWSfBzjkm6RvPsyg3sryZt06BEQoXcF7EK/xpGaQYJgQKDJSUH5SGZ76Y7pFx1QBnXz09rU5Fbw== dependencies: - minipass "^4.0.0" + minipass "^7.0.3" fs-readdir-recursive@^1.1.0: version "1.1.0" @@ -5105,41 +4850,21 @@ fs.realpath@^1.0.0: resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== -fsevents@~2.1.1: - version "2.1.3" - resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.1.3.tgz#fb738703ae8d2f9fe900c33836ddebee8b97f23e" - integrity sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ== - fsevents@~2.3.2: version "2.3.3" resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.3.tgz#cac6407785d03675a2a5e1a5305c697b347d90d6" integrity sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw== -function-bind@^1.1.1, function-bind@^1.1.2: +function-bind@^1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.2.tgz#2c02d864d97f3ea6c8830c464cbd11ab6eab7a1c" integrity sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA== -function.prototype.name@^1.1.5: - version "1.1.5" - resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.1.5.tgz#cce0505fe1ffb80503e6f9e46cc64e46a12a9621" - integrity sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA== - dependencies: - call-bind "^1.0.2" - define-properties "^1.1.3" - es-abstract "^1.19.0" - functions-have-names "^1.2.2" - functional-red-black-tree@^1.0.1, functional-red-black-tree@~1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" integrity sha512-dsKNQNdj6xA3T+QlADDA7mOSlX0qiMINjn0cgr+eGHGsbSHzTabcIogz2+p/iqP1Xs6EP/sS2SbqH+brGTbq0g== -functions-have-names@^1.2.2: - version "1.2.3" - resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834" - integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ== - ganache@7.4.3: version "7.4.3" resolved "https://registry.yarnpkg.com/ganache/-/ganache-7.4.3.tgz#e995f1250697264efbb34d4241c374a2b0271415" @@ -5176,40 +4901,32 @@ generic-pool@3.9.0: resolved "https://registry.yarnpkg.com/generic-pool/-/generic-pool-3.9.0.tgz#36f4a678e963f4fdb8707eab050823abc4e8f5e4" integrity sha512-hymDOu5B53XvN4QT9dBmZxPX4CWhBPPLguTZ9MMFeFa/Kg0xWVfylOVNlJji/E7yTZWFd/q9GO5TxDLq156D7g== -get-caller-file@^1.0.2: +get-caller-file@^1.0.1, get-caller-file@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" integrity sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w== -get-caller-file@^2.0.1, get-caller-file@^2.0.5: +get-caller-file@^2.0.5: version "2.0.5" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== -get-func-name@^2.0.0: +get-func-name@^2.0.1, get-func-name@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/get-func-name/-/get-func-name-2.0.2.tgz#0d7cf20cd13fda808669ffa88f4ffc7a3943fc41" integrity sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ== -get-intrinsic@^1.0.2, get-intrinsic@^1.2.1: - version "1.2.2" - resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.2.tgz#281b7622971123e1ef4b3c90fd7539306da93f3b" - integrity sha512-0gSo4ml/0j98Y3lngkFEot/zhiCeWsbYIlZ+uZOVgzLyLaUw7wxUL+nCTP0XJvJg1AXulJRI3UJi8GsbDuxdGA== +get-intrinsic@^1.1.3, get-intrinsic@^1.2.3, get-intrinsic@^1.2.4: + version "1.2.4" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.4.tgz#e385f5a4b5227d449c3eabbad05494ef0abbeadd" + integrity sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ== dependencies: + es-errors "^1.3.0" function-bind "^1.1.2" has-proto "^1.0.1" has-symbols "^1.0.3" hasown "^2.0.0" -get-intrinsic@^1.1.1, get-intrinsic@^1.1.3, get-intrinsic@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.0.tgz#7ad1dc0535f3a2904bba075772763e5051f6d05f" - integrity sha512-L049y6nFOuom5wGyRc3/gdTLO94dySVKRACj1RmJZBQXlbTMhtNIgkWkUHq+jYmZvKf14EW1EoJnnjbmoHij0Q== - dependencies: - function-bind "^1.1.1" - has "^1.0.3" - has-symbols "^1.0.3" - get-parameter-names@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/get-parameter-names/-/get-parameter-names-0.3.0.tgz#2d2237cd592e6c5b859ab2efdab435f008e5bb97" @@ -5245,14 +4962,6 @@ get-stream@^6.0.0: resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== -get-symbol-description@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/get-symbol-description/-/get-symbol-description-1.0.0.tgz#7fdb81c900101fbd564dd5f1a30af5aadc1e58d6" - integrity sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw== - dependencies: - call-bind "^1.0.2" - get-intrinsic "^1.1.1" - getpass@^0.1.1: version "0.1.7" resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" @@ -5315,7 +5024,7 @@ gitconfiglocal@^1.0.0: dependencies: ini "^1.3.2" -glob-parent@5.1.2, glob-parent@^5.1.2, glob-parent@~5.1.0, glob-parent@~5.1.2: +glob-parent@5.1.2, glob-parent@^5.1.2, glob-parent@~5.1.2: version "5.1.2" resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== @@ -5329,18 +5038,6 @@ glob-parent@^6.0.2: dependencies: is-glob "^4.0.3" -glob@7.1.3: - version "7.1.3" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.3.tgz#3960832d3f1574108342dafd3a67b332c0969df1" - integrity sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ== - dependencies: - fs.realpath "^1.0.0" - inflight "^1.0.4" - inherits "2" - minimatch "^3.0.4" - once "^1.3.0" - path-is-absolute "^1.0.0" - glob@7.1.4: version "7.1.4" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255" @@ -5377,13 +5074,24 @@ glob@7.2.0: once "^1.3.0" path-is-absolute "^1.0.0" +glob@8.1.0, glob@^8.0.1: + version "8.1.0" + resolved "https://registry.yarnpkg.com/glob/-/glob-8.1.0.tgz#d388f656593ef708ee3e34640fdfb99a9fd1c33e" + integrity sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ== + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^5.0.1" + once "^1.3.0" + glob@^10.2.2: - version "10.3.7" - resolved "https://registry.yarnpkg.com/glob/-/glob-10.3.7.tgz#d5bd30a529c8c9b262fb4b217941f64ad90e25ac" - integrity sha512-wCMbE1m9Nx5yD9LYtgsVWq5VhHlk5WzJirw594qZR6AIvQYuHrdDtIktUVjQItalD53y7dqoedu9xP0u0WaxIQ== + version "10.3.10" + resolved "https://registry.yarnpkg.com/glob/-/glob-10.3.10.tgz#0351ebb809fd187fe421ab96af83d3a70715df4b" + integrity sha512-fa46+tv1Ak0UPK1TOy/pZrIybNNt4HCv7SDzwyfiOZkvZLEbjsZkJBPtDHVshZjbecAoAGSC20MjLDG/qr679g== dependencies: foreground-child "^3.1.0" - jackspeak "^2.0.3" + jackspeak "^2.3.5" minimatch "^9.0.1" minipass "^5.0.0 || ^6.0.2 || ^7.0.0" path-scurry "^1.10.1" @@ -5411,18 +5119,7 @@ glob@^7.0.0, glob@^7.1.3, glob@^7.1.4: once "^1.3.0" path-is-absolute "^1.0.0" -glob@^8.0.1: - version "8.1.0" - resolved "https://registry.yarnpkg.com/glob/-/glob-8.1.0.tgz#d388f656593ef708ee3e34640fdfb99a9fd1c33e" - integrity sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ== - dependencies: - fs.realpath "^1.0.0" - inflight "^1.0.4" - inherits "2" - minimatch "^5.0.1" - once "^1.3.0" - -glob@^9.2.0, glob@^9.3.0, glob@^9.3.1: +glob@^9.2.0: version "9.3.5" resolved "https://registry.yarnpkg.com/glob/-/glob-9.3.5.tgz#ca2ed8ca452781a3009685607fdf025a899dfe21" integrity sha512-e1LleDykUz2Iu+MTYdkSsuWX8lvAjAcs0Xef0lNIu0S2wOAzuTxCJtcd9S3cijlwYF18EsU3rzb8jPVobxDh9Q== @@ -5449,19 +5146,12 @@ global-prefix@^3.0.0: which "^1.3.1" globals@^13.19.0: - version "13.20.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-13.20.0.tgz#ea276a1e508ffd4f1612888f9d1bad1e2717bf82" - integrity sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ== + version "13.24.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-13.24.0.tgz#8432a19d78ce0c1e833949c36adb345400bb1171" + integrity sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ== dependencies: type-fest "^0.20.2" -globalthis@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/globalthis/-/globalthis-1.0.3.tgz#5852882a52b80dc301b0660273e1ed082f0b6ccf" - integrity sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA== - dependencies: - define-properties "^1.1.3" - globby@11.1.0, globby@^11.1.0: version "11.1.0" resolved "https://registry.yarnpkg.com/globby/-/globby-11.1.0.tgz#bd4be98bb042f83d796f7e3811991fbe82a0d34b" @@ -5500,23 +5190,18 @@ graceful-fs@4.2.11, graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2 resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== -grapheme-splitter@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/grapheme-splitter/-/grapheme-splitter-1.0.4.tgz#9cf3a665c6247479896834af35cf1dbb4400767e" - integrity sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ== - -growl@1.10.5: - version "1.10.5" - resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.5.tgz#f2735dc2283674fa67478b10181059355c369e5e" - integrity sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA== +graphemer@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/graphemer/-/graphemer-1.4.0.tgz#fb2f1d55e0e3a1849aeffc90c4fa0dd53a0e66c6" + integrity sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag== handlebars@^4.0.1, handlebars@^4.7.7: - version "4.7.7" - resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.7.7.tgz#9ce33416aad02dbd6c8fafa8240d5d98004945a1" - integrity sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA== + version "4.7.8" + resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.7.8.tgz#41c42c18b1be2365439188c77c6afae71c0cd9e9" + integrity sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ== dependencies: minimist "^1.2.5" - neo-async "^2.6.0" + neo-async "^2.6.2" source-map "^0.6.1" wordwrap "^1.0.0" optionalDependencies: @@ -5541,31 +5226,32 @@ hard-rejection@^2.1.0: integrity sha512-VIZB+ibDhx7ObhAe7OVtoEbuP4h/MuOTHJ+J8h/eBXotJYl0fBgR72xDFCKgIh22OJZIOVNxBMWuhAr10r8HdA== hardhat-gas-reporter@^1.0.9: - version "1.0.9" - resolved "https://registry.yarnpkg.com/hardhat-gas-reporter/-/hardhat-gas-reporter-1.0.9.tgz#9a2afb354bc3b6346aab55b1c02ca556d0e16450" - integrity sha512-INN26G3EW43adGKBNzYWOlI3+rlLnasXTwW79YNnUhXPDa+yHESgt639dJEs37gCjhkbNKcRRJnomXEuMFBXJg== + version "1.0.10" + resolved "https://registry.yarnpkg.com/hardhat-gas-reporter/-/hardhat-gas-reporter-1.0.10.tgz#ebe5bda5334b5def312747580cd923c2b09aef1b" + integrity sha512-02N4+So/fZrzJ88ci54GqwVA3Zrf0C9duuTyGt0CFRIh/CdNwbnTgkXkRfojOMLBQ+6t+lBIkgbsOtqMvNwikA== dependencies: array-uniq "1.0.3" eth-gas-reporter "^0.2.25" sha1 "^1.1.1" hardhat@^2.12.7: - version "2.19.4" - resolved "https://registry.yarnpkg.com/hardhat/-/hardhat-2.19.4.tgz#5112c30295d8be2e18e55d847373c50483ed1902" - integrity sha512-fTQJpqSt3Xo9Mn/WrdblNGAfcANM6XC3tAEi6YogB4s02DmTf93A8QsGb8uR0KR8TFcpcS8lgiW4ugAIYpnbrQ== + version "2.20.1" + resolved "https://registry.yarnpkg.com/hardhat/-/hardhat-2.20.1.tgz#3ad8f2b003a96c9ce80a55fec3575580ff2ddcd4" + integrity sha512-q75xDQiQtCZcTMBwjTovrXEU5ECr49baxr4/OBkIu/ULTPzlB20yk1dRWNmD2IFbAeAeXggaWvQAdpiScaHtPw== dependencies: "@ethersproject/abi" "^5.1.2" "@metamask/eth-sig-util" "^4.0.0" - "@nomicfoundation/ethereumjs-block" "5.0.2" - "@nomicfoundation/ethereumjs-blockchain" "7.0.2" - "@nomicfoundation/ethereumjs-common" "4.0.2" - "@nomicfoundation/ethereumjs-evm" "2.0.2" - "@nomicfoundation/ethereumjs-rlp" "5.0.2" - "@nomicfoundation/ethereumjs-statemanager" "2.0.2" - "@nomicfoundation/ethereumjs-trie" "6.0.2" - "@nomicfoundation/ethereumjs-tx" "5.0.2" - "@nomicfoundation/ethereumjs-util" "9.0.2" - "@nomicfoundation/ethereumjs-vm" "7.0.2" + "@nomicfoundation/ethereumjs-block" "5.0.4" + "@nomicfoundation/ethereumjs-blockchain" "7.0.4" + "@nomicfoundation/ethereumjs-common" "4.0.4" + "@nomicfoundation/ethereumjs-evm" "2.0.4" + "@nomicfoundation/ethereumjs-rlp" "5.0.4" + "@nomicfoundation/ethereumjs-statemanager" "2.0.4" + "@nomicfoundation/ethereumjs-trie" "6.0.4" + "@nomicfoundation/ethereumjs-tx" "5.0.4" + "@nomicfoundation/ethereumjs-util" "9.0.4" + "@nomicfoundation/ethereumjs-verkle" "0.0.2" + "@nomicfoundation/ethereumjs-vm" "7.0.4" "@nomicfoundation/solidity-analyzer" "^0.1.0" "@sentry/node" "^5.18.1" "@types/bn.js" "^5.1.0" @@ -5573,6 +5259,7 @@ hardhat@^2.12.7: 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" @@ -5603,11 +5290,6 @@ hardhat@^2.12.7: uuid "^8.3.2" ws "^7.4.6" -has-bigints@^1.0.1, has-bigints@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/has-bigints/-/has-bigints-1.0.2.tgz#0871bd3e3d51626f6ca0966668ba35d5602d6eaa" - integrity sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ== - has-flag@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-1.0.0.tgz#9d9e793165ce017a00f00418c43f942a7b1d11fa" @@ -5623,40 +5305,28 @@ has-flag@^4.0.0: resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== -has-property-descriptors@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz#610708600606d36961ed04c196193b6a607fa861" - integrity sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ== +has-property-descriptors@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz#963ed7d071dc7bf5f084c5bfbe0d1b6222586854" + integrity sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg== dependencies: - get-intrinsic "^1.1.1" + es-define-property "^1.0.0" has-proto@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/has-proto/-/has-proto-1.0.1.tgz#1885c1305538958aff469fef37937c22795408e0" - integrity sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg== + version "1.0.3" + resolved "https://registry.yarnpkg.com/has-proto/-/has-proto-1.0.3.tgz#b31ddfe9b0e6e9914536a6ab286426d0214f77fd" + integrity sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q== -has-symbols@^1.0.0, has-symbols@^1.0.2, has-symbols@^1.0.3: +has-symbols@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.3.tgz#bb7b2c4349251dce87b125f7bdf874aa7c8b39f8" integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== -has-tostringtag@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.0.tgz#7e133818a7d394734f941e73c3d3f9291e658b25" - integrity sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ== - dependencies: - has-symbols "^1.0.2" - has-unicode@2.0.1, has-unicode@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/has-unicode/-/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" integrity sha512-8Rf9Y83NBReMnx0gFzA8JImQACstCYWUplepDa9xprwwtmgEZUF0h/i5xSA625zB/I37EtrswSST6OXxwaaIJQ== -has@^1.0.3: - version "1.0.4" - resolved "https://registry.yarnpkg.com/has/-/has-1.0.4.tgz#2eb2860e000011dae4f1406a86fe80e530fb2ec6" - integrity sha512-qdSAmqLF6209RFj4VVItywPMbm3vWylknmB3nvNiUIs72xAimcM8nVYxYr7ncvZq5qzk9MKIZR8ijqD/1QuYjQ== - hash-base@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/hash-base/-/hash-base-3.1.0.tgz#55c381d9e06e1d2997a883b4a3fddfe7f0d3af33" @@ -5666,14 +5336,6 @@ hash-base@^3.0.0: readable-stream "^3.6.0" safe-buffer "^5.2.0" -hash.js@1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/hash.js/-/hash.js-1.1.3.tgz#340dedbe6290187151c1ea1d777a3448935df846" - integrity sha512-/UETyP0W22QILqS+6HowevwhEFJ3MBJnwTf75Qob9Wz9t0DPuisL8kW8YZMK62dHAKE1c1p+gY1TtOLY+USEHA== - dependencies: - inherits "^2.0.3" - minimalistic-assert "^1.0.0" - hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3, hash.js@^1.1.7: version "1.1.7" resolved "https://registry.yarnpkg.com/hash.js/-/hash.js-1.1.7.tgz#0babca538e8d4ee4a0f8988d68866537a003cf42" @@ -5683,9 +5345,9 @@ hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3, hash.js@^1.1.7: minimalistic-assert "^1.0.1" hasown@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/hasown/-/hasown-2.0.0.tgz#f4c513d454a57b7c7e1650778de226b11700546c" - integrity sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA== + version "2.0.1" + resolved "https://registry.yarnpkg.com/hasown/-/hasown-2.0.1.tgz#26f48f039de2c0f8d3356c223fb8d50253519faa" + integrity sha512-1/th4MHjnwncwXsIW6QMzlvYL9kG5e/CpVvLRZe4XPa8TOUNbCELqmvhDmnkNsAjwaG4+I8gJJL0JBvTTLO9qA== dependencies: function-bind "^1.1.2" @@ -5824,6 +5486,13 @@ iconv-lite@^0.6.2: dependencies: safer-buffer ">= 2.1.2 < 3.0.0" +idna-uts46-hx@^2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/idna-uts46-hx/-/idna-uts46-hx-2.3.1.tgz#a1dc5c4df37eee522bf66d969cc980e00e8711f9" + integrity sha512-PWoF9Keq6laYdIRwwCdhTPl60xRqAloYNMQLiyUnG42VjT53oW07BXIRM+NK7eQjzXjAk2gUvX9caRxlnF9TAA== + dependencies: + punycode "2.1.0" + ieee754@^1.1.13, ieee754@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" @@ -5837,16 +5506,16 @@ ignore-walk@^5.0.1: minimatch "^5.0.1" ignore-walk@^6.0.0: - version "6.0.2" - resolved "https://registry.yarnpkg.com/ignore-walk/-/ignore-walk-6.0.2.tgz#c48f48397cf8ef6174fcc28aa5f8c1de6203d389" - integrity sha512-ezmQ1Dg2b3jVZh2Dh+ar6Eu2MqNSTkyb32HU2MAQQQX9tKM3q/UQ/9lf03lQ5hW+fOeoMnwxwkleZ0xcNp0/qg== + version "6.0.4" + resolved "https://registry.yarnpkg.com/ignore-walk/-/ignore-walk-6.0.4.tgz#89950be94b4f522225eb63a13c56badb639190e9" + integrity sha512-t7sv42WkwFkyKbivUCglsQW5YWMskWtbEf4MNKX5u/CCWHKSPzN4FtBQGsQZgCLbxOzpVlcbWVK5KB3auIOjSw== dependencies: - minimatch "^7.4.2" + minimatch "^9.0.0" -ignore@^5.0.4, ignore@^5.1.1, ignore@^5.2.0: - version "5.2.4" - resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.4.tgz#a291c0c6178ff1b960befe47fcdec301674a6324" - integrity sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ== +ignore@^5.0.4, ignore@^5.1.1, ignore@^5.2.0, ignore@^5.2.4: + version "5.3.1" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.3.1.tgz#5073e554cd42c5b33b394375f538b8593e34d4ef" + integrity sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw== immediate@^3.2.3: version "3.3.0" @@ -5859,11 +5528,11 @@ immediate@~3.2.3: integrity sha512-RrGCXRm/fRVqMIhqXrGEX9rRADavPiDFSoMb/k64i9XMk8uH4r/Omi5Ctierj6XzNecwDbO4WuFbDD1zmpl3Tg== immutable@^4.0.0-rc.12: - version "4.3.4" - resolved "https://registry.yarnpkg.com/immutable/-/immutable-4.3.4.tgz#2e07b33837b4bb7662f288c244d1ced1ef65a78f" - integrity sha512-fsXeu4J4i6WNWSikpI88v/PcVflZz+6kMhUfIwc5SY+poQRPnaf5V7qds6SUyUN3cVxEzuCab7QIoLOQ+DQ1wA== + version "4.3.5" + resolved "https://registry.yarnpkg.com/immutable/-/immutable-4.3.5.tgz#f8b436e66d59f99760dc577f5c99a4fd2a5cc5a0" + integrity sha512-8eabxkth9gZatlwl5TBuJnCsoTADlL6ftEr7A4qgdaTsPyreilDSnUk57SO+jfKcNtxPa22U5KK6DSeAYhpBJw== -import-fresh@^3.0.0, import-fresh@^3.2.1, import-fresh@^3.3.0: +import-fresh@^3.2.1, import-fresh@^3.3.0: version "3.3.0" resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" integrity sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw== @@ -5931,9 +5600,9 @@ init-package-json@5.0.0: validate-npm-package-name "^5.0.0" inquirer@^8.2.4: - version "8.2.5" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-8.2.5.tgz#d8654a7542c35a9b9e069d27e2df4858784d54f8" - integrity sha512-QAgPDQMEgrDssk1XiwwHoOGYF9BAbUcc1+j+FhEvaOt8/cKRqyLn0U5qA6F74fGhTMGxf92pOvPBeh29jQJDTQ== + version "8.2.6" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-8.2.6.tgz#733b74888195d8d400a67ac332011b5fae5ea562" + integrity sha512-M1WuAmb7pn9zdFRtQYk26ZBoY043Sse0wVDdk4Bppr+JOXyQYybdtvK+l9wUibhtjdjvtoiNy8tk+EgsYIUqKg== dependencies: ansi-escapes "^4.2.1" chalk "^4.1.1" @@ -5949,22 +5618,18 @@ inquirer@^8.2.4: string-width "^4.1.0" strip-ansi "^6.0.0" through "^2.3.6" - wrap-ansi "^7.0.0" - -internal-slot@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/internal-slot/-/internal-slot-1.0.5.tgz#f2a2ee21f668f8627a4667f309dc0f4fb6674986" - integrity sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ== - dependencies: - get-intrinsic "^1.2.0" - has "^1.0.3" - side-channel "^1.0.4" + wrap-ansi "^6.0.1" interpret@^1.0.0: version "1.4.0" resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.4.0.tgz#665ab8bc4da27a774a40584e812e3e0fa45b1a1e" integrity sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA== +invert-kv@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" + integrity sha512-xgs2NH9AE66ucSq4cNG1nhSFghr5l6tdL15Pk+jl46bmmBapgoaY/AacXyaDznAqmGL99TiLSQgO/XazFSKYeQ== + io-ts@1.10.4: version "1.10.4" resolved "https://registry.yarnpkg.com/io-ts/-/io-ts-1.10.4.tgz#cd5401b138de88e4f920adbcb7026e2d1967e6e2" @@ -5972,51 +5637,31 @@ io-ts@1.10.4: dependencies: fp-ts "^1.0.0" -ip@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/ip/-/ip-2.0.1.tgz#e8f3595d33a3ea66490204234b77636965307105" - integrity sha512-lJUL9imLTNi1ZfXT+DU6rBBdbiKGBuay9B6xGSPVjUeQwaH1RIGqef8RZkUtHioLmSNpPR5M4HVKJGm1j8FWVQ== +ip-address@^9.0.5: + version "9.0.5" + resolved "https://registry.yarnpkg.com/ip-address/-/ip-address-9.0.5.tgz#117a960819b08780c3bd1f14ef3c1cc1d3f3ea5a" + integrity sha512-zHtQzGojZXTwZTHQqra+ETKd4Sn3vgi7uBmlPoXVWZqYvuKmtI0l/VZTjqGmJY9x88GGOaZ9+G9ES8hC4T4X8g== + dependencies: + jsbn "1.1.0" + sprintf-js "^1.1.3" ipaddr.js@1.9.1: version "1.9.1" resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.9.1.tgz#bff38543eeb8984825079ff3a2a8e6cbd46781b3" integrity sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g== -is-accessor-descriptor@^0.1.6: - version "0.1.6" - resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz#a9e12cb3ae8d876727eeef3843f8a0897b5c98d6" - integrity sha512-e1BM1qnDbMRG3ll2U9dSK0UMHuWOs3pY3AtcFsmvwPtKL3MML/Q86i+GilLfvqEs4GW+ExB91tQ3Ig9noDIZ+A== - dependencies: - kind-of "^3.0.2" - -is-accessor-descriptor@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz#169c2f6d3df1f992618072365c9b0ea1f6878656" - integrity sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ== - dependencies: - kind-of "^6.0.0" - -is-array-buffer@^3.0.1, is-array-buffer@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/is-array-buffer/-/is-array-buffer-3.0.2.tgz#f2653ced8412081638ecb0ebbd0c41c6e0aecbbe" - integrity sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w== +is-accessor-descriptor@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-1.0.1.tgz#3223b10628354644b86260db29b3e693f5ceedd4" + integrity sha512-YBUanLI8Yoihw923YeFUS5fs0fF2f5TSFTNiYAAzhhDscDa3lEqYuz1pDOEP5KvX94I9ey3vsqjJcLVFVU+3QA== dependencies: - call-bind "^1.0.2" - get-intrinsic "^1.2.0" - is-typed-array "^1.1.10" + hasown "^2.0.0" is-arrayish@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" integrity sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg== -is-bigint@^1.0.1: - version "1.0.4" - resolved "https://registry.yarnpkg.com/is-bigint/-/is-bigint-1.0.4.tgz#08147a1875bc2b32005d41ccd8291dffc6691df3" - integrity sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg== - dependencies: - has-bigints "^1.0.1" - is-binary-path@~2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-2.1.0.tgz#ea1f7f3b80f064236e83470f86c09c254fb45b09" @@ -6024,29 +5669,16 @@ is-binary-path@~2.1.0: dependencies: binary-extensions "^2.0.0" -is-boolean-object@^1.1.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/is-boolean-object/-/is-boolean-object-1.1.2.tgz#5c6dc200246dd9321ae4b885a114bb1f75f63719" - integrity sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA== - dependencies: - call-bind "^1.0.2" - has-tostringtag "^1.0.0" - is-buffer@^1.1.5: version "1.1.6" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" integrity sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w== -is-buffer@^2.0.5, is-buffer@~2.0.3: +is-buffer@^2.0.5: version "2.0.5" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-2.0.5.tgz#ebc252e400d22ff8d77fa09888821a24a658c191" integrity sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ== -is-callable@^1.1.3, is-callable@^1.1.4, is-callable@^1.2.7: - version "1.2.7" - resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.7.tgz#3bc2a85ea742d9e36205dcacdd72ca1fdc51b055" - integrity sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA== - is-ci@3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/is-ci/-/is-ci-3.0.1.tgz#db6ecbed1bd659c43dac0f45661e7674103d1867" @@ -6054,51 +5686,35 @@ is-ci@3.0.1: dependencies: ci-info "^3.2.0" -is-core-module@^2.11.0, is-core-module@^2.5.0, is-core-module@^2.8.1: - version "2.12.0" - resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.12.0.tgz#36ad62f6f73c8253fd6472517a12483cf03e7ec4" - integrity sha512-RECHCBCd/viahWmwj6enj19sKbHfJrddi/6cBDsNTKbNq0f7VeaUkBo60BqzvPqo/W54ChS62Z5qyun7cfOMqQ== - dependencies: - has "^1.0.3" - -is-data-descriptor@^0.1.4: - version "0.1.4" - resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" - integrity sha512-+w9D5ulSoBNlmw9OHn3U2v51SyoCd0he+bB3xMl62oijhrspxowjU+AIcDY0N3iEJbUEkB15IlMASQsxYigvXg== - dependencies: - kind-of "^3.0.2" - -is-data-descriptor@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz#d84876321d0e7add03990406abbbbd36ba9268c7" - integrity sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ== +is-core-module@^2.13.0, is-core-module@^2.5.0, is-core-module@^2.8.1: + version "2.13.1" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.13.1.tgz#ad0d7532c6fea9da1ebdc82742d74525c6273384" + integrity sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw== dependencies: - kind-of "^6.0.0" + hasown "^2.0.0" -is-date-object@^1.0.1: - version "1.0.5" - resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.5.tgz#0841d5536e724c25597bf6ea62e1bd38298df31f" - integrity sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ== +is-data-descriptor@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-1.0.1.tgz#2109164426166d32ea38c405c1e0945d9e6a4eeb" + integrity sha512-bc4NlCDiCr28U4aEsQ3Qs2491gVq4V8G7MQyws968ImqjKuYtTJXrl7Vq7jsN7Ly/C3xj5KWFrY7sHNeDkAzXw== dependencies: - has-tostringtag "^1.0.0" + hasown "^2.0.0" is-descriptor@^0.1.0: - version "0.1.6" - resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-0.1.6.tgz#366d8240dde487ca51823b1ab9f07a10a78251ca" - integrity sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg== + version "0.1.7" + resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-0.1.7.tgz#2727eb61fd789dcd5bdf0ed4569f551d2fe3be33" + integrity sha512-C3grZTvObeN1xud4cRWl366OMXZTj0+HGyk4hvfpx4ZHt1Pb60ANSXqCK7pdOTeUQpRzECBSTphqvD7U+l22Eg== dependencies: - is-accessor-descriptor "^0.1.6" - is-data-descriptor "^0.1.4" - kind-of "^5.0.0" + is-accessor-descriptor "^1.0.1" + is-data-descriptor "^1.0.1" is-descriptor@^1.0.0, is-descriptor@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-1.0.2.tgz#3b159746a66604b04f8c81524ba365c5f14d86ec" - integrity sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg== + version "1.0.3" + resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-1.0.3.tgz#92d27cb3cd311c4977a4db47df457234a13cb306" + integrity sha512-JCNNGbwWZEVaSPtS45mdtrneRWJFp07LLmykxeFV5F6oBvNF8vHSfJuJgoT472pSfk+Mf8VnlrspaFBHWM8JAw== dependencies: - is-accessor-descriptor "^1.0.0" - is-data-descriptor "^1.0.0" - kind-of "^6.0.2" + is-accessor-descriptor "^1.0.1" + is-data-descriptor "^1.0.1" is-docker@^2.0.0, is-docker@^2.1.1: version "2.2.1" @@ -6115,6 +5731,13 @@ is-extglob@^2.1.1: resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" integrity sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ== +is-fullwidth-code-point@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" + integrity sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw== + dependencies: + number-is-nan "^1.0.0" + is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" @@ -6147,18 +5770,6 @@ is-lambda@^1.0.1: resolved "https://registry.yarnpkg.com/is-lambda/-/is-lambda-1.0.1.tgz#3d9877899e6a53efc0160504cde15f82e6f061d5" integrity sha512-z7CMFGNrENq5iFB9Bqo64Xk6Y9sg+epq1myIcdHaGnbMTYOxvzsEtdYqQUylB7LxfkvgrrjP32T6Ywciio9UIQ== -is-negative-zero@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/is-negative-zero/-/is-negative-zero-2.0.2.tgz#7bf6f03a28003b8b3965de3ac26f664d765f3150" - integrity sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA== - -is-number-object@^1.0.4: - version "1.0.7" - resolved "https://registry.yarnpkg.com/is-number-object/-/is-number-object-1.0.7.tgz#59d50ada4c45251784e9904f5246c742f07a42fc" - integrity sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ== - dependencies: - has-tostringtag "^1.0.0" - is-number@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/is-number/-/is-number-3.0.0.tgz#24fd6201a4782cf50561c810276afc7d12d71195" @@ -6208,21 +5819,6 @@ is-plain-object@^5.0.0: resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-5.0.0.tgz#4427f50ab3429e9025ea7d52e9043a9ef4159344" integrity sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q== -is-regex@^1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.1.4.tgz#eef5663cd59fa4c0ae339505323df6854bb15958" - integrity sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg== - dependencies: - call-bind "^1.0.2" - has-tostringtag "^1.0.0" - -is-shared-array-buffer@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz#8f259c573b60b6a32d4058a1a07430c0a7344c79" - integrity sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA== - dependencies: - call-bind "^1.0.2" - is-ssh@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/is-ssh/-/is-ssh-1.4.0.tgz#4f8220601d2839d8fa624b3106f8e8884f01b8b2" @@ -6240,20 +5836,6 @@ is-stream@^2.0.0: resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== -is-string@^1.0.5, is-string@^1.0.7: - version "1.0.7" - resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.7.tgz#0dd12bf2006f255bb58f695110eff7491eebc0fd" - integrity sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg== - dependencies: - has-tostringtag "^1.0.0" - -is-symbol@^1.0.2, is-symbol@^1.0.3: - version "1.0.4" - resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.4.tgz#a6dac93b635b063ca6872236de88910a57af139c" - integrity sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg== - dependencies: - has-symbols "^1.0.2" - is-text-path@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-text-path/-/is-text-path-1.0.1.tgz#4e1aa0fb51bfbcb3e92688001397202c1775b66e" @@ -6261,17 +5843,6 @@ is-text-path@^1.0.1: dependencies: text-extensions "^1.0.0" -is-typed-array@^1.1.10, is-typed-array@^1.1.9: - version "1.1.10" - resolved "https://registry.yarnpkg.com/is-typed-array/-/is-typed-array-1.1.10.tgz#36a5b5cb4189b575d1a3e4b08536bfb485801e3f" - integrity sha512-PJqgEHiWZvMpaFZ3uTc8kHPM4+4ADTlDniuQL7cU/UDA0Ql7F70yGfHph3cLNe+c9toaigv+DFzTJKhc2CtO6A== - dependencies: - available-typed-arrays "^1.0.5" - call-bind "^1.0.2" - for-each "^0.3.3" - gopd "^1.0.1" - has-tostringtag "^1.0.0" - is-typedarray@^1.0.0, is-typedarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" @@ -6287,12 +5858,10 @@ is-url@^1.2.4: resolved "https://registry.yarnpkg.com/is-url/-/is-url-1.2.4.tgz#04a4df46d28c4cff3d73d01ff06abeb318a1aa52" integrity sha512-ITvGim8FhRiYe4IQ5uHSkj7pVaPDrCTkNd3yq3cV7iZAcJdHTUMPMEHcqSOy9xZ9qFenQCvi+2wjH9a1nXqHww== -is-weakref@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-weakref/-/is-weakref-1.0.2.tgz#9529f383a9338205e89765e0392efc2f100f06f2" - integrity sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ== - dependencies: - call-bind "^1.0.2" +is-utf8@^0.2.0: + version "0.2.1" + resolved "https://registry.yarnpkg.com/is-utf8/-/is-utf8-0.2.1.tgz#4b0da1442104d1b336340e80797e865cf39f7d72" + integrity sha512-rMYPYvCzsXywIsldgLaSoPlw5PfoB/ssr7hY4pLfcodrA5M/eArza1a9VmTiNIBNMjOGr1Ow9mTyU2o69U6U9Q== is-windows@^1.0.1: version "1.0.2" @@ -6306,11 +5875,6 @@ is-wsl@^2.2.0: dependencies: is-docker "^2.0.0" -isarray@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/isarray/-/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf" - integrity sha512-D2S+3GLxWH+uhrNEcoh/fnmYeP8E8/zHl644d/jdA0g2uyXvy3sb0qxotE+ne0LtccHknQzWwZEzhak7oJ0COQ== - isarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" @@ -6336,29 +5900,29 @@ isstream@~0.1.2: resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" integrity sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g== -jackspeak@^2.0.3: - version "2.3.3" - resolved "https://registry.yarnpkg.com/jackspeak/-/jackspeak-2.3.3.tgz#95e4cbcc03b3eb357bf6bcce14a903fb3d1151e1" - integrity sha512-R2bUw+kVZFS/h1AZqBKrSgDmdmjApzgY0AlCPumopFiAlbUxE2gf+SCuBzQ0cP5hHmUmFYF5yw55T97Th5Kstg== +jackspeak@^2.3.5: + version "2.3.6" + resolved "https://registry.yarnpkg.com/jackspeak/-/jackspeak-2.3.6.tgz#647ecc472238aee4b06ac0e461acc21a8c505ca8" + integrity sha512-N3yCS/NegsOBokc8GAdM8UcmfsKiSS8cipheD/nivzr700H+nsMOxJjQnvwOcRYVuFkdH0wGUvW2WbXGmrZGbQ== dependencies: "@isaacs/cliui" "^8.0.2" optionalDependencies: "@pkgjs/parseargs" "^0.11.0" jake@^10.8.5: - version "10.8.5" - resolved "https://registry.yarnpkg.com/jake/-/jake-10.8.5.tgz#f2183d2c59382cb274226034543b9c03b8164c46" - integrity sha512-sVpxYeuAhWt0OTWITwT98oyV0GsXyMlXCF+3L1SuafBVUIr/uILGRB+NqwkzhgXKvoJpDIpQvqkUALgdmQsQxw== + version "10.8.7" + resolved "https://registry.yarnpkg.com/jake/-/jake-10.8.7.tgz#63a32821177940c33f356e0ba44ff9d34e1c7d8f" + integrity sha512-ZDi3aP+fG/LchyBzUM804VjddnwfSfsdeYkwt8NcbKRvo4rFkjhs456iLFn3k2ZUWvNe4i48WACDbza8fhq2+w== dependencies: async "^3.2.3" chalk "^4.0.2" - filelist "^1.0.1" - minimatch "^3.0.4" + filelist "^1.0.4" + minimatch "^3.1.2" jayson@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/jayson/-/jayson-4.0.0.tgz#145a0ced46f900934c9b307e1332bcb0c7dbdb17" - integrity sha512-v2RNpDCMu45fnLzSk47vx7I+QUaOsox6f5X0CUlabAFwxoP+8MfAY0NQRFwOEYXIxm8Ih5y6OaEa5KYiQMkyAA== + version "4.1.0" + resolved "https://registry.yarnpkg.com/jayson/-/jayson-4.1.0.tgz#60dc946a85197317f2b1439d672a8b0a99cea2f9" + integrity sha512-R6JlbyLN53Mjku329XoRT2zJAE6ZgOQ8f91ucYdMCD4nkGCF9kZSrcGXpHIU4jeKj58zUZke2p+cdQchU7Ly7A== dependencies: "@types/connect" "^3.4.33" "@types/node" "^12.12.54" @@ -6393,29 +5957,21 @@ js-sdsl@^4.1.4: resolved "https://registry.yarnpkg.com/js-sdsl/-/js-sdsl-4.4.2.tgz#2e3c031b1f47d3aca8b775532e3ebb0818e7f847" integrity sha512-dwXFwByc/ajSV6m5bcKAPwe4yDDF6D614pxmIi5odytzxRlwqF6nwoiCek80Ixc7Cvma5awClxrzFtxCQvcM8w== -js-sha3@0.5.7: - version "0.5.7" - resolved "https://registry.yarnpkg.com/js-sha3/-/js-sha3-0.5.7.tgz#0d4ffd8002d5333aabaf4a23eed2f6374c9f28e7" - integrity sha512-GII20kjaPX0zJ8wzkTbNDYMY7msuZcTWk8S5UOh6806Jq/wz1J8/bnr8uGU0DAUmYDjj2Mr4X1cW8v/GLYnR+g== - js-sha3@0.8.0, js-sha3@^0.8.0: version "0.8.0" resolved "https://registry.yarnpkg.com/js-sha3/-/js-sha3-0.8.0.tgz#b9b7a5da73afad7dedd0f8c463954cbde6818840" integrity sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q== +js-sha3@^0.5.7: + version "0.5.7" + resolved "https://registry.yarnpkg.com/js-sha3/-/js-sha3-0.5.7.tgz#0d4ffd8002d5333aabaf4a23eed2f6374c9f28e7" + integrity sha512-GII20kjaPX0zJ8wzkTbNDYMY7msuZcTWk8S5UOh6806Jq/wz1J8/bnr8uGU0DAUmYDjj2Mr4X1cW8v/GLYnR+g== + js-tokens@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== -js-yaml@3.13.1: - version "3.13.1" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847" - integrity sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw== - dependencies: - argparse "^1.0.7" - esprima "^4.0.0" - js-yaml@3.x, js-yaml@^3.10.0: version "3.14.1" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.1.tgz#dae812fdb3825fa306609a8717383c50c36a0537" @@ -6431,6 +5987,11 @@ js-yaml@4.1.0, js-yaml@^4.1.0: dependencies: argparse "^2.0.1" +jsbn@1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-1.1.0.tgz#b01307cb29b618a1ed26ec79e911f803c4da0040" + integrity sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A== + jsbn@~0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" @@ -6443,6 +6004,11 @@ json-bigint@^1.0.0: dependencies: bignumber.js "^9.0.0" +json-buffer@3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.1.tgz#9338802a30d3b6605fbe0613e094008ca8c05a13" + integrity sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ== + json-parse-better-errors@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" @@ -6454,9 +6020,9 @@ json-parse-even-better-errors@^2.3.0: integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== json-parse-even-better-errors@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-3.0.0.tgz#2cb2ee33069a78870a0c7e3da560026b89669cf7" - integrity sha512-iZbGHafX/59r39gPwVPRBGw0QQKnA7tte5pSMrhWOW7swGsVvVTjmfyAV9pNqk8YGT7tRCdxRu8uzcgZwoDooA== + version "3.0.1" + resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-3.0.1.tgz#02bb29fb5da90b5444581749c22cedd3597c6cb0" + integrity sha512-aatBvbL26wVUCLmbWdCpeu9iF5wOyWpagiKkInA+kfws3sWdBrTnsvN2CKcyCYyUrc7rebNBlK6+kteg7ksecg== json-schema-traverse@^0.4.1: version "0.4.1" @@ -6536,10 +6102,10 @@ jsprim@^1.2.2: json-schema "0.4.0" verror "1.10.0" -just-extend@^4.0.2: - version "4.2.1" - resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-4.2.1.tgz#ef5e589afb61e5d66b24eca749409a8939a8c744" - integrity sha512-g3UB796vUFIY90VIv/WX3L2c8CS2MdWUww3CNrYmqza1Fg0DURc2K/O4YrnklBdQarSJ/y8JnJYDGc+1iumQjg== +just-extend@^6.2.0: + version "6.2.0" + resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-6.2.0.tgz#b816abfb3d67ee860482e7401564672558163947" + integrity sha512-cYofQu2Xpom82S6qD778jBDpwvvy39s1l/hrYij2u9AMdQcGRpaBu6kY4mVhuno5kJVi1DAz4aiphA2WI1/OAw== keccak@3.0.1: version "3.0.1" @@ -6567,6 +6133,13 @@ keccak@^3.0.0, keccak@^3.0.2: node-gyp-build "^4.2.0" readable-stream "^3.6.0" +keyv@^4.5.3: + version "4.5.4" + resolved "https://registry.yarnpkg.com/keyv/-/keyv-4.5.4.tgz#a879a99e29452f942439f2a405e3af8b31d4de93" + integrity sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw== + dependencies: + json-buffer "3.0.1" + kind-of@^3.0.2, kind-of@^3.0.3: version "3.2.2" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" @@ -6579,7 +6152,7 @@ kind-of@^5.0.0, kind-of@^5.0.2: resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" integrity sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw== -kind-of@^6.0.0, kind-of@^6.0.2, kind-of@^6.0.3: +kind-of@^6.0.2, kind-of@^6.0.3: version "6.0.3" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.3.tgz#07c05034a6c349fa06e24fa35aa76db4580ce4dd" integrity sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw== @@ -6603,13 +6176,20 @@ lazy-cache@^2.0.1: dependencies: set-getter "^0.1.0" +lcid@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/lcid/-/lcid-1.0.0.tgz#308accafa0bc483a3867b4b6f2b9506251d1b835" + integrity sha512-YiGkH6EnGrDGqLMITnGjXtGmNtjoXw9SVUzcaos8RBi7Ps0VBylkq+vOcY9QE5poLasPCR849ucFUkl0UzUyOw== + dependencies: + invert-kv "^1.0.0" + lerna@^7.3.0: - version "7.3.0" - resolved "https://registry.yarnpkg.com/lerna/-/lerna-7.3.0.tgz#efecafbdce15694e2f6841256e073a3a2061053e" - integrity sha512-Dt8TH+J+c9+3MhTYcm5OxnNzXb87WG7GPNj3kidjYJjJY7KxIMDNU37qBTYRWA1h3wAeNKBplXVQYUPkGcYgkQ== + version "7.4.2" + resolved "https://registry.yarnpkg.com/lerna/-/lerna-7.4.2.tgz#03497125d7b7c8d463eebfe17a701b16bde2ad09" + integrity sha512-gxavfzHfJ4JL30OvMunmlm4Anw7d7Tq6tdVHzUukLdS9nWnxCN/QB21qR+VJYp5tcyXogHKbdUEGh6qmeyzxSA== dependencies: - "@lerna/child-process" "7.3.0" - "@lerna/create" "7.3.0" + "@lerna/child-process" "7.4.2" + "@lerna/create" "7.4.2" "@npmcli/run-script" "6.0.2" "@nx/devkit" ">=16.5.1 < 17" "@octokit/plugin-enterprise-rest" "6.0.1" @@ -6619,7 +6199,7 @@ lerna@^7.3.0: clone-deep "4.0.1" cmd-shim "6.0.1" columnify "1.6.0" - conventional-changelog-angular "6.0.0" + conventional-changelog-angular "7.0.0" conventional-changelog-core "5.0.1" conventional-recommended-bump "7.0.1" cosmiconfig "^8.2.0" @@ -6740,11 +6320,6 @@ level-supports@^2.0.1: resolved "https://registry.yarnpkg.com/level-supports/-/level-supports-2.1.0.tgz#9af908d853597ecd592293b2fad124375be79c5f" integrity sha512-E486g1NCjW5cF78KGPrMDRBYzPuueMZ6VBXHT6gC7A8UYWGiM14fGgp+s/L1oFfDWSPV/+SFkYCmZ0SiESkRKA== -level-supports@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/level-supports/-/level-supports-4.0.1.tgz#431546f9d81f10ff0fea0e74533a0e875c08c66a" - integrity sha512-PbXpve8rKeNcZ9C1mUicC9auIYFyGpkV9/i6g76tLgANwWhtG2v7I4xNBUlkn3lE2/dZF3Pi0ygYGtLc4RXXdA== - level-supports@~1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/level-supports/-/level-supports-1.0.1.tgz#2f530a596834c7301622521988e2c36bb77d122d" @@ -6752,14 +6327,6 @@ level-supports@~1.0.0: dependencies: xtend "^4.0.2" -level-transcoder@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/level-transcoder/-/level-transcoder-1.0.1.tgz#f8cef5990c4f1283d4c86d949e73631b0bc8ba9c" - integrity sha512-t7bFwFtsQeD8cl8NIoQ2iwxA0CL/9IFw7/9gAjOonH0PWTTiRfY7Hq+Ejbsxh86tXobDQ6IOiddjNYIfOBs06w== - dependencies: - buffer "^6.0.3" - module-error "^1.0.1" - level-ws@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/level-ws/-/level-ws-2.0.0.tgz#207a07bcd0164a0ec5d62c304b4615c54436d339" @@ -6769,14 +6336,6 @@ level-ws@^2.0.0: readable-stream "^3.1.0" xtend "^4.0.1" -level@^8.0.0: - version "8.0.0" - resolved "https://registry.yarnpkg.com/level/-/level-8.0.0.tgz#41b4c515dabe28212a3e881b61c161ffead14394" - integrity sha512-ypf0jjAk2BWI33yzEaaotpq7fkOPALKAgDBxggO6Q9HGX2MRXn0wbP1Jn/tJv1gtL867+YOjOB49WaUF3UoJNQ== - dependencies: - browser-level "^1.0.1" - classic-level "^1.2.0" - leveldown@6.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/leveldown/-/leveldown-6.1.0.tgz#7ab1297706f70c657d1a72b31b40323aa612b9ee" @@ -6841,9 +6400,9 @@ lines-and-columns@^1.1.6: integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== lines-and-columns@~2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-2.0.3.tgz#b2f0badedb556b747020ab8ea7f0373e22efac1b" - integrity sha512-cNOjgCnLB+FnvWWtyRTzmB3POJ+cXxTA81LoW7u8JdmhfXzriropYwpjShnz1QLLWsQwY7nIxoDmcPTwphDK9w== + version "2.0.4" + resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-2.0.4.tgz#d00318855905d2660d8c0822e3f5a4715855fc42" + integrity sha512-wM1+Z03eypVAVUCE7QdSqpVIvelbOakn1M0bPDoA4SGWPx3sNDVUiMo3L6To6WWGClB7VyXnhQ4Sn7gxiJbE6A== load-json-file@6.2.0: version "6.2.0" @@ -6855,6 +6414,17 @@ load-json-file@6.2.0: strip-bom "^4.0.0" type-fest "^0.6.0" +load-json-file@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-1.1.0.tgz#956905708d58b4bab4c2261b04f59f31c99374c0" + integrity sha512-cy7ZdNRXdablkXYNI049pthVeXFurRyb9+hA/dZzerZ0pGTx42z+y+ssxBaVV2l70t1muq5IdKhn4UtcoGUY9A== + dependencies: + graceful-fs "^4.1.2" + parse-json "^2.2.0" + pify "^2.0.0" + pinkie-promise "^2.0.0" + strip-bom "^2.0.0" + load-json-file@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-4.0.0.tgz#2f5f45ab91e33216234fd53adab668eb4ec0993b" @@ -6873,14 +6443,6 @@ locate-path@^2.0.0: p-locate "^2.0.0" path-exists "^3.0.0" -locate-path@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-3.0.0.tgz#dbec3b3ab759758071b58fe59fc41871af21400e" - integrity sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A== - dependencies: - p-locate "^3.0.0" - path-exists "^3.0.0" - locate-path@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-5.0.0.tgz#1afba396afd676a6d42504d0a67a3a7eb9f62aa0" @@ -6895,11 +6457,21 @@ locate-path@^6.0.0: dependencies: p-locate "^5.0.0" +lodash.assign@^4.0.3, lodash.assign@^4.0.6: + version "4.2.0" + resolved "https://registry.yarnpkg.com/lodash.assign/-/lodash.assign-4.2.0.tgz#0d99f3ccd7a6d261d19bdaeb9245005d285808e7" + integrity sha512-hFuH8TY+Yji7Eja3mGiuAxBqLagejScbG8GbG0j6o9vzn0YL14My+ktnqtZgFTosKymC9/44wP6s7xyuLfnClw== + lodash.camelcase@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/lodash.camelcase/-/lodash.camelcase-4.3.0.tgz#b28aa6288a2b9fc651035c7711f65ab6190331a6" integrity sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA== +lodash.clonedeep@^4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef" + integrity sha512-H5ZhCF25riFd9uB5UCkVKo61m3S/xZk1x4wA6yp/L3RFP6Z/eHH1ymQcGLo7J3GMPfm0V/7m1tryHuGVxpqEBQ== + lodash.get@^4.4.2: version "4.4.2" resolved "https://registry.yarnpkg.com/lodash.get/-/lodash.get-4.4.2.tgz#2d177f652fa31e939b4438d5341499dfa3825e99" @@ -6920,7 +6492,7 @@ lodash.truncate@^4.4.2: resolved "https://registry.yarnpkg.com/lodash.truncate/-/lodash.truncate-4.4.2.tgz#5a350da0b1113b837ecfffd5812cbe58d6eae193" integrity sha512-jttmRe7bRse52OsWIMDLaXxWqRAmtIUccAQ3garviCqJjafXOfNMO0yMfNpdD6zbGaTU0P5Nz7e7gAT6cKmJRw== -lodash@^4.17.11, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.16, lodash@^4.17.19, lodash@^4.17.21: +lodash@^4.17.11, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.21: version "4.17.21" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== @@ -6933,13 +6505,6 @@ log-ok@^0.1.1: ansi-green "^0.1.1" success-symbol "^0.1.0" -log-symbols@3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-3.0.0.tgz#f3a08516a5dea893336a7dee14d18a1cfdab77c4" - integrity sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ== - dependencies: - chalk "^2.4.2" - log-symbols@4.1.0, log-symbols@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-4.1.0.tgz#3fbdbb95b4683ac9fc785111e792e558d4abd503" @@ -6961,12 +6526,17 @@ log-utils@^0.2.1: time-stamp "^1.0.1" warning-symbol "^0.1.0" -loupe@^2.3.1: - version "2.3.6" - resolved "https://registry.yarnpkg.com/loupe/-/loupe-2.3.6.tgz#76e4af498103c532d1ecc9be102036a21f787b53" - integrity sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA== +loupe@^2.3.6: + version "2.3.7" + resolved "https://registry.yarnpkg.com/loupe/-/loupe-2.3.7.tgz#6e69b7d4db7d3ab436328013d37d1c8c3540c697" + integrity sha512-zSMINGVYkdpYSOBmLi0D1Uo7JU9nVdQKrHxC8eYlV+9YKK9WePqAlL7lSlorG/U2Fw1w0hTBmaa/jrQ3UbPHtA== dependencies: - get-func-name "^2.0.0" + get-func-name "^2.0.1" + +lru-cache@^10.0.0, "lru-cache@^9.1.1 || ^10.0.0": + version "10.2.0" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.2.0.tgz#0bd445ca57363465900f4d1f9bd8db343a4d95c3" + integrity sha512-2bIM8x+VAf6JT4bKAljS1qUWgMsqZRPGJS6FSahIMPVvctcNhyVp7AJu7quxOW9jwkryBReKZY5tY5JYv2n/7Q== lru-cache@^5.1.1: version "5.1.1" @@ -6987,16 +6557,6 @@ lru-cache@^7.4.4, lru-cache@^7.5.1, lru-cache@^7.7.1: resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-7.18.3.tgz#f793896e0fd0e954a59dfdd82f0773808df6aa89" integrity sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA== -lru-cache@^9.0.0: - version "9.0.2" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-9.0.2.tgz#97f13c6b20532fba9bae821c39cd7d471f65119d" - integrity sha512-7zYMKApzQ9qQE13xQUzbXVY3p2C5lh+9V+bs8M9fRf1TF59id+8jkljRWtIPfBfNP4yQAol5cqh/e8clxatdXw== - -"lru-cache@^9.1.1 || ^10.0.0": - version "10.0.1" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.0.1.tgz#0a3be479df549cca0e5d693ac402ff19537a6b7a" - integrity sha512-IJ4uwUTi2qCccrioU6g9g/5rvvVl13bsdczUUcqbciD9iLr095yj8DQKdObriEvuNSx325N1rV1O0sJFszx75g== - lru_map@^0.3.3: version "0.3.3" resolved "https://registry.yarnpkg.com/lru_map/-/lru_map-0.3.3.tgz#b5c8351b9464cbd750335a79650a0ec0e56118dd" @@ -7054,28 +6614,7 @@ make-fetch-happen@^10.0.3: socks-proxy-agent "^7.0.0" ssri "^9.0.0" -make-fetch-happen@^11.0.0, make-fetch-happen@^11.0.1: - version "11.1.0" - resolved "https://registry.yarnpkg.com/make-fetch-happen/-/make-fetch-happen-11.1.0.tgz#f26b05e89317e960b75fd5e080e40d40f8d7b2a5" - integrity sha512-7ChuOzCb1LzdQZrTy0ky6RsCoMYeM+Fh4cY0+4zsJVhNcH5Q3OJojLY1mGkD0xAhWB29lskECVb6ZopofwjldA== - dependencies: - agentkeepalive "^4.2.1" - cacache "^17.0.0" - http-cache-semantics "^4.1.1" - http-proxy-agent "^5.0.0" - https-proxy-agent "^5.0.0" - is-lambda "^1.0.1" - lru-cache "^7.7.1" - minipass "^4.0.0" - minipass-fetch "^3.0.0" - minipass-flush "^1.0.5" - minipass-pipeline "^1.2.4" - negotiator "^0.6.3" - promise-retry "^2.0.1" - socks-proxy-agent "^7.0.0" - ssri "^10.0.0" - -make-fetch-happen@^11.1.1: +make-fetch-happen@^11.0.0, make-fetch-happen@^11.0.1, make-fetch-happen@^11.1.1: version "11.1.1" resolved "https://registry.yarnpkg.com/make-fetch-happen/-/make-fetch-happen-11.1.1.tgz#85ceb98079584a9523d4bf71d32996e7e208549f" integrity sha512-rLWS7GCSTcEujjVBs2YqG7Y4643u8ucvCJeSRqiLYhesrDuzeuFIk37xREzAsfQaqzl8b9rNCE4m6J8tvX4Q8w== @@ -7149,15 +6688,6 @@ memdown@^5.0.0: ltgt "~2.2.0" safe-buffer "~5.2.0" -memory-level@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/memory-level/-/memory-level-1.0.0.tgz#7323c3fd368f9af2f71c3cd76ba403a17ac41692" - integrity sha512-UXzwewuWeHBz5krr7EvehKcmLFNoXxGcvuYhC41tRnkrTbJohtS7kVn9akmgirtRygg+f7Yjsfi8Uu5SGSQ4Og== - dependencies: - abstract-level "^1.0.0" - functional-red-black-tree "^1.0.1" - module-error "^1.0.1" - memorystream@^0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/memorystream/-/memorystream-0.3.1.tgz#86d7090b30ce455d63fbae12dda51a47ddcaf9b2" @@ -7277,13 +6807,6 @@ minimalistic-crypto-utils@^1.0.1: dependencies: brace-expansion "^1.1.7" -minimatch@3.0.4: - version "3.0.4" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" - integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== - dependencies: - brace-expansion "^1.1.7" - minimatch@3.0.5: version "3.0.5" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.5.tgz#4da8f1290ee0f0f8e83d60ca69f8f134068604a3" @@ -7298,6 +6821,13 @@ minimatch@5.0.1: dependencies: brace-expansion "^2.0.1" +minimatch@9.0.3, minimatch@^9.0.0, minimatch@^9.0.1: + version "9.0.3" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.3.tgz#a6e00c3de44c3a542bfaae70abfc22420a6da825" + integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== + dependencies: + brace-expansion "^2.0.1" + minimatch@^5.0.1: version "5.1.6" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.6.tgz#1cfcb8cf5522ea69952cd2af95ae09477f122a96" @@ -7305,13 +6835,6 @@ minimatch@^5.0.1: dependencies: brace-expansion "^2.0.1" -minimatch@^7.4.2: - version "7.4.6" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-7.4.6.tgz#845d6f254d8f4a5e4fd6baf44d5f10c8448365fb" - integrity sha512-sBz8G/YjVniEz6lKPNpKxXwazJe4c19fEfV2GDMX6AjFz+MX9uDWIZW8XreVhkFW3fkIdTv/gxWr/Kks5FFAVw== - dependencies: - brace-expansion "^2.0.1" - minimatch@^8.0.2: version "8.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-8.0.4.tgz#847c1b25c014d4e9a7f68aaf63dedd668a626229" @@ -7319,13 +6842,6 @@ minimatch@^8.0.2: dependencies: brace-expansion "^2.0.1" -minimatch@^9.0.0, minimatch@^9.0.1: - version "9.0.3" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.3.tgz#a6e00c3de44c3a542bfaae70abfc22420a6da825" - integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== - dependencies: - brace-expansion "^2.0.1" - minimist-options@4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/minimist-options/-/minimist-options-4.1.0.tgz#c0655713c53a8a2ebd77ffa247d342c40f010619" @@ -7359,11 +6875,11 @@ minipass-fetch@^2.0.3: encoding "^0.1.13" minipass-fetch@^3.0.0: - version "3.0.2" - resolved "https://registry.yarnpkg.com/minipass-fetch/-/minipass-fetch-3.0.2.tgz#2f7275ae13f2fb0f2a469cee4f78250c25c80ab3" - integrity sha512-/ZpF1CQaWYqjbhfFgKNt3azxztEpc/JUPuMkqOgrnMQqcU8CbE409AUdJYTIWryl3PP5CBaTJZT71N49MXP/YA== + version "3.0.4" + resolved "https://registry.yarnpkg.com/minipass-fetch/-/minipass-fetch-3.0.4.tgz#4d4d9b9f34053af6c6e597a64be8e66e42bf45b7" + integrity sha512-jHAqnA728uUpIaFm7NWsCnqKT6UqZz7GcI/bDpPATuwYyKwJwW0remxSCxUlKiEty+eopHGa3oc8WxgQ1FFJqg== dependencies: - minipass "^4.0.0" + minipass "^7.0.3" minipass-sized "^1.0.3" minizlib "^2.1.2" optionalDependencies: @@ -7405,7 +6921,7 @@ minipass@^3.0.0, minipass@^3.1.1, minipass@^3.1.6: dependencies: yallist "^4.0.0" -minipass@^4.0.0, minipass@^4.2.4: +minipass@^4.2.4: version "4.2.8" resolved "https://registry.yarnpkg.com/minipass/-/minipass-4.2.8.tgz#f0010f64393ecfc1d1ccb5f582bcaf45f48e1a3a" integrity sha512-fNzuVyifolSLFL4NzpF+wEF4qrgqaaKX0haXPQEdQ7NKAN+WecoKMHV09YcuL/DHxrUsYQOK3MiuDf7Ip2OXfQ== @@ -7415,10 +6931,10 @@ minipass@^5.0.0: resolved "https://registry.yarnpkg.com/minipass/-/minipass-5.0.0.tgz#3e9788ffb90b694a5d0ec94479a45b5d8738133d" integrity sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ== -"minipass@^5.0.0 || ^6.0.2 || ^7.0.0": - version "7.0.3" - resolved "https://registry.yarnpkg.com/minipass/-/minipass-7.0.3.tgz#05ea638da44e475037ed94d1c7efcc76a25e1974" - integrity sha512-LhbbwCfz3vsb12j/WkWQPZfKTsgqIe1Nf/ti1pKjYESGLHIVjWU96G9/ljLH4F9mWNVhlQOm0VySdAWzf05dpg== +"minipass@^5.0.0 || ^6.0.2 || ^7.0.0", minipass@^7.0.3: + version "7.0.4" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-7.0.4.tgz#dbce03740f50a4786ba994c1fb908844d27b038c" + integrity sha512-jYofLM5Dam9279rdkWzqHozUo4ybjdZmCsDHePy5V/PbBcVMiSZR97gmAy45aqi8CK1lG2ECd356FU86avfwUQ== minizlib@^2.1.1, minizlib@^2.1.2: version "2.1.2" @@ -7436,13 +6952,6 @@ mixin-object@^2.0.1: for-in "^0.1.3" is-extendable "^0.1.1" -mkdirp@0.5.5: - version "0.5.5" - resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.5.tgz#d91cefd62d1436ca0f41620e251288d420099def" - integrity sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ== - dependencies: - minimist "^1.2.5" - mkdirp@0.5.x, mkdirp@^0.5.1: version "0.5.6" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.6.tgz#7def03d2432dcae4ba1d611445c48396062255f6" @@ -7462,10 +6971,10 @@ mnemonist@^0.38.0: dependencies: obliterator "^2.0.0" -mocha@10.2.0, mocha@^10.0.0, mocha@^10.2.0: - version "10.2.0" - resolved "https://registry.yarnpkg.com/mocha/-/mocha-10.2.0.tgz#1fd4a7c32ba5ac372e03a17eef435bd00e5c68b8" - integrity sha512-IDY7fl/BecMwFHzoqF2sg/SHHANeBoMMXFlS9r0OXKDssYE1M5O43wUY/9BVPeIvfH2zmEbBfseqN9gBQZzXkg== +mocha@^10.0.0, mocha@^10.2.0: + version "10.3.0" + resolved "https://registry.yarnpkg.com/mocha/-/mocha-10.3.0.tgz#0e185c49e6dccf582035c05fa91084a4ff6e3fe9" + integrity sha512-uF2XJs+7xSLsrmIvn37i/wnc91nw7XjOQB8ccyx5aEgdnohr7n+rEiZP23WkCYHjilR6+EboEnbq/ZQDz4LSbg== dependencies: ansi-colors "4.1.1" browser-stdout "1.3.1" @@ -7474,13 +6983,12 @@ mocha@10.2.0, mocha@^10.0.0, mocha@^10.2.0: diff "5.0.0" escape-string-regexp "4.0.0" find-up "5.0.0" - glob "7.2.0" + glob "8.1.0" he "1.2.0" js-yaml "4.1.0" log-symbols "4.1.0" minimatch "5.0.1" ms "2.1.3" - nanoid "3.3.3" serialize-javascript "6.0.0" strip-json-comments "3.1.1" supports-color "8.1.1" @@ -7489,36 +6997,6 @@ mocha@10.2.0, mocha@^10.0.0, mocha@^10.2.0: yargs-parser "20.2.4" yargs-unparser "2.0.0" -mocha@^7.1.1: - version "7.2.0" - resolved "https://registry.yarnpkg.com/mocha/-/mocha-7.2.0.tgz#01cc227b00d875ab1eed03a75106689cfed5a604" - integrity sha512-O9CIypScywTVpNaRrCAgoUnJgozpIofjKUYmJhiCIJMiuYnLI6otcb1/kpW9/n/tJODHGZ7i8aLQoDVsMtOKQQ== - dependencies: - ansi-colors "3.2.3" - browser-stdout "1.3.1" - chokidar "3.3.0" - debug "3.2.6" - diff "3.5.0" - escape-string-regexp "1.0.5" - find-up "3.0.0" - glob "7.1.3" - growl "1.10.5" - he "1.2.0" - js-yaml "3.13.1" - log-symbols "3.0.0" - minimatch "3.0.4" - mkdirp "0.5.5" - ms "2.1.1" - node-environment-flags "1.0.6" - object.assign "4.1.0" - strip-json-comments "2.0.1" - supports-color "6.0.0" - which "1.3.1" - wide-align "1.1.3" - yargs "13.3.2" - yargs-parser "13.1.2" - yargs-unparser "1.6.0" - mock-require@^3.0.3: version "3.0.3" resolved "https://registry.yarnpkg.com/mock-require/-/mock-require-3.0.3.tgz#ccd544d9eae81dd576b3f219f69ec867318a1946" @@ -7528,9 +7006,9 @@ mock-require@^3.0.3: normalize-path "^2.1.1" mock-socket@^9.0.3: - version "9.2.1" - resolved "https://registry.yarnpkg.com/mock-socket/-/mock-socket-9.2.1.tgz#cc9c0810aa4d0afe02d721dcb2b7e657c00e2282" - integrity sha512-aw9F9T9G2zpGipLLhSNh6ZpgUyUl4frcVmRN08uE1NWPWg43Wx6+sGPDbQ7E5iFZZDJW5b5bypMeAEHqTbIFag== + version "9.3.1" + resolved "https://registry.yarnpkg.com/mock-socket/-/mock-socket-9.3.1.tgz#24fb00c2f573c84812aa4a24181bb025de80cc8e" + integrity sha512-qxBgB7Qa2sEQgHFjj0dSigq7fX4k6Saisd5Nelwp2q8mlbAFh5dHV9JTTlF8viYJLSSWgMCZFUom8PJcMNBoJw== mock-stdin@^1.0.0: version "1.0.0" @@ -7542,21 +7020,11 @@ modify-values@^1.0.1: resolved "https://registry.yarnpkg.com/modify-values/-/modify-values-1.0.1.tgz#b3939fa605546474e3e3e3c63d64bd43b4ee6022" integrity sha512-xV2bxeN6F7oYjZWTe/YPAy6MN2M+sL4u/Rlm2AHCIVGfo2p1yGmBHQ6vHehl4bRTZBdHu3TSkWdYgkwpYzAGSw== -module-error@^1.0.1, module-error@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/module-error/-/module-error-1.0.2.tgz#8d1a48897ca883f47a45816d4fb3e3c6ba404d86" - integrity sha512-0yuvsqSCv8LbaOKhnsQ/T5JhyFlCYLPXK3U2sgV10zoKQwzs/MyfuQUOZQ1V/6OCOJsK/TRgNVrPuPDqtdMFtA== - ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" integrity sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A== -ms@2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.1.tgz#30a5864eb3ebb0a66f2ebe6d727af06a09d86e0a" - integrity sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg== - ms@2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" @@ -7593,26 +7061,11 @@ mute-stream@~1.0.0: resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-1.0.0.tgz#e31bd9fe62f0aed23520aa4324ea6671531e013e" integrity sha512-avsJQhyd+680gKXyG/sQc0nXaC6rBkPOfyHYcFb9+hdkqQkR9bdnkJ0AMZhke0oesPqIO+mFFJ+IdBc7mst4IA== -nanoid@3.3.3: - version "3.3.3" - resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.3.tgz#fd8e8b7aa761fe807dba2d1b98fb7241bb724a25" - integrity sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w== - -napi-macros@^2.2.2: - version "2.2.2" - resolved "https://registry.yarnpkg.com/napi-macros/-/napi-macros-2.2.2.tgz#817fef20c3e0e40a963fbf7b37d1600bd0201044" - integrity sha512-hmEVtAGYzVQpCKdbQea4skABsdXW4RUh5t5mJ2zzqowJS2OyXZTU1KhDVFhx+NlWZ4ap9mqR9TcDO3LTTttd+g== - napi-macros@~2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/napi-macros/-/napi-macros-2.0.0.tgz#2b6bae421e7b96eb687aa6c77a7858640670001b" integrity sha512-A0xLykHtARfueITVDernsAWdtIMbOJgKgcluwENp3AlsKN/PloyO10HtmoqnFAQAcxPkgZN7wdfPfEd0zNGxbg== -natural-compare-lite@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/natural-compare-lite/-/natural-compare-lite-1.4.0.tgz#17b09581988979fddafe0201e931ba933c96cbb4" - integrity sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g== - natural-compare@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" @@ -7623,7 +7076,7 @@ negotiator@0.6.3, negotiator@^0.6.3: resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.3.tgz#58e323a72fedc0d6f9cd4d31fe49f51479590ccd" integrity sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg== -neo-async@^2.6.0: +neo-async@^2.6.2: version "2.6.2" resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== @@ -7634,15 +7087,15 @@ next-tick@^1.1.0: integrity sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ== nise@^5.1.2: - version "5.1.4" - resolved "https://registry.yarnpkg.com/nise/-/nise-5.1.4.tgz#491ce7e7307d4ec546f5a659b2efe94a18b4bbc0" - integrity sha512-8+Ib8rRJ4L0o3kfmyVCL7gzrohyDe0cMFTBa2d364yIrEGMEoetznKJx899YxjybU6bL9SQkYPSBBs1gyYs8Xg== + version "5.1.9" + resolved "https://registry.yarnpkg.com/nise/-/nise-5.1.9.tgz#0cb73b5e4499d738231a473cd89bd8afbb618139" + integrity sha512-qOnoujW4SV6e40dYxJOb3uvuoPHtmLzIk4TFo+j0jPJoC+5Z9xja5qH5JZobEPsa8+YYphMrOSwnrshEhG2qww== dependencies: - "@sinonjs/commons" "^2.0.0" - "@sinonjs/fake-timers" "^10.0.2" - "@sinonjs/text-encoding" "^0.7.1" - just-extend "^4.0.2" - path-to-regexp "^1.7.0" + "@sinonjs/commons" "^3.0.0" + "@sinonjs/fake-timers" "^11.2.2" + "@sinonjs/text-encoding" "^0.7.2" + just-extend "^6.2.0" + path-to-regexp "^6.2.1" nock@^12.0.1: version "12.0.3" @@ -7655,13 +7108,12 @@ nock@^12.0.1: propagate "^2.0.0" nock@^13.0.0: - version "13.3.0" - resolved "https://registry.yarnpkg.com/nock/-/nock-13.3.0.tgz#b13069c1a03f1ad63120f994b04bfd2556925768" - integrity sha512-HHqYQ6mBeiMc+N038w8LkMpDCRquCHWeNmN3v6645P3NhN2+qXOBqvPqo7Rt1VyCMzKhJ733wZqw5B7cQVFNPg== + version "13.5.4" + resolved "https://registry.yarnpkg.com/nock/-/nock-13.5.4.tgz#8918f0addc70a63736170fef7106a9721e0dc479" + integrity sha512-yAyTfdeNJGGBFxWdzSKCBYxs5FxLbCg5X5Q4ets974hcQzG1+qCxvIyOo4j2Ry6MUlhWVMX4OoYDefAIIwupjw== dependencies: debug "^4.1.0" json-stringify-safe "^5.0.1" - lodash "^4.17.21" propagate "^2.0.0" node-addon-api@^2.0.0: @@ -7681,14 +7133,6 @@ node-emoji@^1.10.0: dependencies: lodash "^4.17.21" -node-environment-flags@1.0.6: - version "1.0.6" - resolved "https://registry.yarnpkg.com/node-environment-flags/-/node-environment-flags-1.0.6.tgz#a30ac13621f6f7d674260a54dede048c3982c088" - integrity sha512-5Evy2epuL+6TM0lCQGpFIj6KwiEsGh1SrHUhTbNX+sLbBtjidPZFAnVK9y5yU1+h//RitLbRHTIMyxQPtxMdHw== - dependencies: - object.getownpropertydescriptors "^2.0.3" - semver "^5.7.0" - node-fetch@2.6.7: version "2.6.7" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.7.tgz#24de9fba827e3b4ae44dc8b20256a379160052ad" @@ -7697,9 +7141,9 @@ node-fetch@2.6.7: whatwg-url "^5.0.0" node-fetch@^2.6.7: - version "2.6.9" - resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.9.tgz#7c7f744b5cc6eb5fd404e0c7a9fec630a55657e6" - integrity sha512-DJm/CJkZkRjKKj4Zi4BsKVZh3ValV5IR5s7LVZnW+6YMh0W1BfNA8XSs6DLMGYlId5F3KnA70uu2qepcR08Qqg== + version "2.7.0" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d" + integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A== dependencies: whatwg-url "^5.0.0" @@ -7714,16 +7158,17 @@ node-gyp-build@4.4.0: integrity sha512-amJnQCcgtRVw9SvoebO3BKGESClrfXGCUTX9hSn1OuGQTQBOZmVd0Z0OlecpuRksKvbsUqALE8jls/ErClAPuQ== node-gyp-build@^4.2.0, node-gyp-build@^4.3.0: - version "4.7.1" - resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.7.1.tgz#cd7d2eb48e594874053150a9418ac85af83ca8f7" - integrity sha512-wTSrZ+8lsRRa3I3H8Xr65dLWSgCvY2l4AOnaeKdPA9TB/WYMPaTcrzf3rXvFoVvjKNVnu0CcWSx54qq9GKRUYg== + version "4.8.0" + resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.8.0.tgz#3fee9c1731df4581a3f9ead74664369ff00d26dd" + integrity sha512-u6fs2AEUljNho3EYTJNBfImO5QTo/J/1Etd+NVdCj7qWKUSN/bSLkZwhDv7I+w/MSC6qJ4cknepkAYykDdK8og== node-gyp@^9.0.0: - version "9.3.1" - resolved "https://registry.yarnpkg.com/node-gyp/-/node-gyp-9.3.1.tgz#1e19f5f290afcc9c46973d68700cbd21a96192e4" - integrity sha512-4Q16ZCqq3g8awk6UplT7AuxQ35XN4R/yf/+wSAwcBUAjg7l58RTactWaP8fIDTi0FzI7YcVLujwExakZlfWkXg== + version "9.4.1" + resolved "https://registry.yarnpkg.com/node-gyp/-/node-gyp-9.4.1.tgz#8a1023e0d6766ecb52764cc3a734b36ff275e185" + integrity sha512-OQkWKbjQKbGkMf/xqI1jjy3oCTgMKJac58G2+bjZb3fza6gW2YrCSdMQYaoTb70crvE//Gngr4f0AgVHmqHvBQ== dependencies: env-paths "^2.2.0" + exponential-backoff "^3.1.1" glob "^7.1.4" graceful-fs "^4.2.6" make-fetch-happen "^10.0.3" @@ -7815,9 +7260,9 @@ npm-bundled@^3.0.0: npm-normalize-package-bin "^3.0.0" npm-install-checks@^6.0.0: - version "6.1.1" - resolved "https://registry.yarnpkg.com/npm-install-checks/-/npm-install-checks-6.1.1.tgz#b459b621634d06546664207fde16810815808db1" - integrity sha512-dH3GmQL4vsPtld59cOn8uY0iOqRmqKvV+DLGwNXV/Q7MDgD2QfOADWd/mFXcIE5LVhYYGjA3baz6W9JneqnuCw== + version "6.3.0" + resolved "https://registry.yarnpkg.com/npm-install-checks/-/npm-install-checks-6.3.0.tgz#046552d8920e801fa9f919cad569545d60e826fe" + integrity sha512-W29RiK/xtpCGqn6f3ixfRYGk+zRyr+Ew9F2E20BfXxT5/euLdA/Nm7fO7OeTGuAmTs30cpgInyJ0cYe708YTZw== dependencies: semver "^7.1.1" @@ -7827,9 +7272,9 @@ npm-normalize-package-bin@^1.0.1: integrity sha512-EPfafl6JL5/rU+ot6P3gRSCpPDW5VmIzX959Ob1+ySFUuuYHWHekXpwdUZcKP5C+DS4GEtdJluwBjnsNDl+fSA== npm-normalize-package-bin@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/npm-normalize-package-bin/-/npm-normalize-package-bin-3.0.0.tgz#6097436adb4ef09e2628b59a7882576fe53ce485" - integrity sha512-g+DPQSkusnk7HYXr75NtzkIP4+N81i3RPsGFidF3DzHd9MT9wWngmqoeg/fnHFz5MNdtG4w03s+QnhewSLTT2Q== + version "3.0.1" + resolved "https://registry.yarnpkg.com/npm-normalize-package-bin/-/npm-normalize-package-bin-3.0.1.tgz#25447e32a9a7de1f51362c61a559233b89947832" + integrity sha512-dMxCf+zZ+3zeQZXKxmyuCKlIDPGuv8EF940xbkC4kQVDTtqoh6rJFO+JTKSA6/Rwi0getWmtuy4Itup0AMcaDQ== npm-package-arg@8.1.1: version "8.1.1" @@ -7868,29 +7313,16 @@ npm-packlist@^7.0.0: ignore-walk "^6.0.0" npm-pick-manifest@^8.0.0: - version "8.0.1" - resolved "https://registry.yarnpkg.com/npm-pick-manifest/-/npm-pick-manifest-8.0.1.tgz#c6acd97d1ad4c5dbb80eac7b386b03ffeb289e5f" - integrity sha512-mRtvlBjTsJvfCCdmPtiu2bdlx8d/KXtF7yNXNWe7G0Z36qWA9Ny5zXsI2PfBZEv7SXgoxTmNaTzGSbbzDZChoA== + version "8.0.2" + resolved "https://registry.yarnpkg.com/npm-pick-manifest/-/npm-pick-manifest-8.0.2.tgz#2159778d9c7360420c925c1a2287b5a884c713aa" + integrity sha512-1dKY+86/AIiq1tkKVD3l0WI+Gd3vkknVGAggsFeBkTvbhMQ1OND/LKkYv4JtXPKUJ8bOTCyLiqEg2P6QNdK+Gg== dependencies: npm-install-checks "^6.0.0" npm-normalize-package-bin "^3.0.0" npm-package-arg "^10.0.0" semver "^7.3.5" -npm-registry-fetch@^14.0.0, npm-registry-fetch@^14.0.3: - version "14.0.4" - resolved "https://registry.yarnpkg.com/npm-registry-fetch/-/npm-registry-fetch-14.0.4.tgz#43dfa55ce7c0d0c545d625c7a916bab5b95f7038" - integrity sha512-pMS2DRkwg+M44ct65zrN/Cr9IHK1+n6weuefAo6Er4lc+/8YBCU0Czq04H3ZiSigluh7pb2rMM5JpgcytctB+Q== - dependencies: - make-fetch-happen "^11.0.0" - minipass "^4.0.0" - minipass-fetch "^3.0.0" - minipass-json-stream "^1.0.1" - minizlib "^2.1.2" - npm-package-arg "^10.0.0" - proc-log "^3.0.0" - -npm-registry-fetch@^14.0.5: +npm-registry-fetch@^14.0.0, npm-registry-fetch@^14.0.3, npm-registry-fetch@^14.0.5: version "14.0.5" resolved "https://registry.yarnpkg.com/npm-registry-fetch/-/npm-registry-fetch-14.0.5.tgz#fe7169957ba4986a4853a650278ee02e568d115d" integrity sha512-kIDMIo4aBm6xg7jOttupWZamsZRkAqMqwqqbVXnUqstY5+tapvv6bkH/qMR76jdgV+YljEUCyWx3hRYMrJiAgA== @@ -7920,6 +7352,11 @@ npmlog@^6.0.0, npmlog@^6.0.2: gauge "^4.0.3" set-blocking "^2.0.0" +number-is-nan@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" + integrity sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ== + number-to-bn@1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/number-to-bn/-/number-to-bn-1.7.0.tgz#bb3623592f7e5f9e0030b1977bd41a0c53fe1ea0" @@ -7928,7 +7365,7 @@ number-to-bn@1.7.0: bn.js "4.11.6" strip-hex-prefix "1.0.0" -nx@16.10.0, nx@^16.5.5: +nx@16.10.0, "nx@>=16.5.1 < 17", nx@^16.5.5: version "16.10.0" resolved "https://registry.yarnpkg.com/nx/-/nx-16.10.0.tgz#b070461f7de0a3d7988bd78558ea84cda3543ace" integrity sha512-gZl4iCC0Hx0Qe1VWmO4Bkeul2nttuXdPpfnlcDKSACGu3ZIo+uySqwOF8yBAxSTIf8xe2JRhgzJN1aFkuezEBg== @@ -7981,59 +7418,6 @@ nx@16.10.0, nx@^16.5.5: "@nx/nx-win32-arm64-msvc" "16.10.0" "@nx/nx-win32-x64-msvc" "16.10.0" -nx@16.9.0, "nx@>=16.5.1 < 17": - version "16.9.0" - resolved "https://registry.yarnpkg.com/nx/-/nx-16.9.0.tgz#fad51967bb80c12b311f3699292566cf445232f0" - integrity sha512-5/AjO4XJkiTcyIiw+zPyeOBdoy2njS/9fYBFroB4402mFtbqKiWkfjt+9Tng1AWSQzxyuKQb0hopdUQTEPhdcw== - dependencies: - "@nrwl/tao" "*" - "@parcel/watcher" "2.0.4" - "@yarnpkg/lockfile" "^1.1.0" - "@yarnpkg/parsers" "3.0.0-rc.46" - "@zkochan/js-yaml" "0.0.6" - axios "^1.0.0" - chalk "^4.1.0" - cli-cursor "3.1.0" - cli-spinners "2.6.1" - cliui "^7.0.2" - dotenv "~16.3.1" - dotenv-expand "~10.0.0" - enquirer "~2.3.6" - figures "3.2.0" - flat "^5.0.2" - fs-extra "^11.1.0" - glob "7.1.4" - ignore "^5.0.4" - jest-diff "^29.4.1" - js-yaml "4.1.0" - jsonc-parser "3.2.0" - lines-and-columns "~2.0.3" - minimatch "3.0.5" - node-machine-id "1.1.12" - npm-run-path "^4.0.1" - open "^8.4.0" - semver "7.5.3" - string-width "^4.2.3" - strong-log-transformer "^2.1.0" - tar-stream "~2.2.0" - tmp "~0.2.1" - tsconfig-paths "^4.1.2" - tslib "^2.3.0" - v8-compile-cache "2.3.0" - yargs "^17.6.2" - yargs-parser "21.1.1" - optionalDependencies: - "@nx/nx-darwin-arm64" "16.9.0" - "@nx/nx-darwin-x64" "16.9.0" - "@nx/nx-freebsd-x64" "16.9.0" - "@nx/nx-linux-arm-gnueabihf" "16.9.0" - "@nx/nx-linux-arm64-gnu" "16.9.0" - "@nx/nx-linux-arm64-musl" "16.9.0" - "@nx/nx-linux-x64-gnu" "16.9.0" - "@nx/nx-linux-x64-musl" "16.9.0" - "@nx/nx-win32-arm64-msvc" "16.9.0" - "@nx/nx-win32-x64-msvc" "16.9.0" - oauth-sign@~0.9.0: version "0.9.0" resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" @@ -8053,21 +7437,11 @@ object-copy@^0.1.0: define-property "^0.2.5" kind-of "^3.0.3" -object-inspect@^1.12.3: - version "1.12.3" - resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.3.tgz#ba62dffd67ee256c8c086dfae69e016cd1f198b9" - integrity sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g== - -object-inspect@^1.9.0: +object-inspect@^1.13.1: version "1.13.1" resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.13.1.tgz#b96c6109324ccfef6b12216a956ca4dc2ff94bc2" integrity sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ== -object-keys@^1.0.11, object-keys@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" - integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== - object-visit@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object-visit/-/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" @@ -8075,36 +7449,6 @@ object-visit@^1.0.0: dependencies: isobject "^3.0.0" -object.assign@4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.0.tgz#968bf1100d7956bb3ca086f006f846b3bc4008da" - integrity sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w== - dependencies: - define-properties "^1.1.2" - function-bind "^1.1.1" - has-symbols "^1.0.0" - object-keys "^1.0.11" - -object.assign@^4.1.4: - version "4.1.4" - resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.4.tgz#9673c7c7c351ab8c4d0b516f4343ebf4dfb7799f" - integrity sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ== - dependencies: - call-bind "^1.0.2" - define-properties "^1.1.4" - has-symbols "^1.0.3" - object-keys "^1.1.1" - -object.getownpropertydescriptors@^2.0.3: - version "2.1.5" - resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.5.tgz#db5a9002489b64eef903df81d6623c07e5b4b4d3" - integrity sha512-yDNzckpM6ntyQiGTik1fKV1DcVDRS+w8bvpWNCBanvH5LfRX9O8WTHqQzG4RZwRAM4I0oU7TV11Lj5v0g20ibw== - dependencies: - array.prototype.reduce "^1.0.5" - call-bind "^1.0.2" - define-properties "^1.1.4" - es-abstract "^1.20.4" - obliterator@^2.0.0: version "2.0.4" resolved "https://registry.yarnpkg.com/obliterator/-/obliterator-2.0.4.tgz#fa650e019b2d075d745e44f1effeb13a2adbe816" @@ -8152,17 +7496,17 @@ optionator@^0.8.1: type-check "~0.3.2" word-wrap "~1.2.3" -optionator@^0.9.1: - version "0.9.1" - resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.9.1.tgz#4f236a6373dae0566a6d43e1326674f50c291499" - integrity sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw== +optionator@^0.9.3: + version "0.9.3" + resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.9.3.tgz#007397d44ed1872fdc6ed31360190f81814e2c64" + integrity sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg== dependencies: + "@aashutoshrathi/word-wrap" "^1.2.3" deep-is "^0.1.3" fast-levenshtein "^2.0.6" levn "^0.4.1" prelude-ls "^1.2.1" type-check "^0.4.0" - word-wrap "^1.2.3" ora@^5.4.1: version "5.4.1" @@ -8179,6 +7523,13 @@ ora@^5.4.1: strip-ansi "^6.0.0" wcwidth "^1.0.1" +os-locale@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-1.4.0.tgz#20f9f17ae29ed345e8bde583b13d2009803c14d9" + integrity sha512-PRT7ZORmwu2MEFt4/fv3Q+mEfN4zetKxufQrkShY2oGvUms9r8otu5HfdyIFHkYXjO7laNsoVGmM2MANfuTA8g== + dependencies: + lcid "^1.0.0" + os-tmpdir@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" @@ -8196,7 +7547,7 @@ p-limit@^1.1.0: dependencies: p-try "^1.0.0" -p-limit@^2.0.0, p-limit@^2.2.0: +p-limit@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" integrity sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== @@ -8217,13 +7568,6 @@ p-locate@^2.0.0: dependencies: p-limit "^1.1.0" -p-locate@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-3.0.0.tgz#322d69a05c0264b25997d9f40cd8a891ab0064a4" - integrity sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ== - dependencies: - p-limit "^2.0.0" - p-locate@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-4.1.0.tgz#a3428bb7088b3a60292f66919278b7c297ad4f07" @@ -8328,6 +7672,13 @@ parse-cache-control@^1.0.1: resolved "https://registry.yarnpkg.com/parse-cache-control/-/parse-cache-control-1.0.1.tgz#8eeab3e54fa56920fe16ba38f77fa21aacc2d74e" integrity sha512-60zvsJReQPX5/QP0Kzfd/VrpjScIQ7SHBW6bFCYfEP+fp0Eppr1SHhIO5nd1PjZtvclzSzES9D/p5nFJurwfWg== +parse-json@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-2.2.0.tgz#f480f40434ef80741f8469099f8dea18f55a4dc9" + integrity sha512-QR/GGaKCkhwk1ePQNYDRKYZ3mwU9ypsKhB0XyFnLQdomyEqk3e8wpW3V5Jp88zbxK4n5ST1nqo+g9juTpownhQ== + dependencies: + error-ex "^1.2.0" + parse-json@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0" @@ -8370,6 +7721,13 @@ path-browserify@^1.0.0: resolved "https://registry.yarnpkg.com/path-browserify/-/path-browserify-1.0.1.tgz#d98454a9c3753d5790860f16f68867b9e46be1fd" integrity sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g== +path-exists@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-2.1.0.tgz#0feb6c64f0fc518d9a754dd5efb62c7022761f4b" + integrity sha512-yTltuKuhtNeFJKa1PiRzfLAU5182q1y4Eb4XCJ3PBqyzEDkAZRzBrKKBct682ls9reBVHf9udYLN5Nd+K1B9BQ== + dependencies: + pinkie-promise "^2.0.0" + path-exists@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" @@ -8395,7 +7753,7 @@ path-parse@^1.0.6, path-parse@^1.0.7: resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== -path-scurry@^1.10.1: +path-scurry@^1.10.1, path-scurry@^1.6.1: version "1.10.1" resolved "https://registry.yarnpkg.com/path-scurry/-/path-scurry-1.10.1.tgz#9ba6bf5aa8500fe9fd67df4f0d9483b2b0bfc698" integrity sha512-MkhCqzzBEpPvxxQ71Md0b1Kk51W01lrYvlMzSUaIzNsODdd7mqhiimSZlr+VegAz5Z6Vzt9Xg2ttE//XBhH3EQ== @@ -8403,25 +7761,24 @@ path-scurry@^1.10.1: lru-cache "^9.1.1 || ^10.0.0" minipass "^5.0.0 || ^6.0.2 || ^7.0.0" -path-scurry@^1.6.1: - version "1.6.4" - resolved "https://registry.yarnpkg.com/path-scurry/-/path-scurry-1.6.4.tgz#020a9449e5382a4acb684f9c7e1283bc5695de66" - integrity sha512-Qp/9IHkdNiXJ3/Kon++At2nVpnhRiPq/aSvQN+H3U1WZbvNRK0RIQK/o4HMqPoXjpuGJUEWpHSs6Mnjxqh3TQg== - dependencies: - lru-cache "^9.0.0" - minipass "^5.0.0" - path-to-regexp@0.1.7: version "0.1.7" resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-0.1.7.tgz#df604178005f522f15eb4490e7247a1bfaa67f8c" integrity sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ== -path-to-regexp@^1.7.0: - version "1.8.0" - resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-1.8.0.tgz#887b3ba9d84393e87a0a0b9f4cb756198b53548a" - integrity sha512-n43JRhlUKUAlibEJhPeir1ncUID16QnEjNpwzNdO3Lm4ywrBpBZ5oLD0I6br9evr1Y9JTqwRtAh7JLoOzAQdVA== +path-to-regexp@^6.2.1: + version "6.2.1" + resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-6.2.1.tgz#d54934d6798eb9e5ef14e7af7962c945906918e5" + integrity sha512-JLyh7xT1kizaEvcaXOQwOc2/Yhw6KZOvPf1S8401UyLk86CU79LN3vl7ztXGm/pZ+YjoyAJ4rxmHwbkBXJX+yw== + +path-type@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-1.1.0.tgz#59c44f7ee491da704da415da5a4070ba4f8fe441" + integrity sha512-S4eENJz1pkiQn9Znv33Q+deTOKmbl+jj1Fl+qiP/vYezj+S8x+J3Uo0ISrx/QoEvIlOaDWJhPaRd1flJ9HXZqg== dependencies: - isarray "0.0.1" + graceful-fs "^4.1.2" + pify "^2.0.0" + pinkie-promise "^2.0.0" path-type@^3.0.0: version "3.0.0" @@ -8466,7 +7823,7 @@ pify@5.0.0: resolved "https://registry.yarnpkg.com/pify/-/pify-5.0.0.tgz#1f5eca3f5e87ebec28cc6d54a0e4aaf00acc127f" integrity sha512-eW/gHNMlxdSP6dmG6uJip6FXN0EQBwm2clYYd8Wul42Cwu/DK8HEftzsapcNdYe2MfLiIwZqsDk2RDEsTE79hA== -pify@^2.3.0: +pify@^2.0.0, pify@^2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" integrity sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog== @@ -8481,6 +7838,18 @@ pify@^4.0.1: resolved "https://registry.yarnpkg.com/pify/-/pify-4.0.1.tgz#4b2cd25c50d598735c50292224fd8c6df41e3231" integrity sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g== +pinkie-promise@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/pinkie-promise/-/pinkie-promise-2.0.1.tgz#2135d6dfa7a358c069ac9b178776288228450ffa" + integrity sha512-0Gni6D4UcLTbv9c57DfxDGdr41XfgUjqWZu492f0cIGr16zDU06BWP/RAEvOuo7CQ0CNjHaLlM59YJJFm3NWlw== + dependencies: + pinkie "^2.0.0" + +pinkie@^2.0.0: + version "2.0.4" + resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" + integrity sha512-MnUuEycAemtSaeFSjXKW/aroV7akBbY+Sv+RkyqFjgAe73F+MR0TBWKBRDkmfWq/HiFmdavfZ1G7h4SPZXaCSg== + pkg-dir@^4.2.0: version "4.2.0" resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-4.2.0.tgz#f099133df7ede422e81d1d8448270eeb3e4261f3" @@ -8511,18 +7880,18 @@ prettier-linter-helpers@^1.0.0: fast-diff "^1.1.2" prettier-plugin-solidity@^1.1.2: - version "1.1.3" - resolved "https://registry.yarnpkg.com/prettier-plugin-solidity/-/prettier-plugin-solidity-1.1.3.tgz#9a35124f578404caf617634a8cab80862d726cba" - integrity sha512-fQ9yucPi2sBbA2U2Xjh6m4isUTJ7S7QLc/XDDsktqqxYfTwdYKJ0EnnywXHwCGAaYbQNK+HIYPL1OemxuMsgeg== + version "1.3.1" + resolved "https://registry.yarnpkg.com/prettier-plugin-solidity/-/prettier-plugin-solidity-1.3.1.tgz#59944d3155b249f7f234dee29f433524b9a4abcf" + integrity sha512-MN4OP5I2gHAzHZG1wcuJl0FsLS3c4Cc5494bbg+6oQWBPuEamjwDvmGfFMZ6NFzsh3Efd9UUxeT7ImgjNH4ozA== dependencies: - "@solidity-parser/parser" "^0.16.0" - semver "^7.3.8" - solidity-comments-extractor "^0.0.7" + "@solidity-parser/parser" "^0.17.0" + semver "^7.5.4" + solidity-comments-extractor "^0.0.8" prettier@^2.3.1, prettier@^2.8.4: - version "2.8.7" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.7.tgz#bb79fc8729308549d28fe3a98fce73d2c0656450" - integrity sha512-yPngTo3aXUUmyuTjeTUT75txrf+aMh9FiD7q9ZE/i6r0bPb22g4FsE6Y338PQX1bmfy08i9QQCB7/rcUAVntfw== + version "2.8.8" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.8.tgz#e8c5d7e98a4305ffe3de2e1fc4aca1a71c28b1da" + integrity sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q== pretty-format@^29.7.0: version "29.7.0" @@ -8668,15 +8037,20 @@ psl@^1.1.28: resolved "https://registry.yarnpkg.com/psl/-/psl-1.9.0.tgz#d0df2a137f00794565fcaf3b2c00cd09f8d5a5a7" integrity sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag== -punycode@1.3.2: - version "1.3.2" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.3.2.tgz#9653a036fb7c1ee42342f2325cceefea3926c48d" - integrity sha512-RofWgt/7fL5wP1Y7fxE7/EmTLzQVnB0ycyibJ0OOHIlJqTNzglYFxVwETOcIoJqJmpDXJ9xImDv+Fq34F/d4Dw== +punycode@2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.0.tgz#5f863edc89b96db09074bad7947bf09056ca4e7d" + integrity sha512-Yxz2kRwT90aPiWEMHVYnEf4+rhwF1tBmmZ4KepCP+Wkium9JxtWnUm1nqGwpiAHr/tnTSeHqr3wb++jgSkXjhA== + +punycode@^1.4.1: + version "1.4.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" + integrity sha512-jmYNElW7yvO7TV33CjSmvSiE2yco3bV2czu/OzDKdMNVZQWfxCblURLhf+47syQRBntjfLdd/H0egrzIG+oaFQ== punycode@^2.1.0, punycode@^2.1.1: - version "2.3.0" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.3.0.tgz#f67fa67c94da8f4d0cfff981aee4118064199b8f" - integrity sha512-rRV+zQD8tVFys26lAGR9WUuS4iUAngJScM+ZRSKtvl5tKeZ2t5bvdNFdNHBW9FWR4guGHlgmsZ1G7BSm2wTbuA== + version "2.3.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.3.1.tgz#027422e2faec0b25e1549c3e1bd8309b9133b6e5" + integrity sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg== qs@6.11.0: version "6.11.0" @@ -8685,7 +8059,7 @@ qs@6.11.0: dependencies: side-channel "^1.0.4" -qs@^6.4.0: +qs@^6.11.2, qs@^6.4.0: version "6.11.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.2.tgz#64bea51f12c1f5da1bc01496f48ffcff7c69d7d9" integrity sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA== @@ -8697,11 +8071,6 @@ qs@~6.5.2: resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.3.tgz#3aeeffc91967ef6e35c0e488ef46fb296ab76aad" integrity sha512-qxXIEh4pCGfHICj1mAJQ2/2XVZkjCDTcEgfoSQxc/fYivUZxTkk7L3bDBJSoNrEzXI17oUO5Dp07ktqE5KzczA== -querystring@0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/querystring/-/querystring-0.2.0.tgz#b209849203bb25df820da756e747005878521620" - integrity sha512-X/xY82scca2tau62i9mDyU9K+I+djTMUsvwf7xnUX5GLvVzgJybOJf4Y6o9Zx3oJK/LSXg5tTZBjwzqVPaPO2g== - queue-microtask@^1.2.2, queue-microtask@^1.2.3: version "1.2.3" resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" @@ -8733,16 +8102,6 @@ range-parser@~1.2.1: resolved "https://registry.yarnpkg.com/range-parser/-/range-parser-1.2.1.tgz#3cf37023d199e1c24d1a55b84800c2f3e6468031" integrity sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg== -raw-body@2.5.1: - version "2.5.1" - resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.5.1.tgz#fe1b1628b181b700215e5fd42389f98b71392857" - integrity sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig== - dependencies: - bytes "3.1.2" - http-errors "2.0.0" - iconv-lite "0.4.24" - unpipe "1.0.0" - raw-body@2.5.2, raw-body@^2.4.1: version "2.5.2" resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.5.2.tgz#99febd83b90e08975087e8f1f9419a149366b68a" @@ -8771,7 +8130,7 @@ read-package-json-fast@^3.0.0: json-parse-even-better-errors "^3.0.0" npm-normalize-package-bin "^3.0.0" -read-package-json@6.0.4: +read-package-json@6.0.4, read-package-json@^6.0.0: version "6.0.4" resolved "https://registry.yarnpkg.com/read-package-json/-/read-package-json-6.0.4.tgz#90318824ec456c287437ea79595f4c2854708836" integrity sha512-AEtWXYfopBj2z5N5PbkAOeNHRPUg5q+Nen7QLxV8M2zJq1ym6/lCz3fYNTCXe19puu2d06jfHhrP7v/S2PtMMw== @@ -8781,15 +8140,13 @@ read-package-json@6.0.4: normalize-package-data "^5.0.0" npm-normalize-package-bin "^3.0.0" -read-package-json@^6.0.0: - version "6.0.1" - resolved "https://registry.yarnpkg.com/read-package-json/-/read-package-json-6.0.1.tgz#566cb06bc05dbddefba4607e9096d5a9efbcd836" - integrity sha512-AaHqXxfAVa+fNL07x8iAghfKOds/XXsu7zoouIVsbm7PEbQ3nMWXlvjcbrNLjElnUHWQtAo4QEa0RXuvD4XlpA== +read-pkg-up@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-1.0.1.tgz#9d63c13276c065918d57f002a57f40a1b643fb02" + integrity sha512-WD9MTlNtI55IwYUS27iHh9tK3YoIVhxis8yKhLpTqWtml739uXc9NWTpxoHkfZf3+DkCCsXox94/VWZniuZm6A== dependencies: - glob "^9.3.0" - json-parse-even-better-errors "^3.0.0" - normalize-package-data "^5.0.0" - npm-normalize-package-bin "^3.0.0" + find-up "^1.0.0" + read-pkg "^1.0.0" read-pkg-up@^3.0.0: version "3.0.0" @@ -8808,6 +8165,15 @@ read-pkg-up@^7.0.1: read-pkg "^5.2.0" type-fest "^0.8.1" +read-pkg@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-1.1.0.tgz#f5ffaa5ecd29cb31c0474bca7d756b6bb29e3f28" + integrity sha512-7BGwRHqt4s/uVbuyoeejRn4YmFnYZiFl4AuaeXHlgZf3sONF0SOGlxs2Pw8g6hCKupo08RafIO5YXFNOKTfwsQ== + dependencies: + load-json-file "^1.0.0" + normalize-package-data "^2.3.2" + path-type "^1.0.0" + read-pkg@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-3.0.0.tgz#9cbc686978fee65d16c00e2b19c237fcf6e38389" @@ -8856,13 +8222,6 @@ readable-stream@^3.0.0, readable-stream@^3.0.2, readable-stream@^3.1.0, readable string_decoder "^1.1.1" util-deprecate "^1.0.1" -readdirp@~3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.2.0.tgz#c30c33352b12c96dfb4b895421a49fd5a9593839" - integrity sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ== - dependencies: - picomatch "^2.0.4" - readdirp@~3.6.0: version "3.6.0" resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.6.0.tgz#74a370bd857116e245b29cc97340cd431a02a6c7" @@ -8934,15 +8293,6 @@ reduce-flatten@^2.0.0: resolved "https://registry.yarnpkg.com/reduce-flatten/-/reduce-flatten-2.0.0.tgz#734fd84e65f375d7ca4465c69798c25c9d10ae27" integrity sha512-EJ4UNY/U1t2P/2k6oqotuX2Cc3T6nxJwsM0N0asT7dhrtH1ltUxDn4NalSYmPE2rCkVpcf/X6R0wDwcFpzhd4w== -regexp.prototype.flags@^1.4.3: - version "1.4.3" - resolved "https://registry.yarnpkg.com/regexp.prototype.flags/-/regexp.prototype.flags-1.4.3.tgz#87cab30f80f66660181a3bb7bf5981a872b367ac" - integrity sha512-fjggEOO3slI6Wvgjwflkc4NFRCTZAu5CnNfBd5qOMYhWdn67nJBBu34/TkD++eeFmd8C9r9jfXJ27+nSiRkSUA== - dependencies: - call-bind "^1.0.2" - define-properties "^1.1.3" - functions-have-names "^1.2.2" - remove-trailing-separator@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" @@ -8962,23 +8312,7 @@ req-from@^2.0.0: dependencies: resolve-from "^3.0.0" -request-promise-core@1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/request-promise-core/-/request-promise-core-1.1.4.tgz#3eedd4223208d419867b78ce815167d10593a22f" - integrity sha512-TTbAfBBRdWD7aNNOoVOBH4pN/KigV6LyapYNNlAPA8JwbovRti1E88m3sYAwsLi5ryhPKsE9APwnjFTgdUjTpw== - dependencies: - lodash "^4.17.19" - -request-promise-native@^1.0.5: - version "1.0.9" - resolved "https://registry.yarnpkg.com/request-promise-native/-/request-promise-native-1.0.9.tgz#e407120526a5efdc9a39b28a5679bf47b9d9dc28" - integrity sha512-wcW+sIUiWnKgNY0dqCpOZkUbF/I+YPi+f09JZIDa39Ec+q82CpSYniDp+ISgTTbKmnpJWASeJBPZmoxH84wt3g== - dependencies: - request-promise-core "1.1.4" - stealthy-require "^1.1.1" - tough-cookie "^2.3.3" - -request@^2.85.0, request@^2.88.0: +request@^2.85.0: version "2.88.2" resolved "https://registry.yarnpkg.com/request/-/request-2.88.2.tgz#d73c918731cb5a87da047e207234146f664d12b3" integrity sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw== @@ -9009,15 +8343,20 @@ require-directory@^2.1.1: resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== +require-from-string@^1.1.0: + version "1.2.1" + resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-1.2.1.tgz#529c9ccef27380adfec9a2f965b649bbee636418" + integrity sha512-H7AkJWMobeskkttHyhTVtS0fxpFLjxhbfMa6Bk3wimP7sdPRGL3EyCg3sAQenFfAe+xQ+oAc85Nmtvq0ROM83Q== + require-from-string@^2.0.0, require-from-string@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.2.tgz#89a7fdd938261267318eafe14f9c32e598c36909" integrity sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw== -require-main-filename@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz#d0b329ecc7cc0f61649f62215be69af54aa8989b" - integrity sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg== +require-main-filename@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" + integrity sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug== resolve-cwd@^3.0.0: version "3.0.0" @@ -9054,11 +8393,11 @@ resolve@1.17.0: path-parse "^1.0.6" resolve@^1.1.6, resolve@^1.10.0: - version "1.22.2" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.2.tgz#0ed0943d4e301867955766c9f3e1ae6d01c6845f" - integrity sha512-Sb+mjNHOULsBv818T40qSPeRiuWLyaGMa5ewydRLFimneixmVy2zdivRl+AF6jaYPC8ERxGDmFSiqui6SfPd+g== + version "1.22.8" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.8.tgz#b6c87a9f2aa06dfab52e3d70ac8cde321fa5a48d" + integrity sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw== dependencies: - is-core-module "^2.11.0" + is-core-module "^2.13.0" path-parse "^1.0.7" supports-preserve-symlinks-flag "^1.0.0" @@ -9087,7 +8426,7 @@ rimraf@^2.2.8: dependencies: glob "^7.1.3" -rimraf@^3.0.0, rimraf@^3.0.2: +rimraf@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-3.0.2.tgz#f1a5402ba6220ad52cc1282bac1ae3aa49fd061a" integrity sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA== @@ -9128,13 +8467,6 @@ run-async@^2.4.0: resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.4.1.tgz#8440eccf99ea3e70bd409d49aab88e10c189a455" integrity sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ== -run-parallel-limit@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/run-parallel-limit/-/run-parallel-limit-1.1.0.tgz#be80e936f5768623a38a963262d6bef8ff11e7ba" - integrity sha512-jJA7irRNM91jaKc3Hcl1npHsFLOXOoTkPCUL1JEa1R82O2miplXXRaGdjW/KM/98YQWDhJLiSs793CnXfblJUw== - dependencies: - queue-microtask "^1.2.2" - run-parallel@^1.1.9: version "1.2.0" resolved "https://registry.yarnpkg.com/run-parallel/-/run-parallel-1.2.0.tgz#66d1368da7bdf921eb9d95bd1a9229e7f21a43ee" @@ -9142,15 +8474,27 @@ run-parallel@^1.1.9: dependencies: queue-microtask "^1.2.2" +rust-verkle-wasm@^0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/rust-verkle-wasm/-/rust-verkle-wasm-0.0.1.tgz#fd8396a7060d8ee8ea10da50ab6e862948095a74" + integrity sha512-BN6fiTsxcd2dCECz/cHtGTt9cdLJR925nh7iAuRcj8ymKw7OOaPmCneQZ7JePOJ/ia27TjEL91VdOi88Yf+mcA== + +rustbn-wasm@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/rustbn-wasm/-/rustbn-wasm-0.2.0.tgz#0407521fb55ae69eeb4968d01885d63efd1c4ff9" + integrity sha512-FThvYFNTqrEKGqXuseeg0zR7yROh/6U1617mCHF68OVqrN1tNKRN7Tdwy4WayPVsCmmK+eMxtIZX1qL6JxTkMg== + dependencies: + "@scure/base" "^1.1.1" + rustbn.js@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/rustbn.js/-/rustbn.js-0.2.0.tgz#8082cb886e707155fd1cb6f23bd591ab8d55d0ca" integrity sha512-4VlvkRUuCJvr2J6Y0ImW7NvTCriMi7ErOAqWk1y69vAdoNIzCF3yPmgeNzx+RQTLEDFq5sHfscn1MwHxP9hNfA== rxjs@^7.5.5: - version "7.8.0" - resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-7.8.0.tgz#90a938862a82888ff4c7359811a595e14e1e09a4" - integrity sha512-F2+gxDshqmIub1KdvZkaEfGDwLNpPvk9Fs6LD/MyQxNgMds/WH9OdDDXOmxUZpME+iSK3rQCctkL0DYyytUqMg== + version "7.8.1" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-7.8.1.tgz#6f6f3d99ea8044291efd92e7c7fcf562c4057543" + integrity sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg== dependencies: tslib "^2.1.0" @@ -9164,15 +8508,6 @@ safe-buffer@~5.1.0, safe-buffer@~5.1.1: resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== -safe-regex-test@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/safe-regex-test/-/safe-regex-test-1.0.0.tgz#793b874d524eb3640d1873aad03596db2d4f2295" - integrity sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA== - dependencies: - call-bind "^1.0.2" - get-intrinsic "^1.1.3" - is-regex "^1.1.4" - "safer-buffer@>= 2.1.2 < 3", "safer-buffer@>= 2.1.2 < 3.0.0", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" @@ -9198,11 +8533,6 @@ sc-istanbul@^0.4.5: which "^1.1.1" wordwrap "^1.0.0" -scrypt-js@2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/scrypt-js/-/scrypt-js-2.0.4.tgz#32f8c5149f0797672e551c07e230f834b6af5f16" - integrity sha512-4KsaGcPnuhtCZQCxFxN3GVYIhKFPTdLd8PLC552XwbMndtD0cjRFAhDuuydXQ0h08ZfPgzqe6EKHozpuH74iDw== - scrypt-js@3.0.1, scrypt-js@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/scrypt-js/-/scrypt-js-3.0.1.tgz#d314a57c2aef69d1ad98a138a21fe9eafa9ee312" @@ -9227,7 +8557,7 @@ semaphore-async-await@^1.5.1: resolved "https://registry.yarnpkg.com/semaphore-async-await/-/semaphore-async-await-1.5.1.tgz#857bef5e3644601ca4b9570b87e9df5ca12974fa" integrity sha512-b/ptP11hETwYWpeilHXXQiV5UJNJl7ZWWooKRE5eBIYWoom6dZ0SluCIdCtKycsMtZgKWE01/qAw6jblw1YVhg== -"semver@2 || 3 || 4 || 5", semver@^5.5.0, semver@^5.6.0, semver@^5.7.0: +"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.5.0, semver@^5.6.0: version "5.7.2" resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== @@ -9244,10 +8574,10 @@ semver@^6.3.0: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== -semver@^7.0.0, semver@^7.1.1, semver@^7.3.4, semver@^7.3.5, semver@^7.3.7, semver@^7.3.8, semver@^7.5.3: - version "7.5.4" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" - integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== +semver@^7.0.0, semver@^7.1.1, semver@^7.3.4, semver@^7.3.5, semver@^7.3.7, semver@^7.3.8, semver@^7.5.3, semver@^7.5.4: + version "7.6.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.0.tgz#1a46a4db4bffcccd97b743b5005c8325f23d4e2d" + integrity sha512-EnwXhrlwXMk9gKu5/flx5sv/an57AkRplG3hTK68W7FRDN+k+OWBj65M7719OkA82XLBxrcX0KSHj+X5COhOVg== dependencies: lru-cache "^6.0.0" @@ -9292,15 +8622,17 @@ set-blocking@^2.0.0: resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" integrity sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw== -set-function-length@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/set-function-length/-/set-function-length-1.1.1.tgz#4bc39fafb0307224a33e106a7d35ca1218d659ed" - integrity sha512-VoaqjbBJKiWtg4yRcKBQ7g7wnGnLV3M8oLvVWwOk2PdYY6PEFegR1vezXR0tw6fZGF9csVakIRjrJiy2veSBFQ== +set-function-length@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/set-function-length/-/set-function-length-1.2.1.tgz#47cc5945f2c771e2cf261c6737cf9684a2a5e425" + integrity sha512-j4t6ccc+VsKwYHso+kElc5neZpjtq9EnRICFZtWyBsLojhmeF/ZBd/elqm22WJh/BziDe/SBiOeAt0m2mfLD0g== dependencies: - define-data-property "^1.1.1" - get-intrinsic "^1.2.1" + define-data-property "^1.1.2" + es-errors "^1.3.0" + function-bind "^1.1.2" + get-intrinsic "^1.2.3" gopd "^1.0.1" - has-property-descriptors "^1.0.0" + has-property-descriptors "^1.0.1" set-getter@^0.1.0: version "0.1.1" @@ -9316,11 +8648,6 @@ set-value@^3.0.0: dependencies: is-plain-object "^2.0.4" -setimmediate@1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/setimmediate/-/setimmediate-1.0.4.tgz#20e81de622d4a02588ce0c8da8973cbcf1d3138f" - integrity sha512-/TjEmXQVEzdod/FFskf3o7oOAsGhHf2j1dZqRFbDzq4F3mvvxflIIi4Hd3bLQE9y/CpwqfSQam5JakI/mi3Pog== - setimmediate@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/setimmediate/-/setimmediate-1.0.5.tgz#290cbb232e306942d7d7ea9b83732ab7856f8285" @@ -9385,13 +8712,14 @@ shelljs@^0.8.3: rechoir "^0.6.2" side-channel@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" - integrity sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw== + version "1.0.6" + resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.6.tgz#abd25fb7cd24baf45466406b1096b7831c9215f2" + integrity sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA== dependencies: - call-bind "^1.0.0" - get-intrinsic "^1.0.2" - object-inspect "^1.9.0" + call-bind "^1.0.7" + es-errors "^1.3.0" + get-intrinsic "^1.2.4" + object-inspect "^1.13.1" signal-exit@3.0.7, signal-exit@^3.0.2, signal-exit@^3.0.3, signal-exit@^3.0.7: version "3.0.7" @@ -9460,17 +8788,17 @@ socks-proxy-agent@^7.0.0: socks "^2.6.2" socks@^2.6.2: - version "2.7.1" - resolved "https://registry.yarnpkg.com/socks/-/socks-2.7.1.tgz#d8e651247178fde79c0663043e07240196857d55" - integrity sha512-7maUZy1N7uo6+WVEX6psASxtNlKaNVMlGQKkG/63nEDdLOWNbiUMoLK7X4uYoLhQstau72mLgfEWcXcwsaHbYQ== + version "2.8.1" + resolved "https://registry.yarnpkg.com/socks/-/socks-2.8.1.tgz#22c7d9dd7882649043cba0eafb49ae144e3457af" + integrity sha512-B6w7tkwNid7ToxjZ08rQMT8M9BJAf8DKx8Ft4NivzH0zBUfd6jldGcisJn/RLgxcX3FPNDdNQCUEMMT79b+oCQ== dependencies: - ip "^2.0.0" + ip-address "^9.0.5" smart-buffer "^4.2.0" -solady@0.0.172: - version "0.0.172" - resolved "https://registry.yarnpkg.com/solady/-/solady-0.0.172.tgz#aea9071c1ba41d805c74c9423201173b8d05246c" - integrity sha512-8YkQr78PuaGKb1jWQzVgLcCtAOYXc6Xczh/wB6YUEZO/ioidzbGYoFSmYCA1nN0Ln+K9+NZSqDhyuyv/q4N8XQ== +solady@0.0.173: + version "0.0.173" + resolved "https://registry.yarnpkg.com/solady/-/solady-0.0.173.tgz#6b51b541ca1697b5bbb0e83916852bf48dcb4c5d" + integrity sha512-6DAm9wdjN5NRQMkdy93Sh2Se7KQDX2fI9Ioj4hw0LHxAZn4vYg1sRSvodCn41RrDa1BVZWwLz0AGAG4mhzPJIQ== solc@0.7.3: version "0.7.3" @@ -9500,21 +8828,31 @@ solc@0.8.15: semver "^5.5.0" tmp "0.0.33" -solidity-comments-extractor@^0.0.7: - version "0.0.7" - resolved "https://registry.yarnpkg.com/solidity-comments-extractor/-/solidity-comments-extractor-0.0.7.tgz#99d8f1361438f84019795d928b931f4e5c39ca19" - integrity sha512-wciNMLg/Irp8OKGrh3S2tfvZiZ0NEyILfcRCXCD4mp7SgK/i9gzLfhY2hY7VMCQJ3kH9UB9BzNdibIVMchzyYw== +solc@^0.4.20: + version "0.4.26" + resolved "https://registry.yarnpkg.com/solc/-/solc-0.4.26.tgz#5390a62a99f40806b86258c737c1cf653cc35cb5" + integrity sha512-o+c6FpkiHd+HPjmjEVpQgH7fqZ14tJpXhho+/bQXlXbliLIS/xjXb42Vxh+qQY1WCSTMQ0+a5vR9vi0MfhU6mA== + dependencies: + fs-extra "^0.30.0" + memorystream "^0.3.1" + require-from-string "^1.1.0" + semver "^5.3.0" + yargs "^4.7.1" + +solidity-comments-extractor@^0.0.8: + version "0.0.8" + resolved "https://registry.yarnpkg.com/solidity-comments-extractor/-/solidity-comments-extractor-0.0.8.tgz#f6e148ab0c49f30c1abcbecb8b8df01ed8e879f8" + integrity sha512-htM7Vn6LhHreR+EglVMd2s+sZhcXAirB1Zlyrv5zBuTxieCvjfnRpd7iZk75m/u6NOlEyQ94C6TWbBn2cY7w8g== solidity-coverage@^0.8.5: - version "0.8.5" - resolved "https://registry.yarnpkg.com/solidity-coverage/-/solidity-coverage-0.8.5.tgz#64071c3a0c06a0cecf9a7776c35f49edc961e875" - integrity sha512-6C6N6OV2O8FQA0FWA95FdzVH+L16HU94iFgg5wAFZ29UpLFkgNI/DRR2HotG1bC0F4gAc/OMs2BJI44Q/DYlKQ== + version "0.8.10" + resolved "https://registry.yarnpkg.com/solidity-coverage/-/solidity-coverage-0.8.10.tgz#8985f9f80a34432daf397fc13d994e689f3df92d" + integrity sha512-6nvlWLnCjBIVnCgTZiIo2XBI62O3YJuU83xj+bklnH/B+dXGTjuQB7SccZfysUC3LFkjtZO/KjzUJ/hiSlkXWw== dependencies: "@ethersproject/abi" "^5.0.9" - "@solidity-parser/parser" "^0.16.0" + "@solidity-parser/parser" "^0.18.0" chalk "^2.4.2" death "^1.1.0" - detect-port "^1.3.0" difflib "^0.2.4" fs-extra "^8.1.0" ghost-testrpc "^0.0.2" @@ -9522,7 +8860,7 @@ solidity-coverage@^0.8.5: globby "^10.0.1" jsonschema "^1.2.4" lodash "^4.17.15" - mocha "10.2.0" + mocha "^10.2.0" node-emoji "^1.10.0" pify "^4.0.1" recursive-readdir "^2.2.2" @@ -9567,9 +8905,9 @@ spdx-correct@^3.0.0: spdx-license-ids "^3.0.0" spdx-exceptions@^2.1.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz#3f28ce1a77a00372683eade4a433183527a2163d" - integrity sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A== + version "2.5.0" + resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.5.0.tgz#5d607d27fc806f66d7b64a766650fa890f04ed66" + integrity sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w== spdx-expression-parse@^3.0.0: version "3.0.1" @@ -9580,9 +8918,9 @@ spdx-expression-parse@^3.0.0: spdx-license-ids "^3.0.0" spdx-license-ids@^3.0.0: - version "3.0.13" - resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.13.tgz#7189a474c46f8d47c7b0da4b987bb45e908bd2d5" - integrity sha512-XkD+zwiqXHikFZm4AX/7JSCXA98U5Db4AFd5XUg/+9UNtnH75+Z9KxtpYiJZx36mUDVOwH83pl7yvCer6ewM3w== + version "3.0.17" + resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.17.tgz#887da8aa73218e51a1d917502d79863161a93f9c" + integrity sha512-sh8PWc/ftMqAAdFiBu6Fy6JUOYjqDJBJvIhpfDMyHrr0Rbp5liZqd4TjtQ/RgfLjKFZb+LMx5hpml5qOWy0qvg== split2@^3.2.2: version "3.2.2" @@ -9598,15 +8936,20 @@ split@^1.0.1: dependencies: through "2" +sprintf-js@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.1.3.tgz#4914b903a2f8b685d17fdf78a70e917e872e444a" + integrity sha512-Oo+0REFV59/rz3gfJNKQiBlwfHaSESl1pcGyABQsnnIfWOFt6JNj5gCog2U6MLZ//IGYD+nA8nI+mTShREReaA== + sprintf-js@~1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" integrity sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g== sshpk@^1.7.0: - version "1.17.0" - resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.17.0.tgz#578082d92d4fe612b13007496e543fa0fbcbe4c5" - integrity sha512-/9HIEs1ZXGhSPE8X6Ccm7Nam1z8KcoCqPdI7ecm1N33EzAetWahvQWVqLZtaZQ+IDKX4IyA2o0gBzqIMkAagHQ== + version "1.18.0" + resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.18.0.tgz#1663e55cddf4d688b86a46b77f0d5fe363aba028" + integrity sha512-2p2KJZTSqQ/I3+HX42EpYOa2l3f8Erv8MWKsy2I9uf4wA7yFIkXRffYdsx86y6z4vHtV8u7g+pPlr8/4ouAxsQ== dependencies: asn1 "~0.2.3" assert-plus "^1.0.0" @@ -9619,11 +8962,11 @@ sshpk@^1.7.0: tweetnacl "~0.14.0" ssri@^10.0.0, ssri@^10.0.1: - version "10.0.3" - resolved "https://registry.yarnpkg.com/ssri/-/ssri-10.0.3.tgz#7f83da39058ca1d599d174e9eee4237659710bf4" - integrity sha512-lJtX/BFPI/VEtxZmLfeh7pzisIs6micwZ3eruD3+ds9aPsXKlYpwDS2Q7omD6WC42WO9+bnUSzlMmfv8uK8meg== + version "10.0.5" + resolved "https://registry.yarnpkg.com/ssri/-/ssri-10.0.5.tgz#e49efcd6e36385196cb515d3a2ad6c3f0265ef8c" + integrity sha512-bSf16tAFkGeRlUNDjXu8FzaMQt6g2HZJrun7mtMbIPOddxt3GLMSz5VWUWcqTJUPfLEaDIepGxv+bYQW49596A== dependencies: - minipass "^4.0.0" + minipass "^7.0.3" ssri@^9.0.0, ssri@^9.0.1: version "9.0.1" @@ -9660,17 +9003,12 @@ stdout-stderr@^0.1.9: debug "^4.1.1" strip-ansi "^6.0.0" -stealthy-require@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/stealthy-require/-/stealthy-require-1.1.1.tgz#35b09875b4ff49f26a777e509b3090a3226bf24b" - integrity sha512-ZnWpYnYugiOVEY5GkcuJK1io5V8QmNYChG62gSit9pQVGErXtrKuPC55ITaVSukmMta5qpMU7vqLt2Lnni4f/g== - string-format@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/string-format/-/string-format-2.0.0.tgz#f2df2e7097440d3b65de31b6d40d54c96eaffb9b" integrity sha512-bbEs3scLeYNXLecRRuk6uJxdXUSj6le/8rNPHChIJTn2V79aXVTR1EH2OH5zLKKoz0V02fOUKZZcw01pLUShZA== -"string-width-cjs@npm:string-width@^4.2.0", "string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: +"string-width-cjs@npm:string-width@^4.2.0", "string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.0.0, string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.2, string-width@^4.2.3: version "4.2.3" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -9679,7 +9017,16 @@ string-format@^2.0.0: is-fullwidth-code-point "^3.0.0" strip-ansi "^6.0.1" -"string-width@^1.0.2 || 2", string-width@^2.0.0, string-width@^2.1.1: +string-width@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" + integrity sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw== + dependencies: + code-point-at "^1.0.0" + is-fullwidth-code-point "^1.0.0" + strip-ansi "^3.0.0" + +string-width@^2.0.0, string-width@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== @@ -9687,15 +9034,6 @@ string-format@^2.0.0: is-fullwidth-code-point "^2.0.0" strip-ansi "^4.0.0" -string-width@^3.0.0, string-width@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" - integrity sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w== - dependencies: - emoji-regex "^7.0.1" - is-fullwidth-code-point "^2.0.0" - strip-ansi "^5.1.0" - string-width@^5.0.1, string-width@^5.1.2: version "5.1.2" resolved "https://registry.yarnpkg.com/string-width/-/string-width-5.1.2.tgz#14f8daec6d81e7221d2a357e668cab73bdbca794" @@ -9705,33 +9043,6 @@ string-width@^5.0.1, string-width@^5.1.2: emoji-regex "^9.2.2" strip-ansi "^7.0.1" -string.prototype.trim@^1.2.7: - version "1.2.7" - resolved "https://registry.yarnpkg.com/string.prototype.trim/-/string.prototype.trim-1.2.7.tgz#a68352740859f6893f14ce3ef1bb3037f7a90533" - integrity sha512-p6TmeT1T3411M8Cgg9wBTMRtY2q9+PNy9EV1i2lIXUN/btt763oIfxwN3RR8VU6wHX8j/1CFy0L+YuThm6bgOg== - dependencies: - call-bind "^1.0.2" - define-properties "^1.1.4" - es-abstract "^1.20.4" - -string.prototype.trimend@^1.0.6: - version "1.0.6" - resolved "https://registry.yarnpkg.com/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz#c4a27fa026d979d79c04f17397f250a462944533" - integrity sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ== - dependencies: - call-bind "^1.0.2" - define-properties "^1.1.4" - es-abstract "^1.20.4" - -string.prototype.trimstart@^1.0.6: - version "1.0.6" - resolved "https://registry.yarnpkg.com/string.prototype.trimstart/-/string.prototype.trimstart-1.0.6.tgz#e90ab66aa8e4007d92ef591bbf3cd422c56bdcf4" - integrity sha512-omqjMDaY92pbn5HOX7f9IccLA+U1tA9GvtU4JrodiXFfYB7jPzzHpRzpglLAjtUV6bB557zwClJezTqnAiYnQA== - dependencies: - call-bind "^1.0.2" - define-properties "^1.1.4" - es-abstract "^1.20.4" - string_decoder@^1.1.1: version "1.3.0" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.3.0.tgz#42f114594a46cf1a8e30b0a84f56c78c3edac21e" @@ -9753,6 +9064,13 @@ string_decoder@~1.1.1: dependencies: ansi-regex "^5.0.1" +strip-ansi@^3.0.0, strip-ansi@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" + integrity sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg== + dependencies: + ansi-regex "^2.0.0" + strip-ansi@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-4.0.0.tgz#a8479022eb1ac368a871389b635262c505ee368f" @@ -9760,13 +9078,6 @@ strip-ansi@^4.0.0: dependencies: ansi-regex "^3.0.0" -strip-ansi@^5.0.0, strip-ansi@^5.1.0, strip-ansi@^5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-5.2.0.tgz#8c9a536feb6afc962bdfa5b104a5091c1ad9c0ae" - integrity sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA== - dependencies: - ansi-regex "^4.1.0" - strip-ansi@^7.0.1: version "7.1.0" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-7.1.0.tgz#d5b6568ca689d8561370b0707685d22434faff45" @@ -9774,6 +9085,13 @@ strip-ansi@^7.0.1: dependencies: ansi-regex "^6.0.1" +strip-bom@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" + integrity sha512-kwrX1y7czp1E69n2ajbG65mIo9dqvJ+8aBQXOGVxqwvNbsXdFM6Lq37dLAY3mknUwru8CfcCbfOLL/gMo+fi3g== + dependencies: + is-utf8 "^0.2.0" + strip-bom@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-3.0.0.tgz#2334c18e9c759f7bdd56fdef7e9ae3d588e68ed3" @@ -9808,12 +9126,7 @@ strip-indent@^3.0.0: dependencies: min-indent "^1.0.0" -strip-json-comments@2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" - integrity sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ== - -strip-json-comments@3.1.1, strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: +strip-json-comments@3.1.1, strip-json-comments@^3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== @@ -9832,13 +9145,6 @@ success-symbol@^0.1.0: resolved "https://registry.yarnpkg.com/success-symbol/-/success-symbol-0.1.0.tgz#24022e486f3bf1cdca094283b769c472d3b72897" integrity sha512-7S6uOTxPklNGxOSbDIg4KlVLBQw1UiGVyfCUYgYxrZUKRblUkmGj7r8xlfQoFudvqLv6Ap5gd76/IIFfI9JG2A== -supports-color@6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-6.0.0.tgz#76cfe742cf1f41bb9b1c29ad03068c05b4c0e40a" - integrity sha512-on9Kwidc1IUQo+bQdhi8+Tijpo0e1SS6RoGo2guUwn5vdaxw8RXOF9Vb2ws+ihWOmh4JnCJOvaziZWP1VABaLg== - dependencies: - has-flag "^3.0.0" - supports-color@8.1.1: version "8.1.1" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-8.1.1.tgz#cd6fc17e28500cff56c1b86c0a7fd4a54a73005c" @@ -9933,13 +9239,13 @@ tar@6.1.11: yallist "^4.0.0" tar@^6.1.11, tar@^6.1.2: - version "6.1.13" - resolved "https://registry.yarnpkg.com/tar/-/tar-6.1.13.tgz#46e22529000f612180601a6fe0680e7da508847b" - integrity sha512-jdIBIN6LTIe2jqzay/2vtYLlBHa3JF42ot3h1dW8Q0PaAG4v8rm0cvpVePtau5C6OKXGGcgO9q2AMNSWxiLqKw== + version "6.2.0" + resolved "https://registry.yarnpkg.com/tar/-/tar-6.2.0.tgz#b14ce49a79cb1cd23bc9b016302dea5474493f73" + integrity sha512-/Wo7DcT0u5HUV486xg675HtjNd3BXZ6xDbzsCUZPt5iw8bTQ63bP0Raut3mvro9u+CUyq7YQd8Cx55fsZXxqLQ== dependencies: chownr "^2.0.0" fs-minipass "^2.0.0" - minipass "^4.0.0" + minipass "^5.0.0" minizlib "^2.1.1" mkdirp "^1.0.3" yallist "^4.0.0" @@ -9958,6 +9264,11 @@ terminal-paginator@^2.0.2: extend-shallow "^2.0.1" log-utils "^0.2.1" +testrpc@0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/testrpc/-/testrpc-0.0.1.tgz#83e2195b1f5873aec7be1af8cbe6dcf39edb7aed" + integrity sha512-afH1hO+SQ/VPlmaLUFj2636QMeDvPCeQMc/9RBMW0IfjNe9gFD9Ra3ShqYkB7py0do1ZcCna/9acHyzTJ+GcNA== + text-extensions@^1.0.0: version "1.9.0" resolved "https://registry.yarnpkg.com/text-extensions/-/text-extensions-1.9.0.tgz#1853e45fee39c945ce6f6c36b2d659b5aabc2a26" @@ -10016,11 +9327,9 @@ tmp@0.0.33, tmp@^0.0.33: os-tmpdir "~1.0.2" tmp@~0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.2.1.tgz#8457fc3037dcf4719c251367a1af6500ee1ccf14" - integrity sha512-76SUhtfqR2Ijn+xllcI5P1oyannHNHByD80W1q447gU3mp9G9PSpGdWmjUOHRDPiHYacIk66W7ubDTuPF3BEtQ== - dependencies: - rimraf "^3.0.0" + version "0.2.3" + resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.2.3.tgz#eb783cc22bc1e8bebd0671476d46ea4eb32a79ae" + integrity sha512-nZD7m9iCPC5g0pYmcaxogYKggSfLsdxl8of3Q/oIbqCqLLIO9IAF0GWjX1z9NZRHPiXv8Wex4yDCaZsgEw0Y8w== to-object-path@^0.3.0: version "0.3.0" @@ -10048,7 +9357,7 @@ toidentifier@1.0.1: resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.1.tgz#3be34321a88a820ed1bd80dfaa33e479fbb8dd35" integrity sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA== -tough-cookie@^2.3.3, tough-cookie@~2.5.0: +tough-cookie@~2.5.0: version "2.5.0" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.5.0.tgz#cd9fb2a0aa1d5a12b473bd9fb96fa3dcff65ade2" integrity sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g== @@ -10066,12 +9375,16 @@ trim-newlines@^3.0.0: resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-3.0.1.tgz#260a5d962d8b752425b32f3a7db0dcacd176c144" integrity sha512-c1PTsA3tYrIsLGkJkzHF+w9F2EyxfXGo4UyJc4pFL++FMjnq0HJS69T3M7d//gKrFKwy429bouPescbjecU+Zw== +ts-api-utils@^1.0.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/ts-api-utils/-/ts-api-utils-1.2.1.tgz#f716c7e027494629485b21c0df6180f4d08f5e8b" + integrity sha512-RIYA36cJn2WiH9Hy77hdF9r7oEwxAtB/TS9/S4Qd90Ap4z5FSiin5zEiTL44OII1Y3IIlEvxwxFUVgrHSZ/UpA== + ts-command-line-args@^2.2.0: - version "2.5.0" - resolved "https://registry.yarnpkg.com/ts-command-line-args/-/ts-command-line-args-2.5.0.tgz#7eeed3a6937b2612ea08a0794cf9d43fbbea89c4" - integrity sha512-Ff7Xt04WWCjj/cmPO9eWTJX3qpBZWuPWyQYG1vnxJao+alWWYjwJBc5aYz3h5p5dE08A6AnpkgiCtP/0KXXBYw== + version "2.5.1" + resolved "https://registry.yarnpkg.com/ts-command-line-args/-/ts-command-line-args-2.5.1.tgz#e64456b580d1d4f6d948824c274cf6fa5f45f7f0" + integrity sha512-H69ZwTw3rFHb5WYpQya40YAX2/w7Ut75uUECbgBIsLmM+BNuYnxsltfyyLMxy6sEeKxgijLTnQtLd0nKd6+IYw== dependencies: - "@morgan-stanley/ts-mocking-bird" "^0.6.2" chalk "^4.1.0" command-line-args "^5.1.1" command-line-usage "^6.1.0" @@ -10083,9 +9396,9 @@ ts-essentials@^7.0.1: integrity sha512-8+gr5+lqO3G84KdiTSMRLtuyJ+nTBVRKuCrK4lidMPdVeEp0uqC875uE5NMcaA7YYMN7XsNiFQuMvasF8HT/xQ== ts-node@^10.9.1: - version "10.9.1" - resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-10.9.1.tgz#e73de9102958af9e1f0b168a6ff320e25adcff4b" - integrity sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw== + version "10.9.2" + resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-10.9.2.tgz#70f021c9e185bccdca820e26dc413805c101c71f" + integrity sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ== dependencies: "@cspotcode/source-map-support" "^0.8.0" "@tsconfig/node10" "^1.0.7" @@ -10110,28 +9423,21 @@ tsconfig-paths@^4.1.2: minimist "^1.2.6" strip-bom "^3.0.0" -tslib@^1.8.1, tslib@^1.9.3: +tslib@^1.9.3: version "1.14.1" resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== tslib@^2.1.0, tslib@^2.3.0, tslib@^2.4.0: - version "2.5.0" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.5.0.tgz#42bfed86f5787aeb41d031866c8f402429e0fddf" - integrity sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg== + version "2.6.2" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.2.tgz#703ac29425e7b37cd6fd456e92404d46d1f3e4ae" + integrity sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q== tsort@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/tsort/-/tsort-0.0.1.tgz#e2280f5e817f8bf4275657fd0f9aebd44f5a2786" integrity sha512-Tyrf5mxF8Ofs1tNoxA13lFeZ2Zrbd6cKbuH3V+MQ5sb6DtBj5FjrXVsRWT8YvNAQTqNoz66dz1WsbigI22aEnw== -tsutils@^3.21.0: - version "3.21.0" - resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-3.21.0.tgz#b48717d394cea6c1e096983eed58e9d61715b623" - integrity sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA== - dependencies: - tslib "^1.8.1" - tuf-js@^1.1.7: version "1.1.7" resolved "https://registry.yarnpkg.com/tuf-js/-/tuf-js-1.1.7.tgz#21b7ae92a9373015be77dfe0cb282a80ec3bbe43" @@ -10177,7 +9483,7 @@ type-check@~0.3.2: dependencies: prelude-ls "~1.1.2" -type-detect@4.0.8, type-detect@^4.0.0, type-detect@^4.0.5, type-detect@^4.0.8: +type-detect@4.0.8, type-detect@^4.0.0, type-detect@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== @@ -10235,26 +9541,10 @@ type@^2.7.2: resolved "https://registry.yarnpkg.com/type/-/type-2.7.2.tgz#2376a15a3a28b1efa0f5350dcf72d24df6ef98d0" integrity sha512-dzlvlNlt6AXU7EBSfpAscydQ7gXB+pPGsPnfJnZpiNJBDj7IaJzQlBZYGdEi4R9HmPdBv2XmWJ6YUtoTa7lmCw== -typechain@^8.0.0: - version "8.3.1" - resolved "https://registry.yarnpkg.com/typechain/-/typechain-8.3.1.tgz#dccbc839b94877997536c356380eff7325395cfb" - integrity sha512-fA7clol2IP/56yq6vkMTR+4URF1nGjV82Wx6Rf09EsqD4tkzMAvEaqYxVFCavJm/1xaRga/oD55K+4FtuXwQOQ== - dependencies: - "@types/prettier" "^2.1.1" - debug "^4.3.1" - fs-extra "^7.0.0" - glob "7.1.7" - js-sha3 "^0.8.0" - lodash "^4.17.15" - mkdirp "^1.0.4" - prettier "^2.3.1" - ts-command-line-args "^2.2.0" - ts-essentials "^7.0.1" - -typechain@^8.1.1: - version "8.1.1" - resolved "https://registry.yarnpkg.com/typechain/-/typechain-8.1.1.tgz#9c2e8012c2c4c586536fc18402dcd7034c4ff0bd" - integrity sha512-uF/sUvnXTOVF2FHKhQYnxHk4su4JjZR8vr4mA2mBaRwHTbwh0jIlqARz9XJr1tA0l7afJGvEa1dTSi4zt039LQ== +typechain@^8.0.0, typechain@^8.1.1: + version "8.3.2" + resolved "https://registry.yarnpkg.com/typechain/-/typechain-8.3.2.tgz#1090dd8d9c57b6ef2aed3640a516bdbf01b00d73" + integrity sha512-x/sQYr5w9K7yv3es7jo4KTX05CLxOf7TRWwoHlrjRh8H82G64g+k7VuWPJlgMo6qrjfCulOdfBjiaDtmhFYD/Q== dependencies: "@types/prettier" "^2.1.1" debug "^4.3.1" @@ -10267,15 +9557,6 @@ typechain@^8.1.1: ts-command-line-args "^2.2.0" ts-essentials "^7.0.1" -typed-array-length@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/typed-array-length/-/typed-array-length-1.0.4.tgz#89d83785e5c4098bec72e08b319651f0eac9c1bb" - integrity sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng== - dependencies: - call-bind "^1.0.2" - for-each "^0.3.3" - is-typed-array "^1.1.9" - typedarray-to-buffer@^3.1.5: version "3.1.5" resolved "https://registry.yarnpkg.com/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz#a97ee7a9ff42691b9f783ff1bc5112fe3fca9080" @@ -10288,15 +9569,10 @@ typedarray@^0.0.6: resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" integrity sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA== -"typescript@>=3 < 6": - version "5.2.2" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.2.2.tgz#5ebb5e5a5b75f085f22bc3f8460fba308310fa78" - integrity sha512-mI4WrpHsbCIcwT9cF4FZvr80QUeKvsUsUvKDoR+X/7XHQH98xYD8YHZg7ANtz2GtZt/CBq2QJ0thkGJMHfqc1w== - -typescript@^5.0.4: - version "5.0.4" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.0.4.tgz#b217fd20119bd61a94d4011274e0ab369058da3b" - integrity sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw== +"typescript@>=3 < 6", typescript@^5.0.4: + version "5.3.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.3.3.tgz#b3ce6ba258e72e6305ba66f5c9b452aaee3ffe37" + integrity sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw== typical@^4.0.0: version "4.0.0" @@ -10313,16 +9589,6 @@ uglify-js@^3.1.4: resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.17.4.tgz#61678cf5fa3f5b7eb789bb345df29afb8257c22c" integrity sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g== -unbox-primitive@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/unbox-primitive/-/unbox-primitive-1.0.2.tgz#29032021057d5e6cdbd08c5129c226dff8ed6f9e" - integrity sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw== - dependencies: - call-bind "^1.0.2" - has-bigints "^1.0.2" - has-symbols "^1.0.3" - which-boxed-primitive "^1.0.2" - undici-types@~5.26.4: version "5.26.5" resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-5.26.5.tgz#bcd539893d00b56e964fd2657a4866b221a65617" @@ -10364,9 +9630,9 @@ unique-slug@^4.0.0: imurmurhash "^0.1.4" universal-user-agent@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/universal-user-agent/-/universal-user-agent-6.0.0.tgz#3381f8503b251c0d9cd21bc1de939ec9df5480ee" - integrity sha512-isyNax3wXoKaulPDZWHQqbmIx1k2tb9fb3GGDBRxCscfYV2Ch7WxPArBsFEG8s/safwXTT7H4QGhaIkTp9447w== + version "6.0.1" + resolved "https://registry.yarnpkg.com/universal-user-agent/-/universal-user-agent-6.0.1.tgz#15f20f55da3c930c57bddbf1734c6654d5fd35aa" + integrity sha512-yCzhz6FN2wU1NiiQRogkTQszlQSlpWaw8SvVegAc+bDxbzHgh1vX8uIe8OYyMH6DwH+sdTJsgMl36+mSMdRJIQ== universalify@^0.1.0: version "0.1.2" @@ -10374,9 +9640,9 @@ universalify@^0.1.0: integrity sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg== universalify@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/universalify/-/universalify-2.0.0.tgz#75a4984efedc4b08975c5aeb73f530d02df25717" - integrity sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ== + version "2.0.1" + resolved "https://registry.yarnpkg.com/universalify/-/universalify-2.0.1.tgz#168efc2180964e6386d061e094df61afe239b18d" + integrity sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw== unpipe@1.0.0, unpipe@~1.0.0: version "1.0.0" @@ -10396,12 +9662,12 @@ uri-js@^4.2.2: punycode "^2.1.0" url@^0.11.0: - version "0.11.0" - resolved "https://registry.yarnpkg.com/url/-/url-0.11.0.tgz#3838e97cfc60521eb73c525a8e55bfdd9e2e28f1" - integrity sha512-kbailJa29QrtXnxgq+DdCEGlbTeYM2eJUxsz6vjZavrCYPMIFHMKQmSKYAIuUK2i7hgPm28a8piX5NTUtM/LKQ== + version "0.11.3" + resolved "https://registry.yarnpkg.com/url/-/url-0.11.3.tgz#6f495f4b935de40ce4a0a52faee8954244f3d3ad" + integrity sha512-6hxOLGfZASQK/cijlZnZJTq8OXAkt/3YGfQX45vvMYXpZoo8NdWZcY73K108Jf759lS1Bv/8wXnHDTSz17dSRw== dependencies: - punycode "1.3.2" - querystring "0.2.0" + punycode "^1.4.1" + qs "^6.11.2" utf-8-validate@5.0.7: version "5.0.7" @@ -10432,21 +9698,11 @@ utils-merge@1.0.1: resolved "https://registry.yarnpkg.com/utils-merge/-/utils-merge-1.0.1.tgz#9f95710f50a267947b2ccc124741c1028427e713" integrity sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA== -uuid@2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-2.0.1.tgz#c2a30dedb3e535d72ccf82e343941a50ba8533ac" - integrity sha512-nWg9+Oa3qD2CQzHIP4qKUqwNfzKn8P0LtFhotaCTFchsV7ZfDhAybeip/HZVeMIpZi9JgY1E3nUlwaCmZT1sEg== - uuid@^3.3.2: version "3.4.0" resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee" integrity sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A== -uuid@^7.0.3: - version "7.0.3" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-7.0.3.tgz#c5c9f2c8cf25dc0a372c4df1441c41f5bd0c680b" - integrity sha512-DPSke0pXhTZgoF/d+WSt2QaKMCFSfx7QegxEWT+JOuHF5aWrKEn0G+ztjuJg/gG8/ItK+rbPCD/yNv8yyih6Cg== - uuid@^8.3.2: version "8.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" @@ -10520,10 +9776,10 @@ wcwidth@^1.0.0, wcwidth@^1.0.1: dependencies: defaults "^1.0.3" -web3-utils@^1.3.1: - version "1.10.3" - resolved "https://registry.yarnpkg.com/web3-utils/-/web3-utils-1.10.3.tgz#f1db99c82549c7d9f8348f04ffe4e0188b449714" - integrity sha512-OqcUrEE16fDBbGoQtZXWdavsPzbGIDc5v3VrRTZ0XrIpefC/viZ1ZU9bGEemazyS0catk/3rkOOxpzTfY+XsyQ== +web3-utils@^1.0.0-beta.31, web3-utils@^1.3.1, web3-utils@^1.3.6: + version "1.10.4" + resolved "https://registry.yarnpkg.com/web3-utils/-/web3-utils-1.10.4.tgz#0daee7d6841641655d8b3726baf33b08eda1cbec" + integrity sha512-tsu8FiKJLk2PzhDl9fXbGUWTkkVXYhtTA+SmEFkKft+9BgwLxfCRpU96sWv7ICC8zixBNd3JURVoiR3dUXgP8A== dependencies: "@ethereumjs/util" "^8.1.0" bn.js "^5.2.1" @@ -10534,19 +9790,6 @@ web3-utils@^1.3.1: randombytes "^2.1.0" utf8 "3.0.0" -web3-utils@^1.3.6: - version "1.9.0" - resolved "https://registry.yarnpkg.com/web3-utils/-/web3-utils-1.9.0.tgz#7c5775a47586cefb4ad488831be8f6627be9283d" - integrity sha512-p++69rCNNfu2jM9n5+VD/g26l+qkEOQ1m6cfRQCbH8ZRrtquTmrirJMgTmyOoax5a5XRYOuws14aypCOs51pdQ== - dependencies: - bn.js "^5.2.1" - ethereum-bloom-filters "^1.0.6" - ethereumjs-util "^7.1.0" - ethjs-unit "0.1.6" - number-to-bn "1.7.0" - randombytes "^2.1.0" - utf8 "3.0.0" - webidl-conversions@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" @@ -10572,35 +9815,12 @@ whatwg-url@^5.0.0: tr46 "~0.0.3" webidl-conversions "^3.0.0" -which-boxed-primitive@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz#13757bc89b209b049fe5d86430e21cf40a89a8e6" - integrity sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg== - dependencies: - is-bigint "^1.0.1" - is-boolean-object "^1.1.0" - is-number-object "^1.0.4" - is-string "^1.0.5" - is-symbol "^1.0.3" - -which-module@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.0.tgz#d9ef07dce77b9902b8a3a8fa4b31c3e3f7e6e87a" - integrity sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q== - -which-typed-array@^1.1.9: - version "1.1.9" - resolved "https://registry.yarnpkg.com/which-typed-array/-/which-typed-array-1.1.9.tgz#307cf898025848cf995e795e8423c7f337efbde6" - integrity sha512-w9c4xkx6mPidwp7180ckYWfMmvxpjlZuIudNtDf4N/tTAUB8VJbX25qZoAsrtGuYNnGw3pa0AXgbGKRB8/EceA== - dependencies: - available-typed-arrays "^1.0.5" - call-bind "^1.0.2" - for-each "^0.3.3" - gopd "^1.0.1" - has-tostringtag "^1.0.0" - is-typed-array "^1.1.10" +which-module@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/which-module/-/which-module-1.0.0.tgz#bba63ca861948994ff307736089e3b96026c2a4f" + integrity sha512-F6+WgncZi/mJDrammbTuHe1q0R5hOXv/mBaiNA2TCNT/LTHusX0V+CJnj9XT8ki5ln2UZyyddDgHfCzyrOH7MQ== -which@1.3.1, which@^1.1.1, which@^1.3.1: +which@^1.1.1, which@^1.3.1: version "1.3.1" resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== @@ -10615,19 +9835,12 @@ which@^2.0.1, which@^2.0.2: isexe "^2.0.0" which@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/which/-/which-3.0.0.tgz#a9efd016db59728758a390d23f1687b6e8f59f8e" - integrity sha512-nla//68K9NU6yRiwDY/Q8aU6siKlSs64aEC7+IV56QoAuyQT2ovsJcgGYGyqMOmI/CGN1BOR6mM5EN0FBO+zyQ== + version "3.0.1" + resolved "https://registry.yarnpkg.com/which/-/which-3.0.1.tgz#89f1cd0c23f629a8105ffe69b8172791c87b4be1" + integrity sha512-XA1b62dzQzLfaEOSQFTCOd5KFf/1VSzZo7/7TUjnya6u0vGGKzU96UQBZTAThCb2j4/xjBAyii1OhRLJEivHvg== dependencies: isexe "^2.0.0" -wide-align@1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.3.tgz#ae074e6bdc0c14a431e804e624549c633b000457" - integrity sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA== - dependencies: - string-width "^1.0.2 || 2" - wide-align@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.5.tgz#df1d4c206854369ecf3c9a4898f1b23fbd9d15d3" @@ -10635,6 +9848,18 @@ wide-align@^1.1.5: dependencies: string-width "^1.0.2 || 2 || 3 || 4" +widest-line@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/widest-line/-/widest-line-3.1.0.tgz#8292333bbf66cb45ff0de1603b136b7ae1496eca" + integrity sha512-NsmoXalsWVDMGupxZ5R08ka9flZjjiLvHVAWYOKtiKM8ujtZWr9cRffak+uSE48+Ob8ObalXpwyeUiyDD6QFgg== + dependencies: + string-width "^4.0.0" + +window-size@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/window-size/-/window-size-0.2.0.tgz#b4315bb4214a3d7058ebeee892e13fa24d98b075" + integrity sha512-UD7d8HFA2+PZsbKyaOCEy8gMh1oDtHgJh1LfgjQ4zVXmYjAT/kvz3PueITKuqDiIXQe7yzpPnxX3lNc+AhQMyw== + window-size@^1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/window-size/-/window-size-1.1.1.tgz#9858586580ada78ab26ecd6978a6e03115c1af20" @@ -10643,10 +9868,10 @@ window-size@^1.1.0: define-property "^1.0.0" is-number "^3.0.0" -word-wrap@^1.2.3, word-wrap@~1.2.3: - version "1.2.4" - resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.4.tgz#cb4b50ec9aca570abd1f52f33cd45b6c61739a9f" - integrity sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA== +word-wrap@~1.2.3: + version "1.2.5" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.5.tgz#d2c45c6dd4fbce621a66f136cbe328afd0410b34" + integrity sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA== wordwrap@^1.0.0: version "1.0.0" @@ -10675,14 +9900,22 @@ workerpool@6.2.1: string-width "^4.1.0" strip-ansi "^6.0.0" -wrap-ansi@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-5.1.0.tgz#1fd1f67235d5b6d0fee781056001bfb694c03b09" - integrity sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q== +wrap-ansi@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" + integrity sha512-vAaEaDM946gbNpH5pLVNR+vX2ht6n0Bt3GXwVB1AuAqZosOvHNF3P7wDnh8KLkSqgUh0uh77le7Owgoz+Z9XBw== dependencies: - ansi-styles "^3.2.0" - string-width "^3.0.0" - strip-ansi "^5.0.0" + string-width "^1.0.1" + strip-ansi "^3.0.1" + +wrap-ansi@^6.0.1: + version "6.2.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-6.2.0.tgz#e9393ba07102e6c91a3b221478f0257cd2856e53" + integrity sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" wrap-ansi@^8.1.0: version "8.1.0" @@ -10746,25 +9979,20 @@ ws@^7.4.1, ws@^7.4.5, ws@^7.4.6: resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.9.tgz#54fa7db29f4c7cec68b1ddd3a89de099942bb591" integrity sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q== -ws@^8.13.0: - version "8.13.0" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.13.0.tgz#9a9fb92f93cf41512a0735c8f4dd09b8a1211cd0" - integrity sha512-x9vcZYTrFPC7aSIbj7sRCYo7L/Xb8Iy+pW0ng0wt2vCJv7M9HOMy0UoN3rr+IFC7hb7vXoqS+P9ktyLLLhO+LA== - -xmlhttprequest@1.8.0: - version "1.8.0" - resolved "https://registry.yarnpkg.com/xmlhttprequest/-/xmlhttprequest-1.8.0.tgz#67fe075c5c24fef39f9d65f5f7b7fe75171968fc" - integrity sha512-58Im/U0mlVBLM38NdZjHyhuMtCqa61469k2YP/AaPbvCoV9aQGUpbJBj1QRm2ytRiVQBD/fsw7L2bJGDVQswBA== +ws@^8.16.0: + version "8.16.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.16.0.tgz#d1cd774f36fbc07165066a60e40323eab6446fd4" + integrity sha512-HS0c//TP7Ina87TfiPUz1rQzMhHrl/SG2guqRcTOIUYD2q8uhUdNHZYJUaQ8aTGPzCh+c6oawMKW35nFl1dxyQ== xtend@^4.0.1, xtend@^4.0.2, xtend@~4.0.0, xtend@~4.0.1: version "4.0.2" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== -y18n@^4.0.0: - version "4.0.3" - resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.3.tgz#b5f259c82cd6e336921efd7bfd8bf560de9eeedf" - integrity sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ== +y18n@^3.2.1: + version "3.2.2" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.2.tgz#85c901bd6470ce71fc4bb723ad209b70f7f28696" + integrity sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ== y18n@^5.0.5: version "5.0.8" @@ -10786,14 +10014,6 @@ yallist@^3.0.2: resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd" integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g== -yargs-parser@13.1.2, yargs-parser@^13.1.2: - version "13.1.2" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.2.tgz#130f09702ebaeef2650d54ce6e3e5706f7a4fb38" - integrity sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg== - dependencies: - camelcase "^5.0.0" - decamelize "^1.2.0" - yargs-parser@20.2.4: version "20.2.4" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.4.tgz#b42890f14566796f85ae8e3a25290d205f154a54" @@ -10804,20 +10024,19 @@ yargs-parser@21.1.1, yargs-parser@^21.1.1: resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" integrity sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw== +yargs-parser@^2.4.1: + version "2.4.1" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-2.4.1.tgz#85568de3cf150ff49fa51825f03a8c880ddcc5c4" + integrity sha512-9pIKIJhnI5tonzG6OnCFlz/yln8xHYcGl+pn3xR0Vzff0vzN1PbNRaelgfgRUwZ3s4i3jvxT9WhmUGL4whnasA== + dependencies: + camelcase "^3.0.0" + lodash.assign "^4.0.6" + yargs-parser@^20.2.2, yargs-parser@^20.2.3: version "20.2.9" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.9.tgz#2eb7dc3b0289718fc295f362753845c41a0c94ee" integrity sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w== -yargs-unparser@1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/yargs-unparser/-/yargs-unparser-1.6.0.tgz#ef25c2c769ff6bd09e4b0f9d7c605fb27846ea9f" - integrity sha512-W9tKgmSn0DpSatfri0nx52Joq5hVXgeLiqR/5G0sZNDoLZFOr/xjBUDcShCOGNsBnEMNo1KAMBkTej1Hm62HTw== - dependencies: - flat "^4.1.0" - lodash "^4.17.15" - yargs "^13.3.0" - yargs-unparser@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/yargs-unparser/-/yargs-unparser-2.0.0.tgz#f131f9226911ae5d9ad38c432fe809366c2325eb" @@ -10828,22 +10047,6 @@ yargs-unparser@2.0.0: flat "^5.0.2" is-plain-obj "^2.1.0" -yargs@13.3.2, yargs@^13.3.0: - version "13.3.2" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-13.3.2.tgz#ad7ffefec1aa59565ac915f82dccb38a9c31a2dd" - integrity sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw== - dependencies: - cliui "^5.0.0" - find-up "^3.0.0" - get-caller-file "^2.0.1" - require-directory "^2.1.1" - require-main-filename "^2.0.0" - set-blocking "^2.0.0" - string-width "^3.0.0" - which-module "^2.0.0" - y18n "^4.0.0" - yargs-parser "^13.1.2" - yargs@16.2.0, yargs@^16.2.0: version "16.2.0" resolved "https://registry.yarnpkg.com/yargs/-/yargs-16.2.0.tgz#1c82bf0f6b6a66eafce7ef30e376f49a12477f66" @@ -10858,9 +10061,9 @@ yargs@16.2.0, yargs@^16.2.0: yargs-parser "^20.2.2" yargs@^17.6.2: - version "17.7.1" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.7.1.tgz#34a77645201d1a8fc5213ace787c220eabbd0967" - integrity sha512-cwiTb08Xuv5fqF4AovYacTFNxk62th7LKJ6BL9IGUpTJrWoU7/7WdQGTP2SjKf1dUNBGzDd28p/Yfs/GI6JrLw== + version "17.7.2" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.7.2.tgz#991df39aca675a192b816e1e0363f9d75d2aa269" + integrity sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w== dependencies: cliui "^8.0.1" escalade "^3.1.1" @@ -10870,6 +10073,26 @@ yargs@^17.6.2: y18n "^5.0.5" yargs-parser "^21.1.1" +yargs@^4.7.1: + version "4.8.1" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-4.8.1.tgz#c0c42924ca4aaa6b0e6da1739dfb216439f9ddc0" + integrity sha512-LqodLrnIDM3IFT+Hf/5sxBnEGECrfdC1uIbgZeJmESCSo4HoCAaKEus8MylXHAkdacGc0ye+Qa+dpkuom8uVYA== + dependencies: + cliui "^3.2.0" + decamelize "^1.1.1" + get-caller-file "^1.0.1" + lodash.assign "^4.0.3" + os-locale "^1.4.0" + read-pkg-up "^1.0.1" + require-directory "^2.1.1" + require-main-filename "^1.0.1" + set-blocking "^2.0.0" + string-width "^1.0.1" + which-module "^1.0.0" + window-size "^0.2.0" + y18n "^3.2.1" + yargs-parser "^2.4.1" + yn@3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/yn/-/yn-3.1.1.tgz#1e87401a09d767c1d5eab26a6e4c185182d2eb50" From dd62cddd70a0c16cf07642ae95a2ab9850e2d03e Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Fri, 1 Mar 2024 18:42:12 +0100 Subject: [PATCH 39/43] @airswap/stores: bump for npm publishing --- tools/stores/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/stores/package.json b/tools/stores/package.json index a04105467..4d6a756c8 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/stores", - "version": "4.2.6", + "version": "4.3.0", "description": "AirSwap: Storage for Indexing", "repository": { "type": "git", From 1c0b8a1f13fb28e79e4036e51ea04aab5a4a26cf Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Fri, 1 Mar 2024 19:18:52 +0100 Subject: [PATCH 40/43] bump batch-call, wrapper, libraries for publishing --- source/batch-call/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 4b5e6e84f..7449d1829 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/batch-call", - "version": "4.2.1", + "version": "4.2.2", "description": "Batch balance, allowance, order validity checks", "license": "MIT", "repository": { diff --git a/source/wrapper/package.json b/source/wrapper/package.json index dc6dae7e3..7c5fccfc9 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/wrapper", - "version": "4.2.1", + "version": "4.2.2", "description": "AirSwap: Wrap and Unwrap Native Tokens", "license": "MIT", "repository": { diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 64d1ee9de..3f491494f 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.3.0", + "version": "4.3.1", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -22,7 +22,7 @@ "test:ci": "yarn test" }, "dependencies": { - "@airswap/batch-call": "4.2.1", + "@airswap/batch-call": "4.2.2", "@airswap/jsonrpc-client-websocket": "0.0.1", "@airswap/registry": "4.2.1", "@airswap/pool": "4.2.1", @@ -30,7 +30,7 @@ "@airswap/swap": "4.2.1", "@airswap/swap-erc20": "4.3.0", "@airswap/utils": "4.3.0", - "@airswap/wrapper": "4.2.1", + "@airswap/wrapper": "4.2.2", "browser-or-node": "^2.1.1", "ethers": "^5.7.2", "jayson": "^4.0.0", From 38fb92daa3acf9afec69d0ab7155526534c9e21a Mon Sep 17 00:00:00 2001 From: don mosites Date: Wed, 13 Mar 2024 17:00:27 +0100 Subject: [PATCH 41/43] Additional swap-erc20 deploys; remove solidity deps from NPM packages (#1300) * deploys and blocks for base and arbitrum * move solidity deps to devdeps * merge deploys --- source/batch-call/package.json | 10 ++++------ source/pool/package.json | 6 ++---- source/registry/package.json | 6 ++---- source/staking/package.json | 6 ++---- source/swap-erc20/deploys-blocks.js | 9 +++++++++ source/swap-erc20/deploys.js | 9 +++++++++ source/swap-erc20/package.json | 10 ++++------ source/swap-erc20/scripts/deploy.js | 3 +-- source/swap/package.json | 8 +++----- source/wrapper/package.json | 8 +++----- tools/libraries/package.json | 16 ++++++++-------- tools/utils/src/constants.ts | 2 +- 12 files changed, 48 insertions(+), 45 deletions(-) diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 7449d1829..a6c19f4df 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/batch-call", - "version": "4.2.2", + "version": "4.2.3", "description": "Batch balance, allowance, order validity checks", "license": "MIT", "repository": { @@ -25,13 +25,11 @@ "verify": "hardhat run ./scripts/verify.js", "owners": "hardhat run ./scripts/owner.js" }, - "dependencies": { - "@openzeppelin/contracts": "^4.8.3", - "@airswap/swap": "4.2.1", - "@airswap/swap-erc20": "4.3.0" - }, "devDependencies": { "@airswap/utils": "4.3.0", + "@airswap/swap": "4.2.2", + "@airswap/swap-erc20": "4.3.1", + "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/pool/package.json b/source/pool/package.json index f1a481b3a..adaf0bfdb 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/pool", - "version": "4.2.1", + "version": "4.2.2", "description": "AirSwap: Withdrawable Token Pool", "license": "MIT", "repository": { @@ -27,12 +27,10 @@ "migrate": "hardhat run ./scripts/migrate.js", "balances": "hardhat run ./scripts/balances.js" }, - "dependencies": { - "@openzeppelin/contracts": "^4.8.3" - }, "devDependencies": { "@airswap/utils": "4.3.0", "@airswap/merkle": "0.0.2", + "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" }, "publishConfig": { diff --git a/source/registry/package.json b/source/registry/package.json index 72e8ea5f1..9a57dbede 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/registry", - "version": "4.2.1", + "version": "4.2.2", "description": "AirSwap: Server Registry", "license": "MIT", "repository": { @@ -25,14 +25,12 @@ "verify": "hardhat run ./scripts/verify.js", "owners": "hardhat run ./scripts/owner.js" }, - "dependencies": { - "@openzeppelin/contracts": "^4.8.3" - }, "publishConfig": { "access": "public" }, "devDependencies": { "@airswap/utils": "4.3.0", + "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" } } diff --git a/source/staking/package.json b/source/staking/package.json index 4f88bd0de..088f3f1c0 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/staking", - "version": "4.2.1", + "version": "4.2.2", "description": "AirSwap: Stake Tokens", "license": "MIT", "repository": { @@ -25,14 +25,12 @@ "verify": "hardhat run ./scripts/verify.js", "owners": "hardhat run ./scripts/owner.js" }, - "dependencies": { - "@openzeppelin/contracts": "^4.8.3" - }, "publishConfig": { "access": "public" }, "devDependencies": { "@airswap/utils": "4.3.0", + "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" } } diff --git a/source/swap-erc20/deploys-blocks.js b/source/swap-erc20/deploys-blocks.js index dffb6818b..36947b100 100644 --- a/source/swap-erc20/deploys-blocks.js +++ b/source/swap-erc20/deploys-blocks.js @@ -1,8 +1,17 @@ module.exports = { 1: 19341464, 56: 36593146, + 97: 38543402, 137: 54144778, + 8453: 11289587, + 42161: 186290627, + 17000: 1132433, + 43113: 30844328, 43114: 42345669, + 59140: 4286115, 59144: 2613444, + 80001: 47001356, + 84532: 7287254, + 421614: 22800328, 11155111: 5395281, } diff --git a/source/swap-erc20/deploys.js b/source/swap-erc20/deploys.js index 18ca0ce44..b016da41c 100644 --- a/source/swap-erc20/deploys.js +++ b/source/swap-erc20/deploys.js @@ -1,8 +1,17 @@ module.exports = { 1: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', 56: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 97: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', 137: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 8453: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 42161: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 17000: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 43113: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', 43114: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 59140: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', 59144: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 80001: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 84532: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', + 421614: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', 11155111: '0xD82E10B9A4107939e55fCCa9B53A9ede6CF2fC46', } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index bca7624c8..b869f8671 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/swap-erc20", - "version": "4.3.0", + "version": "4.3.1", "description": "AirSwap: Atomic ERC20 Token Swap", "license": "MIT", "repository": { @@ -25,13 +25,11 @@ "verify": "hardhat run ./scripts/verify.js", "owners": "hardhat run ./scripts/owner.js" }, - "dependencies": { - "solady": "0.0.173" - }, "devDependencies": { - "@airswap/staking": "4.2.1", + "@airswap/staking": "4.2.2", "@airswap/utils": "4.3.0", - "prompt-confirm": "^2.0.4" + "prompt-confirm": "^2.0.4", + "solady": "0.0.173" }, "publishConfig": { "access": "public" diff --git a/source/swap-erc20/scripts/deploy.js b/source/swap-erc20/scripts/deploy.js index d45dd8977..424febabc 100644 --- a/source/swap-erc20/scripts/deploy.js +++ b/source/swap-erc20/scripts/deploy.js @@ -8,7 +8,6 @@ const { ChainIds, chainLabels, protocolFeeReceiverAddresses, - ADDRESS_ZERO, } = require('@airswap/utils') const { getReceiptUrl } = require('@airswap/utils') const swapERC20Deploys = require('../deploys.js') @@ -27,7 +26,7 @@ async function main() { } await displayDeployerInfo(deployer) - let protocolFeeReceiver = poolDeploys[chainId] || ADDRESS_ZERO + let protocolFeeReceiver = poolDeploys[chainId] if (protocolFeeReceiverAddresses[chainId]) { protocolFeeReceiver = protocolFeeReceiverAddresses[chainId] } diff --git a/source/swap/package.json b/source/swap/package.json index 8d1f95bef..cac1eadde 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/swap", - "version": "4.2.1", + "version": "4.2.2", "description": "AirSwap: Atomic Token Swap", "license": "MIT", "repository": { @@ -28,12 +28,10 @@ "verify-adapters": "hardhat run ./scripts/verify-adapters.js", "owners": "hardhat run ./scripts/owner.js" }, - "dependencies": { - "@openzeppelin/contracts": "^4.8.3" - }, "devDependencies": { "@airswap/utils": "4.3.0", - "@nomicfoundation/hardhat-network-helpers": "^1.0.7" + "@nomicfoundation/hardhat-network-helpers": "^1.0.7", + "@openzeppelin/contracts": "^4.8.3" }, "publishConfig": { "access": "public" diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 7c5fccfc9..de6661c7b 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/wrapper", - "version": "4.2.2", + "version": "4.2.3", "description": "AirSwap: Wrap and Unwrap Native Tokens", "license": "MIT", "repository": { @@ -27,12 +27,10 @@ "verify": "hardhat run ./scripts/verify.js", "owners": "hardhat run ./scripts/owner.js" }, - "dependencies": { - "@airswap/swap-erc20": "4.3.0", - "@openzeppelin/contracts": "^4.8.3" - }, "devDependencies": { "@airswap/utils": "4.3.0", + "@airswap/swap-erc20": "4.3.1", + "@openzeppelin/contracts": "^4.8.3", "@uniswap/v2-periphery": "^1.1.0-beta.0", "prompt-confirm": "^2.0.4" }, diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 3f491494f..90d4cdbdb 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.3.1", + "version": "4.3.2", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -22,15 +22,15 @@ "test:ci": "yarn test" }, "dependencies": { - "@airswap/batch-call": "4.2.2", + "@airswap/batch-call": "4.2.3", "@airswap/jsonrpc-client-websocket": "0.0.1", - "@airswap/registry": "4.2.1", - "@airswap/pool": "4.2.1", - "@airswap/staking": "4.2.1", - "@airswap/swap": "4.2.1", - "@airswap/swap-erc20": "4.3.0", + "@airswap/registry": "4.2.2", + "@airswap/pool": "4.2.2", + "@airswap/staking": "4.2.2", + "@airswap/swap": "4.2.2", + "@airswap/swap-erc20": "4.3.1", "@airswap/utils": "4.3.0", - "@airswap/wrapper": "4.2.2", + "@airswap/wrapper": "4.2.3", "browser-or-node": "^2.1.1", "ethers": "^5.7.2", "jayson": "^4.0.0", diff --git a/tools/utils/src/constants.ts b/tools/utils/src/constants.ts index 820b0222d..e6b69123a 100644 --- a/tools/utils/src/constants.ts +++ b/tools/utils/src/constants.ts @@ -162,7 +162,7 @@ export const apiUrls: Record = { [ChainIds.AVALANCHE]: 'https://api.avax.network/ext/bc/C/rpc', [ChainIds.LINEAGOERLI]: 'https://rpc.goerli.linea.build', [ChainIds.LINEA]: 'https://rpc.linea.build', - [ChainIds.MUMBAI]: 'https://rpc-mumbai.maticvigil.com', + [ChainIds.MUMBAI]: 'https://gateway.tenderly.co/public/polygon-mumbai', [ChainIds.BASESEPOLIA]: 'https://sepolia.base.org', [ChainIds.ARBITRUMSEPOLIA]: 'https://sepolia-rollup.arbitrum.io/rpc', [ChainIds.SEPOLIA]: 'https://ethereum-sepolia.publicnode.com', From 64f78ae4d6593e83cc14e4b93a5e692b1e712a31 Mon Sep 17 00:00:00 2001 From: don mosites Date: Thu, 14 Mar 2024 19:42:59 +0100 Subject: [PATCH 42/43] remove openzeppelin from utils deps (#1301) --- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 4 +- tools/stores/package.json | 4 +- tools/utils/package.json | 6 +- tools/utils/src/abis/ERC1155.json | 334 ++++++++++++++++++++++++++++ tools/utils/src/abis/ERC165.json | 30 +++ tools/utils/src/abis/ERC20.json | 297 +++++++++++++++++++++++++ tools/utils/src/abis/ERC721.json | 357 ++++++++++++++++++++++++++++++ tools/utils/src/metadata.ts | 8 +- 15 files changed, 1034 insertions(+), 20 deletions(-) create mode 100644 tools/utils/src/abis/ERC1155.json create mode 100644 tools/utils/src/abis/ERC165.json create mode 100644 tools/utils/src/abis/ERC20.json create mode 100644 tools/utils/src/abis/ERC721.json diff --git a/source/batch-call/package.json b/source/batch-call/package.json index a6c19f4df..6378f306b 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -26,7 +26,7 @@ "owners": "hardhat run ./scripts/owner.js" }, "devDependencies": { - "@airswap/utils": "4.3.0", + "@airswap/utils": "4.3.1", "@airswap/swap": "4.2.2", "@airswap/swap-erc20": "4.3.1", "@openzeppelin/contracts": "^4.8.3", diff --git a/source/pool/package.json b/source/pool/package.json index adaf0bfdb..76c23deac 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -28,7 +28,7 @@ "balances": "hardhat run ./scripts/balances.js" }, "devDependencies": { - "@airswap/utils": "4.3.0", + "@airswap/utils": "4.3.1", "@airswap/merkle": "0.0.2", "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" diff --git a/source/registry/package.json b/source/registry/package.json index 9a57dbede..637a3bc9a 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -29,7 +29,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.3.0", + "@airswap/utils": "4.3.1", "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" } diff --git a/source/staking/package.json b/source/staking/package.json index 088f3f1c0..514a8de91 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -29,7 +29,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.3.0", + "@airswap/utils": "4.3.1", "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index b869f8671..5ab9b96f3 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -27,7 +27,7 @@ }, "devDependencies": { "@airswap/staking": "4.2.2", - "@airswap/utils": "4.3.0", + "@airswap/utils": "4.3.1", "prompt-confirm": "^2.0.4", "solady": "0.0.173" }, diff --git a/source/swap/package.json b/source/swap/package.json index cac1eadde..d855cd27e 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -29,7 +29,7 @@ "owners": "hardhat run ./scripts/owner.js" }, "devDependencies": { - "@airswap/utils": "4.3.0", + "@airswap/utils": "4.3.1", "@nomicfoundation/hardhat-network-helpers": "^1.0.7", "@openzeppelin/contracts": "^4.8.3" }, diff --git a/source/wrapper/package.json b/source/wrapper/package.json index de6661c7b..3c9e402dd 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -28,7 +28,7 @@ "owners": "hardhat run ./scripts/owner.js" }, "devDependencies": { - "@airswap/utils": "4.3.0", + "@airswap/utils": "4.3.1", "@airswap/swap-erc20": "4.3.1", "@openzeppelin/contracts": "^4.8.3", "@uniswap/v2-periphery": "^1.1.0-beta.0", diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 90d4cdbdb..7f6fa8d88 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.3.2", + "version": "4.3.3", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -29,7 +29,7 @@ "@airswap/staking": "4.2.2", "@airswap/swap": "4.2.2", "@airswap/swap-erc20": "4.3.1", - "@airswap/utils": "4.3.0", + "@airswap/utils": "4.3.1", "@airswap/wrapper": "4.2.3", "browser-or-node": "^2.1.1", "ethers": "^5.7.2", diff --git a/tools/stores/package.json b/tools/stores/package.json index 4d6a756c8..fe18c5c75 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/stores", - "version": "4.3.0", + "version": "4.3.1", "description": "AirSwap: Storage for Indexing", "repository": { "type": "git", @@ -22,7 +22,7 @@ "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/utils": "4.3.0", + "@airswap/utils": "4.3.1", "redis": "^4.6.13" }, "devDependencies": { diff --git a/tools/utils/package.json b/tools/utils/package.json index e46aaa52f..0b1b10547 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.3.0", + "version": "4.3.1", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", @@ -22,7 +22,6 @@ }, "dependencies": { "@metamask/eth-sig-util": "^5.0.2", - "@openzeppelin/contracts": "^4.8.3", "@uniswap/token-lists": "^1.0.0-beta.24", "bignumber.js": "^9.0.1", "ethereumjs-util": "^7.1.5", @@ -30,9 +29,6 @@ "lz-string": "^1.5.0", "valid-url": "^1.0.9" }, - "devDependencies": { - "@openzeppelin/contracts": "^4.8.3" - }, "publishConfig": { "access": "public" } diff --git a/tools/utils/src/abis/ERC1155.json b/tools/utils/src/abis/ERC1155.json new file mode 100644 index 000000000..8486b3605 --- /dev/null +++ b/tools/utils/src/abis/ERC1155.json @@ -0,0 +1,334 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "ERC1155", + "sourceName": "contracts/token/ERC1155/ERC1155.sol", + "abi": [ + { + "inputs": [ + { + "internalType": "string", + "name": "uri_", + "type": "string" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "name": "ApprovalForAll", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "ids", + "type": "uint256[]" + }, + { + "indexed": false, + "internalType": "uint256[]", + "name": "values", + "type": "uint256[]" + } + ], + "name": "TransferBatch", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "TransferSingle", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "string", + "name": "value", + "type": "string" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "id", + "type": "uint256" + } + ], + "name": "URI", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "accounts", + "type": "address[]" + }, + { + "internalType": "uint256[]", + "name": "ids", + "type": "uint256[]" + } + ], + "name": "balanceOfBatch", + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + } + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256[]", + "name": "ids", + "type": "uint256[]" + }, + { + "internalType": "uint256[]", + "name": "amounts", + "type": "uint256[]" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "safeBatchTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "id", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4" + } + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "name": "uri", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + } + ], + "bytecode": "0x60806040523480156200001157600080fd5b50604051620015cb380380620015cb83398101604081905262000034916200011b565b6200003f8162000046565b5062000233565b80516200005b9060029060208401906200005f565b5050565b8280546200006d90620001f7565b90600052602060002090601f016020900481019282620000915760008555620000dc565b82601f10620000ac57805160ff1916838001178555620000dc565b82800160010185558215620000dc579182015b82811115620000dc578251825591602001919060010190620000bf565b50620000ea929150620000ee565b5090565b5b80821115620000ea5760008155600101620000ef565b634e487b7160e01b600052604160045260246000fd5b600060208083850312156200012f57600080fd5b82516001600160401b03808211156200014757600080fd5b818501915085601f8301126200015c57600080fd5b81518181111562000171576200017162000105565b604051601f8201601f19908116603f011681019083821181831017156200019c576200019c62000105565b816040528281528886848701011115620001b557600080fd5b600093505b82841015620001d95784840186015181850187015292850192620001ba565b82841115620001eb5760008684830101525b98975050505050505050565b600181811c908216806200020c57607f821691505b6020821081036200022d57634e487b7160e01b600052602260045260246000fd5b50919050565b61138880620002436000396000f3fe608060405234801561001057600080fd5b50600436106100875760003560e01c80634e1273f41161005b5780634e1273f41461010a578063a22cb4651461012a578063e985e9c51461013d578063f242432a1461017957600080fd5b8062fdd58e1461008c57806301ffc9a7146100b25780630e89341c146100d55780632eb2c2d6146100f5575b600080fd5b61009f61009a366004610b3f565b61018c565b6040519081526020015b60405180910390f35b6100c56100c0366004610b82565b610222565b60405190151581526020016100a9565b6100e86100e3366004610ba6565b610274565b6040516100a99190610c0c565b610108610103366004610d6b565b610308565b005b61011d610118366004610e15565b610354565b6040516100a99190610f1b565b610108610138366004610f2e565b61047e565b6100c561014b366004610f6a565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b610108610187366004610f9d565b61048d565b60006001600160a01b0383166101fc5760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b506000908152602081815260408083206001600160a01b03949094168352929052205490565b60006001600160e01b03198216636cdb3d1360e11b148061025357506001600160e01b031982166303a24d0760e21b145b8061026e57506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606002805461028390611002565b80601f01602080910402602001604051908101604052809291908181526020018280546102af90611002565b80156102fc5780601f106102d1576101008083540402835291602001916102fc565b820191906000526020600020905b8154815290600101906020018083116102df57829003601f168201915b50505050509050919050565b6001600160a01b0385163314806103245750610324853361014b565b6103405760405162461bcd60e51b81526004016101f39061103c565b61034d85858585856104d2565b5050505050565b606081518351146103b95760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b60648201526084016101f3565b6000835167ffffffffffffffff8111156103d5576103d5610c1f565b6040519080825280602002602001820160405280156103fe578160200160208202803683370190505b50905060005b8451811015610476576104498582815181106104225761042261108a565b602002602001015185838151811061043c5761043c61108a565b602002602001015161018c565b82828151811061045b5761045b61108a565b602090810291909101015261046f816110b6565b9050610404565b509392505050565b6104893383836106af565b5050565b6001600160a01b0385163314806104a957506104a9853361014b565b6104c55760405162461bcd60e51b81526004016101f39061103c565b61034d858585858561078f565b81518351146105345760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b60648201526084016101f3565b6001600160a01b03841661055a5760405162461bcd60e51b81526004016101f3906110cf565b3360005b845181101561064157600085828151811061057b5761057b61108a565b6020026020010151905060008583815181106105995761059961108a565b602090810291909101810151600084815280835260408082206001600160a01b038e1683529093529190912054909150818110156105e95760405162461bcd60e51b81526004016101f390611114565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b1682528120805484929061062690849061115e565b925050819055505050508061063a906110b6565b905061055e565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051610691929190611176565b60405180910390a46106a78187878787876108b9565b505050505050565b816001600160a01b0316836001600160a01b0316036107225760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b60648201526084016101f3565b6001600160a01b03838116600081815260016020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b0384166107b55760405162461bcd60e51b81526004016101f3906110cf565b3360006107c185610a1d565b905060006107ce85610a1d565b90506000868152602081815260408083206001600160a01b038c168452909152902054858110156108115760405162461bcd60e51b81526004016101f390611114565b6000878152602081815260408083206001600160a01b038d8116855292528083208985039055908a1682528120805488929061084e90849061115e565b909155505060408051888152602081018890526001600160a01b03808b16928c821692918816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a46108ae848a8a8a8a8a610a68565b505050505050505050565b6001600160a01b0384163b156106a75760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906108fd90899089908890889088906004016111a4565b6020604051808303816000875af1925050508015610938575060408051601f3d908101601f1916820190925261093591810190611202565b60015b6109e45761094461121f565b806308c379a00361097d575061095861123b565b80610963575061097f565b8060405162461bcd60e51b81526004016101f39190610c0c565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e2d455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b60648201526084016101f3565b6001600160e01b0319811663bc197c8160e01b14610a145760405162461bcd60e51b81526004016101f3906112c5565b50505050505050565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110610a5757610a5761108a565b602090810291909101015292915050565b6001600160a01b0384163b156106a75760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190610aac908990899088908890889060040161130d565b6020604051808303816000875af1925050508015610ae7575060408051601f3d908101601f19168201909252610ae491810190611202565b60015b610af35761094461121f565b6001600160e01b0319811663f23a6e6160e01b14610a145760405162461bcd60e51b81526004016101f3906112c5565b80356001600160a01b0381168114610b3a57600080fd5b919050565b60008060408385031215610b5257600080fd5b610b5b83610b23565b946020939093013593505050565b6001600160e01b031981168114610b7f57600080fd5b50565b600060208284031215610b9457600080fd5b8135610b9f81610b69565b9392505050565b600060208284031215610bb857600080fd5b5035919050565b6000815180845260005b81811015610be557602081850181015186830182015201610bc9565b81811115610bf7576000602083870101525b50601f01601f19169290920160200192915050565b602081526000610b9f6020830184610bbf565b634e487b7160e01b600052604160045260246000fd5b601f8201601f1916810167ffffffffffffffff81118282101715610c5b57610c5b610c1f565b6040525050565b600067ffffffffffffffff821115610c7c57610c7c610c1f565b5060051b60200190565b600082601f830112610c9757600080fd5b81356020610ca482610c62565b604051610cb18282610c35565b83815260059390931b8501820192828101915086841115610cd157600080fd5b8286015b84811015610cec5780358352918301918301610cd5565b509695505050505050565b600082601f830112610d0857600080fd5b813567ffffffffffffffff811115610d2257610d22610c1f565b604051610d39601f8301601f191660200182610c35565b818152846020838601011115610d4e57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a08688031215610d8357600080fd5b610d8c86610b23565b9450610d9a60208701610b23565b9350604086013567ffffffffffffffff80821115610db757600080fd5b610dc389838a01610c86565b94506060880135915080821115610dd957600080fd5b610de589838a01610c86565b93506080880135915080821115610dfb57600080fd5b50610e0888828901610cf7565b9150509295509295909350565b60008060408385031215610e2857600080fd5b823567ffffffffffffffff80821115610e4057600080fd5b818501915085601f830112610e5457600080fd5b81356020610e6182610c62565b604051610e6e8282610c35565b83815260059390931b8501820192828101915089841115610e8e57600080fd5b948201945b83861015610eb357610ea486610b23565b82529482019490820190610e93565b96505086013592505080821115610ec957600080fd5b50610ed685828601610c86565b9150509250929050565b600081518084526020808501945080840160005b83811015610f1057815187529582019590820190600101610ef4565b509495945050505050565b602081526000610b9f6020830184610ee0565b60008060408385031215610f4157600080fd5b610f4a83610b23565b915060208301358015158114610f5f57600080fd5b809150509250929050565b60008060408385031215610f7d57600080fd5b610f8683610b23565b9150610f9460208401610b23565b90509250929050565b600080600080600060a08688031215610fb557600080fd5b610fbe86610b23565b9450610fcc60208701610b23565b93506040860135925060608601359150608086013567ffffffffffffffff811115610ff657600080fd5b610e0888828901610cf7565b600181811c9082168061101657607f821691505b60208210810361103657634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252602e908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526d195c881bdc88185c1c1c9bdd995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016110c8576110c86110a0565b5060010190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b60008219821115611171576111716110a0565b500190565b6040815260006111896040830185610ee0565b828103602084015261119b8185610ee0565b95945050505050565b6001600160a01b0386811682528516602082015260a0604082018190526000906111d090830186610ee0565b82810360608401526111e28186610ee0565b905082810360808401526111f68185610bbf565b98975050505050505050565b60006020828403121561121457600080fd5b8151610b9f81610b69565b600060033d11156112385760046000803e5060005160e01c5b90565b600060443d10156112495790565b6040516003193d81016004833e81513d67ffffffffffffffff816024840111818411171561127957505050505090565b82850191508151818111156112915750505050505090565b843d87010160208285010111156112ab5750505050505090565b6112ba60208286010187610c35565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a06080820181905260009061134790830184610bbf565b97965050505050505056fea26469706673582212202f31a5ed9841bb19ea3048d1ee82155c8ba6a9a7cec7bee194b0e339d260147f64736f6c634300080d0033", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100875760003560e01c80634e1273f41161005b5780634e1273f41461010a578063a22cb4651461012a578063e985e9c51461013d578063f242432a1461017957600080fd5b8062fdd58e1461008c57806301ffc9a7146100b25780630e89341c146100d55780632eb2c2d6146100f5575b600080fd5b61009f61009a366004610b3f565b61018c565b6040519081526020015b60405180910390f35b6100c56100c0366004610b82565b610222565b60405190151581526020016100a9565b6100e86100e3366004610ba6565b610274565b6040516100a99190610c0c565b610108610103366004610d6b565b610308565b005b61011d610118366004610e15565b610354565b6040516100a99190610f1b565b610108610138366004610f2e565b61047e565b6100c561014b366004610f6a565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b610108610187366004610f9d565b61048d565b60006001600160a01b0383166101fc5760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b506000908152602081815260408083206001600160a01b03949094168352929052205490565b60006001600160e01b03198216636cdb3d1360e11b148061025357506001600160e01b031982166303a24d0760e21b145b8061026e57506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606002805461028390611002565b80601f01602080910402602001604051908101604052809291908181526020018280546102af90611002565b80156102fc5780601f106102d1576101008083540402835291602001916102fc565b820191906000526020600020905b8154815290600101906020018083116102df57829003601f168201915b50505050509050919050565b6001600160a01b0385163314806103245750610324853361014b565b6103405760405162461bcd60e51b81526004016101f39061103c565b61034d85858585856104d2565b5050505050565b606081518351146103b95760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b60648201526084016101f3565b6000835167ffffffffffffffff8111156103d5576103d5610c1f565b6040519080825280602002602001820160405280156103fe578160200160208202803683370190505b50905060005b8451811015610476576104498582815181106104225761042261108a565b602002602001015185838151811061043c5761043c61108a565b602002602001015161018c565b82828151811061045b5761045b61108a565b602090810291909101015261046f816110b6565b9050610404565b509392505050565b6104893383836106af565b5050565b6001600160a01b0385163314806104a957506104a9853361014b565b6104c55760405162461bcd60e51b81526004016101f39061103c565b61034d858585858561078f565b81518351146105345760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b60648201526084016101f3565b6001600160a01b03841661055a5760405162461bcd60e51b81526004016101f3906110cf565b3360005b845181101561064157600085828151811061057b5761057b61108a565b6020026020010151905060008583815181106105995761059961108a565b602090810291909101810151600084815280835260408082206001600160a01b038e1683529093529190912054909150818110156105e95760405162461bcd60e51b81526004016101f390611114565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b1682528120805484929061062690849061115e565b925050819055505050508061063a906110b6565b905061055e565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051610691929190611176565b60405180910390a46106a78187878787876108b9565b505050505050565b816001600160a01b0316836001600160a01b0316036107225760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b60648201526084016101f3565b6001600160a01b03838116600081815260016020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b0384166107b55760405162461bcd60e51b81526004016101f3906110cf565b3360006107c185610a1d565b905060006107ce85610a1d565b90506000868152602081815260408083206001600160a01b038c168452909152902054858110156108115760405162461bcd60e51b81526004016101f390611114565b6000878152602081815260408083206001600160a01b038d8116855292528083208985039055908a1682528120805488929061084e90849061115e565b909155505060408051888152602081018890526001600160a01b03808b16928c821692918816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a46108ae848a8a8a8a8a610a68565b505050505050505050565b6001600160a01b0384163b156106a75760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906108fd90899089908890889088906004016111a4565b6020604051808303816000875af1925050508015610938575060408051601f3d908101601f1916820190925261093591810190611202565b60015b6109e45761094461121f565b806308c379a00361097d575061095861123b565b80610963575061097f565b8060405162461bcd60e51b81526004016101f39190610c0c565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e2d455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b60648201526084016101f3565b6001600160e01b0319811663bc197c8160e01b14610a145760405162461bcd60e51b81526004016101f3906112c5565b50505050505050565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110610a5757610a5761108a565b602090810291909101015292915050565b6001600160a01b0384163b156106a75760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190610aac908990899088908890889060040161130d565b6020604051808303816000875af1925050508015610ae7575060408051601f3d908101601f19168201909252610ae491810190611202565b60015b610af35761094461121f565b6001600160e01b0319811663f23a6e6160e01b14610a145760405162461bcd60e51b81526004016101f3906112c5565b80356001600160a01b0381168114610b3a57600080fd5b919050565b60008060408385031215610b5257600080fd5b610b5b83610b23565b946020939093013593505050565b6001600160e01b031981168114610b7f57600080fd5b50565b600060208284031215610b9457600080fd5b8135610b9f81610b69565b9392505050565b600060208284031215610bb857600080fd5b5035919050565b6000815180845260005b81811015610be557602081850181015186830182015201610bc9565b81811115610bf7576000602083870101525b50601f01601f19169290920160200192915050565b602081526000610b9f6020830184610bbf565b634e487b7160e01b600052604160045260246000fd5b601f8201601f1916810167ffffffffffffffff81118282101715610c5b57610c5b610c1f565b6040525050565b600067ffffffffffffffff821115610c7c57610c7c610c1f565b5060051b60200190565b600082601f830112610c9757600080fd5b81356020610ca482610c62565b604051610cb18282610c35565b83815260059390931b8501820192828101915086841115610cd157600080fd5b8286015b84811015610cec5780358352918301918301610cd5565b509695505050505050565b600082601f830112610d0857600080fd5b813567ffffffffffffffff811115610d2257610d22610c1f565b604051610d39601f8301601f191660200182610c35565b818152846020838601011115610d4e57600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a08688031215610d8357600080fd5b610d8c86610b23565b9450610d9a60208701610b23565b9350604086013567ffffffffffffffff80821115610db757600080fd5b610dc389838a01610c86565b94506060880135915080821115610dd957600080fd5b610de589838a01610c86565b93506080880135915080821115610dfb57600080fd5b50610e0888828901610cf7565b9150509295509295909350565b60008060408385031215610e2857600080fd5b823567ffffffffffffffff80821115610e4057600080fd5b818501915085601f830112610e5457600080fd5b81356020610e6182610c62565b604051610e6e8282610c35565b83815260059390931b8501820192828101915089841115610e8e57600080fd5b948201945b83861015610eb357610ea486610b23565b82529482019490820190610e93565b96505086013592505080821115610ec957600080fd5b50610ed685828601610c86565b9150509250929050565b600081518084526020808501945080840160005b83811015610f1057815187529582019590820190600101610ef4565b509495945050505050565b602081526000610b9f6020830184610ee0565b60008060408385031215610f4157600080fd5b610f4a83610b23565b915060208301358015158114610f5f57600080fd5b809150509250929050565b60008060408385031215610f7d57600080fd5b610f8683610b23565b9150610f9460208401610b23565b90509250929050565b600080600080600060a08688031215610fb557600080fd5b610fbe86610b23565b9450610fcc60208701610b23565b93506040860135925060608601359150608086013567ffffffffffffffff811115610ff657600080fd5b610e0888828901610cf7565b600181811c9082168061101657607f821691505b60208210810361103657634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252602e908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526d195c881bdc88185c1c1c9bdd995960921b606082015260800190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000600182016110c8576110c86110a0565b5060010190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b60008219821115611171576111716110a0565b500190565b6040815260006111896040830185610ee0565b828103602084015261119b8185610ee0565b95945050505050565b6001600160a01b0386811682528516602082015260a0604082018190526000906111d090830186610ee0565b82810360608401526111e28186610ee0565b905082810360808401526111f68185610bbf565b98975050505050505050565b60006020828403121561121457600080fd5b8151610b9f81610b69565b600060033d11156112385760046000803e5060005160e01c5b90565b600060443d10156112495790565b6040516003193d81016004833e81513d67ffffffffffffffff816024840111818411171561127957505050505090565b82850191508151818111156112915750505050505090565b843d87010160208285010111156112ab5750505050505090565b6112ba60208286010187610c35565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a06080820181905260009061134790830184610bbf565b97965050505050505056fea26469706673582212202f31a5ed9841bb19ea3048d1ee82155c8ba6a9a7cec7bee194b0e339d260147f64736f6c634300080d0033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/tools/utils/src/abis/ERC165.json b/tools/utils/src/abis/ERC165.json new file mode 100644 index 000000000..e1bfd6b4f --- /dev/null +++ b/tools/utils/src/abis/ERC165.json @@ -0,0 +1,30 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "ERC165", + "sourceName": "contracts/utils/introspection/ERC165.sol", + "abi": [ + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4" + } + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + } + ], + "bytecode": "0x", + "deployedBytecode": "0x", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/tools/utils/src/abis/ERC20.json b/tools/utils/src/abis/ERC20.json new file mode 100644 index 000000000..e1f5a7ac6 --- /dev/null +++ b/tools/utils/src/abis/ERC20.json @@ -0,0 +1,297 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "ERC20", + "sourceName": "contracts/token/ERC20/ERC20.sol", + "abi": [ + { + "inputs": [ + { + "internalType": "string", + "name": "name_", + "type": "string" + }, + { + "internalType": "string", + "name": "symbol_", + "type": "string" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + } + ], + "bytecode": "0x60806040523480156200001157600080fd5b5060405162000aed38038062000aed8339810160408190526200003491620001db565b81516200004990600390602085019062000068565b5080516200005f90600490602084019062000068565b50505062000281565b828054620000769062000245565b90600052602060002090601f0160209004810192826200009a5760008555620000e5565b82601f10620000b557805160ff1916838001178555620000e5565b82800160010185558215620000e5579182015b82811115620000e5578251825591602001919060010190620000c8565b50620000f3929150620000f7565b5090565b5b80821115620000f35760008155600101620000f8565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200013657600080fd5b81516001600160401b03808211156200015357620001536200010e565b604051601f8301601f19908116603f011681019082821181831017156200017e576200017e6200010e565b816040528381526020925086838588010111156200019b57600080fd5b600091505b83821015620001bf5785820183015181830184015290820190620001a0565b83821115620001d15760008385830101525b9695505050505050565b60008060408385031215620001ef57600080fd5b82516001600160401b03808211156200020757600080fd5b620002158683870162000124565b935060208501519150808211156200022c57600080fd5b506200023b8582860162000124565b9150509250929050565b600181811c908216806200025a57607f821691505b6020821081036200027b57634e487b7160e01b600052602260045260246000fd5b50919050565b61085c80620002916000396000f3fe608060405234801561001057600080fd5b50600436106100a95760003560e01c80633950935111610071578063395093511461012357806370a082311461013657806395d89b411461015f578063a457c2d714610167578063a9059cbb1461017a578063dd62ed3e1461018d57600080fd5b806306fdde03146100ae578063095ea7b3146100cc57806318160ddd146100ef57806323b872dd14610101578063313ce56714610114575b600080fd5b6100b66101a0565b6040516100c3919061069a565b60405180910390f35b6100df6100da36600461070b565b610232565b60405190151581526020016100c3565b6002545b6040519081526020016100c3565b6100df61010f366004610735565b61024a565b604051601281526020016100c3565b6100df61013136600461070b565b61026e565b6100f3610144366004610771565b6001600160a01b031660009081526020819052604090205490565b6100b6610290565b6100df61017536600461070b565b61029f565b6100df61018836600461070b565b61031f565b6100f361019b366004610793565b61032d565b6060600380546101af906107c6565b80601f01602080910402602001604051908101604052809291908181526020018280546101db906107c6565b80156102285780601f106101fd57610100808354040283529160200191610228565b820191906000526020600020905b81548152906001019060200180831161020b57829003601f168201915b5050505050905090565b600033610240818585610358565b5060019392505050565b60003361025885828561047c565b6102638585856104f6565b506001949350505050565b600033610240818585610281838361032d565b61028b9190610800565b610358565b6060600480546101af906107c6565b600033816102ad828661032d565b9050838110156103125760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084015b60405180910390fd5b6102638286868403610358565b6000336102408185856104f6565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b6001600160a01b0383166103ba5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610309565b6001600160a01b03821661041b5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610309565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b6000610488848461032d565b905060001981146104f057818110156104e35760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610309565b6104f08484848403610358565b50505050565b6001600160a01b03831661055a5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610309565b6001600160a01b0382166105bc5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610309565b6001600160a01b038316600090815260208190526040902054818110156106345760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610309565b6001600160a01b03848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a36104f0565b600060208083528351808285015260005b818110156106c7578581018301518582016040015282016106ab565b818111156106d9576000604083870101525b50601f01601f1916929092016040019392505050565b80356001600160a01b038116811461070657600080fd5b919050565b6000806040838503121561071e57600080fd5b610727836106ef565b946020939093013593505050565b60008060006060848603121561074a57600080fd5b610753846106ef565b9250610761602085016106ef565b9150604084013590509250925092565b60006020828403121561078357600080fd5b61078c826106ef565b9392505050565b600080604083850312156107a657600080fd5b6107af836106ef565b91506107bd602084016106ef565b90509250929050565b600181811c908216806107da57607f821691505b6020821081036107fa57634e487b7160e01b600052602260045260246000fd5b50919050565b6000821982111561082157634e487b7160e01b600052601160045260246000fd5b50019056fea26469706673582212208ea3918651cefe661c47475f544a91c156156839b9d304a33b7b43e599a312a064736f6c634300080d0033", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100a95760003560e01c80633950935111610071578063395093511461012357806370a082311461013657806395d89b411461015f578063a457c2d714610167578063a9059cbb1461017a578063dd62ed3e1461018d57600080fd5b806306fdde03146100ae578063095ea7b3146100cc57806318160ddd146100ef57806323b872dd14610101578063313ce56714610114575b600080fd5b6100b66101a0565b6040516100c3919061069a565b60405180910390f35b6100df6100da36600461070b565b610232565b60405190151581526020016100c3565b6002545b6040519081526020016100c3565b6100df61010f366004610735565b61024a565b604051601281526020016100c3565b6100df61013136600461070b565b61026e565b6100f3610144366004610771565b6001600160a01b031660009081526020819052604090205490565b6100b6610290565b6100df61017536600461070b565b61029f565b6100df61018836600461070b565b61031f565b6100f361019b366004610793565b61032d565b6060600380546101af906107c6565b80601f01602080910402602001604051908101604052809291908181526020018280546101db906107c6565b80156102285780601f106101fd57610100808354040283529160200191610228565b820191906000526020600020905b81548152906001019060200180831161020b57829003601f168201915b5050505050905090565b600033610240818585610358565b5060019392505050565b60003361025885828561047c565b6102638585856104f6565b506001949350505050565b600033610240818585610281838361032d565b61028b9190610800565b610358565b6060600480546101af906107c6565b600033816102ad828661032d565b9050838110156103125760405162461bcd60e51b815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77604482015264207a65726f60d81b60648201526084015b60405180910390fd5b6102638286868403610358565b6000336102408185856104f6565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b6001600160a01b0383166103ba5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f206164646044820152637265737360e01b6064820152608401610309565b6001600160a01b03821661041b5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f206164647265604482015261737360f01b6064820152608401610309565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b6000610488848461032d565b905060001981146104f057818110156104e35760405162461bcd60e51b815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610309565b6104f08484848403610358565b50505050565b6001600160a01b03831661055a5760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b6064820152608401610309565b6001600160a01b0382166105bc5760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b6064820152608401610309565b6001600160a01b038316600090815260208190526040902054818110156106345760405162461bcd60e51b815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e7420657863656564732062604482015265616c616e636560d01b6064820152608401610309565b6001600160a01b03848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a36104f0565b600060208083528351808285015260005b818110156106c7578581018301518582016040015282016106ab565b818111156106d9576000604083870101525b50601f01601f1916929092016040019392505050565b80356001600160a01b038116811461070657600080fd5b919050565b6000806040838503121561071e57600080fd5b610727836106ef565b946020939093013593505050565b60008060006060848603121561074a57600080fd5b610753846106ef565b9250610761602085016106ef565b9150604084013590509250925092565b60006020828403121561078357600080fd5b61078c826106ef565b9392505050565b600080604083850312156107a657600080fd5b6107af836106ef565b91506107bd602084016106ef565b90509250929050565b600181811c908216806107da57607f821691505b6020821081036107fa57634e487b7160e01b600052602260045260246000fd5b50919050565b6000821982111561082157634e487b7160e01b600052601160045260246000fd5b50019056fea26469706673582212208ea3918651cefe661c47475f544a91c156156839b9d304a33b7b43e599a312a064736f6c634300080d0033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/tools/utils/src/abis/ERC721.json b/tools/utils/src/abis/ERC721.json new file mode 100644 index 000000000..789fdef4b --- /dev/null +++ b/tools/utils/src/abis/ERC721.json @@ -0,0 +1,357 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "ERC721", + "sourceName": "contracts/token/ERC721/ERC721.sol", + "abi": [ + { + "inputs": [ + { + "internalType": "string", + "name": "name_", + "type": "string" + }, + { + "internalType": "string", + "name": "symbol_", + "type": "string" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "approved", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "indexed": false, + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "name": "ApprovalForAll", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": true, + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "getApproved", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "operator", + "type": "address" + } + ], + "name": "isApprovedForAll", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "ownerOf", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "safeTransferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "operator", + "type": "address" + }, + { + "internalType": "bool", + "name": "approved", + "type": "bool" + } + ], + "name": "setApprovalForAll", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes4", + "name": "interfaceId", + "type": "bytes4" + } + ], + "name": "supportsInterface", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "tokenURI", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } + ], + "bytecode": "0x60806040523480156200001157600080fd5b506040516200138c3803806200138c8339810160408190526200003491620001db565b81516200004990600090602085019062000068565b5080516200005f90600190602084019062000068565b50505062000281565b828054620000769062000245565b90600052602060002090601f0160209004810192826200009a5760008555620000e5565b82601f10620000b557805160ff1916838001178555620000e5565b82800160010185558215620000e5579182015b82811115620000e5578251825591602001919060010190620000c8565b50620000f3929150620000f7565b5090565b5b80821115620000f35760008155600101620000f8565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200013657600080fd5b81516001600160401b03808211156200015357620001536200010e565b604051601f8301601f19908116603f011681019082821181831017156200017e576200017e6200010e565b816040528381526020925086838588010111156200019b57600080fd5b600091505b83821015620001bf5785820183015181830184015290820190620001a0565b83821115620001d15760008385830101525b9695505050505050565b60008060408385031215620001ef57600080fd5b82516001600160401b03808211156200020757600080fd5b620002158683870162000124565b935060208501519150808211156200022c57600080fd5b506200023b8582860162000124565b9150509250929050565b600181811c908216806200025a57607f821691505b6020821081036200027b57634e487b7160e01b600052602260045260246000fd5b50919050565b6110fb80620002916000396000f3fe608060405234801561001057600080fd5b50600436106100cf5760003560e01c80636352211e1161008c578063a22cb46511610066578063a22cb465146101b3578063b88d4fde146101c6578063c87b56dd146101d9578063e985e9c5146101ec57600080fd5b80636352211e1461017757806370a082311461018a57806395d89b41146101ab57600080fd5b806301ffc9a7146100d457806306fdde03146100fc578063081812fc14610111578063095ea7b31461013c57806323b872dd1461015157806342842e0e14610164575b600080fd5b6100e76100e2366004610c7f565b610228565b60405190151581526020015b60405180910390f35b61010461027a565b6040516100f39190610cf4565b61012461011f366004610d07565b61030c565b6040516001600160a01b0390911681526020016100f3565b61014f61014a366004610d3c565b610333565b005b61014f61015f366004610d66565b61044d565b61014f610172366004610d66565b61047e565b610124610185366004610d07565b610499565b61019d610198366004610da2565b6104f9565b6040519081526020016100f3565b61010461057f565b61014f6101c1366004610dbd565b61058e565b61014f6101d4366004610e0f565b61059d565b6101046101e7366004610d07565b6105d5565b6100e76101fa366004610eeb565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b60006001600160e01b031982166380ac58cd60e01b148061025957506001600160e01b03198216635b5e139f60e01b145b8061027457506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606000805461028990610f1e565b80601f01602080910402602001604051908101604052809291908181526020018280546102b590610f1e565b80156103025780601f106102d757610100808354040283529160200191610302565b820191906000526020600020905b8154815290600101906020018083116102e557829003601f168201915b5050505050905090565b600061031782610649565b506000908152600460205260409020546001600160a01b031690565b600061033e82610499565b9050806001600160a01b0316836001600160a01b0316036103b05760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b03821614806103cc57506103cc81336101fa565b61043e5760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c00000060648201526084016103a7565b61044883836106ab565b505050565b6104573382610719565b6104735760405162461bcd60e51b81526004016103a790610f58565b610448838383610798565b6104488383836040518060200160405280600081525061059d565b6000818152600260205260408120546001600160a01b0316806102745760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016103a7565b60006001600160a01b0382166105635760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016103a7565b506001600160a01b031660009081526003602052604090205490565b60606001805461028990610f1e565b6105993383836108fc565b5050565b6105a73383610719565b6105c35760405162461bcd60e51b81526004016103a790610f58565b6105cf848484846109ca565b50505050565b60606105e082610649565b60006105f760408051602081019091526000815290565b905060008151116106175760405180602001604052806000815250610642565b80610621846109fd565b604051602001610632929190610fa5565b6040516020818303038152906040525b9392505050565b6000818152600260205260409020546001600160a01b03166106a85760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016103a7565b50565b600081815260046020526040902080546001600160a01b0319166001600160a01b03841690811790915581906106e082610499565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008061072583610499565b9050806001600160a01b0316846001600160a01b0316148061076c57506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b806107905750836001600160a01b03166107858461030c565b6001600160a01b0316145b949350505050565b826001600160a01b03166107ab82610499565b6001600160a01b0316146107d15760405162461bcd60e51b81526004016103a790610fd4565b6001600160a01b0382166108335760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016103a7565b826001600160a01b031661084682610499565b6001600160a01b03161461086c5760405162461bcd60e51b81526004016103a790610fd4565b600081815260046020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260038552838620805460001901905590871680865283862080546001019055868652600290945282852080549092168417909155905184937fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b816001600160a01b0316836001600160a01b03160361095d5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016103a7565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6109d5848484610798565b6109e184848484610a90565b6105cf5760405162461bcd60e51b81526004016103a790611019565b60606000610a0a83610b91565b600101905060008167ffffffffffffffff811115610a2a57610a2a610df9565b6040519080825280601f01601f191660200182016040528015610a54576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a8504945084610a5e57509392505050565b60006001600160a01b0384163b15610b8657604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290610ad490339089908890889060040161106b565b6020604051808303816000875af1925050508015610b0f575060408051601f3d908101601f19168201909252610b0c918101906110a8565b60015b610b6c573d808015610b3d576040519150601f19603f3d011682016040523d82523d6000602084013e610b42565b606091505b508051600003610b645760405162461bcd60e51b81526004016103a790611019565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610790565b506001949350505050565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b8310610bd05772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef81000000008310610bfc576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc100008310610c1a57662386f26fc10000830492506010015b6305f5e1008310610c32576305f5e100830492506008015b6127108310610c4657612710830492506004015b60648310610c58576064830492506002015b600a83106102745760010192915050565b6001600160e01b0319811681146106a857600080fd5b600060208284031215610c9157600080fd5b813561064281610c69565b60005b83811015610cb7578181015183820152602001610c9f565b838111156105cf5750506000910152565b60008151808452610ce0816020860160208601610c9c565b601f01601f19169290920160200192915050565b6020815260006106426020830184610cc8565b600060208284031215610d1957600080fd5b5035919050565b80356001600160a01b0381168114610d3757600080fd5b919050565b60008060408385031215610d4f57600080fd5b610d5883610d20565b946020939093013593505050565b600080600060608486031215610d7b57600080fd5b610d8484610d20565b9250610d9260208501610d20565b9150604084013590509250925092565b600060208284031215610db457600080fd5b61064282610d20565b60008060408385031215610dd057600080fd5b610dd983610d20565b915060208301358015158114610dee57600080fd5b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215610e2557600080fd5b610e2e85610d20565b9350610e3c60208601610d20565b925060408501359150606085013567ffffffffffffffff80821115610e6057600080fd5b818701915087601f830112610e7457600080fd5b813581811115610e8657610e86610df9565b604051601f8201601f19908116603f01168101908382118183101715610eae57610eae610df9565b816040528281528a6020848701011115610ec757600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215610efe57600080fd5b610f0783610d20565b9150610f1560208401610d20565b90509250929050565b600181811c90821680610f3257607f821691505b602082108103610f5257634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b60008351610fb7818460208801610c9c565b835190830190610fcb818360208801610c9c565b01949350505050565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061109e90830184610cc8565b9695505050505050565b6000602082840312156110ba57600080fd5b815161064281610c6956fea26469706673582212203444012838d8a4d94e0f3add6d8bb2fb39f1578fcb587501af32ec2cd13620e164736f6c634300080d0033", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100cf5760003560e01c80636352211e1161008c578063a22cb46511610066578063a22cb465146101b3578063b88d4fde146101c6578063c87b56dd146101d9578063e985e9c5146101ec57600080fd5b80636352211e1461017757806370a082311461018a57806395d89b41146101ab57600080fd5b806301ffc9a7146100d457806306fdde03146100fc578063081812fc14610111578063095ea7b31461013c57806323b872dd1461015157806342842e0e14610164575b600080fd5b6100e76100e2366004610c7f565b610228565b60405190151581526020015b60405180910390f35b61010461027a565b6040516100f39190610cf4565b61012461011f366004610d07565b61030c565b6040516001600160a01b0390911681526020016100f3565b61014f61014a366004610d3c565b610333565b005b61014f61015f366004610d66565b61044d565b61014f610172366004610d66565b61047e565b610124610185366004610d07565b610499565b61019d610198366004610da2565b6104f9565b6040519081526020016100f3565b61010461057f565b61014f6101c1366004610dbd565b61058e565b61014f6101d4366004610e0f565b61059d565b6101046101e7366004610d07565b6105d5565b6100e76101fa366004610eeb565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b60006001600160e01b031982166380ac58cd60e01b148061025957506001600160e01b03198216635b5e139f60e01b145b8061027457506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606000805461028990610f1e565b80601f01602080910402602001604051908101604052809291908181526020018280546102b590610f1e565b80156103025780601f106102d757610100808354040283529160200191610302565b820191906000526020600020905b8154815290600101906020018083116102e557829003601f168201915b5050505050905090565b600061031782610649565b506000908152600460205260409020546001600160a01b031690565b600061033e82610499565b9050806001600160a01b0316836001600160a01b0316036103b05760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b03821614806103cc57506103cc81336101fa565b61043e5760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c00000060648201526084016103a7565b61044883836106ab565b505050565b6104573382610719565b6104735760405162461bcd60e51b81526004016103a790610f58565b610448838383610798565b6104488383836040518060200160405280600081525061059d565b6000818152600260205260408120546001600160a01b0316806102745760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016103a7565b60006001600160a01b0382166105635760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016103a7565b506001600160a01b031660009081526003602052604090205490565b60606001805461028990610f1e565b6105993383836108fc565b5050565b6105a73383610719565b6105c35760405162461bcd60e51b81526004016103a790610f58565b6105cf848484846109ca565b50505050565b60606105e082610649565b60006105f760408051602081019091526000815290565b905060008151116106175760405180602001604052806000815250610642565b80610621846109fd565b604051602001610632929190610fa5565b6040516020818303038152906040525b9392505050565b6000818152600260205260409020546001600160a01b03166106a85760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016103a7565b50565b600081815260046020526040902080546001600160a01b0319166001600160a01b03841690811790915581906106e082610499565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008061072583610499565b9050806001600160a01b0316846001600160a01b0316148061076c57506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b806107905750836001600160a01b03166107858461030c565b6001600160a01b0316145b949350505050565b826001600160a01b03166107ab82610499565b6001600160a01b0316146107d15760405162461bcd60e51b81526004016103a790610fd4565b6001600160a01b0382166108335760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016103a7565b826001600160a01b031661084682610499565b6001600160a01b03161461086c5760405162461bcd60e51b81526004016103a790610fd4565b600081815260046020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260038552838620805460001901905590871680865283862080546001019055868652600290945282852080549092168417909155905184937fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b816001600160a01b0316836001600160a01b03160361095d5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016103a7565b6001600160a01b03838116600081815260056020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6109d5848484610798565b6109e184848484610a90565b6105cf5760405162461bcd60e51b81526004016103a790611019565b60606000610a0a83610b91565b600101905060008167ffffffffffffffff811115610a2a57610a2a610df9565b6040519080825280601f01601f191660200182016040528015610a54576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a8504945084610a5e57509392505050565b60006001600160a01b0384163b15610b8657604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290610ad490339089908890889060040161106b565b6020604051808303816000875af1925050508015610b0f575060408051601f3d908101601f19168201909252610b0c918101906110a8565b60015b610b6c573d808015610b3d576040519150601f19603f3d011682016040523d82523d6000602084013e610b42565b606091505b508051600003610b645760405162461bcd60e51b81526004016103a790611019565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050610790565b506001949350505050565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b8310610bd05772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef81000000008310610bfc576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc100008310610c1a57662386f26fc10000830492506010015b6305f5e1008310610c32576305f5e100830492506008015b6127108310610c4657612710830492506004015b60648310610c58576064830492506002015b600a83106102745760010192915050565b6001600160e01b0319811681146106a857600080fd5b600060208284031215610c9157600080fd5b813561064281610c69565b60005b83811015610cb7578181015183820152602001610c9f565b838111156105cf5750506000910152565b60008151808452610ce0816020860160208601610c9c565b601f01601f19169290920160200192915050565b6020815260006106426020830184610cc8565b600060208284031215610d1957600080fd5b5035919050565b80356001600160a01b0381168114610d3757600080fd5b919050565b60008060408385031215610d4f57600080fd5b610d5883610d20565b946020939093013593505050565b600080600060608486031215610d7b57600080fd5b610d8484610d20565b9250610d9260208501610d20565b9150604084013590509250925092565b600060208284031215610db457600080fd5b61064282610d20565b60008060408385031215610dd057600080fd5b610dd983610d20565b915060208301358015158114610dee57600080fd5b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215610e2557600080fd5b610e2e85610d20565b9350610e3c60208601610d20565b925060408501359150606085013567ffffffffffffffff80821115610e6057600080fd5b818701915087601f830112610e7457600080fd5b813581811115610e8657610e86610df9565b604051601f8201601f19908116603f01168101908382118183101715610eae57610eae610df9565b816040528281528a6020848701011115610ec757600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215610efe57600080fd5b610f0783610d20565b9150610f1560208401610d20565b90509250929050565b600181811c90821680610f3257607f821691505b602082108103610f5257634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b60008351610fb7818460208801610c9c565b835190830190610fcb818360208801610c9c565b01949350505050565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061109e90830184610cc8565b9695505050505050565b6000602082840312156110ba57600080fd5b815161064281610c6956fea26469706673582212203444012838d8a4d94e0f3add6d8bb2fb39f1578fcb587501af32ec2cd13620e164736f6c634300080d0033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/tools/utils/src/metadata.ts b/tools/utils/src/metadata.ts index bdc65ba69..d882fb6d8 100644 --- a/tools/utils/src/metadata.ts +++ b/tools/utils/src/metadata.ts @@ -22,10 +22,10 @@ const AIRSWAP_SYMBOL = 'AST' const DEFAULT_NAME = 'Unknown NFT' const DEFAULT_IPFS_URI = 'https://ipfs.io/ipfs/' -import { abi as ERC165_ABI } from '@openzeppelin/contracts/build/contracts/ERC165.json' -import { abi as ERC20_ABI } from '@openzeppelin/contracts/build/contracts/ERC20.json' -import { abi as ERC721_ABI } from '@openzeppelin/contracts/build/contracts/ERC721.json' -import { abi as ERC1155_ABI } from '@openzeppelin/contracts/build/contracts/ERC1155.json' +import { abi as ERC165_ABI } from './abis/ERC165.json' +import { abi as ERC20_ABI } from './abis/ERC20.json' +import { abi as ERC721_ABI } from './abis/ERC721.json' +import { abi as ERC1155_ABI } from './abis/ERC1155.json' export async function getKnownTokens( chainId: number From 6ad0137fa62ab2bd9eead257b77b8f77962d0bf3 Mon Sep 17 00:00:00 2001 From: Don Mosites Date: Thu, 14 Mar 2024 20:08:10 +0100 Subject: [PATCH 43/43] @airswap/utils dep quickfix; publish to npm --- source/batch-call/package.json | 2 +- source/pool/package.json | 2 +- source/registry/package.json | 2 +- source/staking/package.json | 2 +- source/swap-erc20/package.json | 2 +- source/swap/package.json | 2 +- source/wrapper/package.json | 2 +- tools/libraries/package.json | 4 ++-- tools/stores/package.json | 4 ++-- tools/utils/package.json | 2 +- tools/utils/src/swap-erc20.ts | 2 +- 11 files changed, 13 insertions(+), 13 deletions(-) diff --git a/source/batch-call/package.json b/source/batch-call/package.json index 6378f306b..c9e68da3f 100644 --- a/source/batch-call/package.json +++ b/source/batch-call/package.json @@ -26,7 +26,7 @@ "owners": "hardhat run ./scripts/owner.js" }, "devDependencies": { - "@airswap/utils": "4.3.1", + "@airswap/utils": "4.3.2", "@airswap/swap": "4.2.2", "@airswap/swap-erc20": "4.3.1", "@openzeppelin/contracts": "^4.8.3", diff --git a/source/pool/package.json b/source/pool/package.json index 76c23deac..232e56dcb 100644 --- a/source/pool/package.json +++ b/source/pool/package.json @@ -28,7 +28,7 @@ "balances": "hardhat run ./scripts/balances.js" }, "devDependencies": { - "@airswap/utils": "4.3.1", + "@airswap/utils": "4.3.2", "@airswap/merkle": "0.0.2", "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" diff --git a/source/registry/package.json b/source/registry/package.json index 637a3bc9a..6c7cd36e6 100644 --- a/source/registry/package.json +++ b/source/registry/package.json @@ -29,7 +29,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.3.1", + "@airswap/utils": "4.3.2", "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" } diff --git a/source/staking/package.json b/source/staking/package.json index 514a8de91..8e5db6f17 100644 --- a/source/staking/package.json +++ b/source/staking/package.json @@ -29,7 +29,7 @@ "access": "public" }, "devDependencies": { - "@airswap/utils": "4.3.1", + "@airswap/utils": "4.3.2", "@openzeppelin/contracts": "^4.8.3", "prompt-confirm": "^2.0.4" } diff --git a/source/swap-erc20/package.json b/source/swap-erc20/package.json index 5ab9b96f3..01ae29a6c 100644 --- a/source/swap-erc20/package.json +++ b/source/swap-erc20/package.json @@ -27,7 +27,7 @@ }, "devDependencies": { "@airswap/staking": "4.2.2", - "@airswap/utils": "4.3.1", + "@airswap/utils": "4.3.2", "prompt-confirm": "^2.0.4", "solady": "0.0.173" }, diff --git a/source/swap/package.json b/source/swap/package.json index d855cd27e..c90e718e0 100644 --- a/source/swap/package.json +++ b/source/swap/package.json @@ -29,7 +29,7 @@ "owners": "hardhat run ./scripts/owner.js" }, "devDependencies": { - "@airswap/utils": "4.3.1", + "@airswap/utils": "4.3.2", "@nomicfoundation/hardhat-network-helpers": "^1.0.7", "@openzeppelin/contracts": "^4.8.3" }, diff --git a/source/wrapper/package.json b/source/wrapper/package.json index 3c9e402dd..fb2f8de8a 100644 --- a/source/wrapper/package.json +++ b/source/wrapper/package.json @@ -28,7 +28,7 @@ "owners": "hardhat run ./scripts/owner.js" }, "devDependencies": { - "@airswap/utils": "4.3.1", + "@airswap/utils": "4.3.2", "@airswap/swap-erc20": "4.3.1", "@openzeppelin/contracts": "^4.8.3", "@uniswap/v2-periphery": "^1.1.0-beta.0", diff --git a/tools/libraries/package.json b/tools/libraries/package.json index 7f6fa8d88..715fc1065 100644 --- a/tools/libraries/package.json +++ b/tools/libraries/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/libraries", - "version": "4.3.3", + "version": "4.3.4", "description": "AirSwap: Libraries for Developers", "repository": { "type": "git", @@ -29,7 +29,7 @@ "@airswap/staking": "4.2.2", "@airswap/swap": "4.2.2", "@airswap/swap-erc20": "4.3.1", - "@airswap/utils": "4.3.1", + "@airswap/utils": "4.3.2", "@airswap/wrapper": "4.2.3", "browser-or-node": "^2.1.1", "ethers": "^5.7.2", diff --git a/tools/stores/package.json b/tools/stores/package.json index fe18c5c75..c878e058f 100644 --- a/tools/stores/package.json +++ b/tools/stores/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/stores", - "version": "4.3.1", + "version": "4.3.2", "description": "AirSwap: Storage for Indexing", "repository": { "type": "git", @@ -22,7 +22,7 @@ "test": "REDISCLOUD_URL=redis://localhost:6379 TS_NODE_COMPILER_OPTIONS='{\"strict\":false}' yarn mocha -r ts-node/esm test/*.ts" }, "dependencies": { - "@airswap/utils": "4.3.1", + "@airswap/utils": "4.3.2", "redis": "^4.6.13" }, "devDependencies": { diff --git a/tools/utils/package.json b/tools/utils/package.json index 0b1b10547..5ba564d42 100644 --- a/tools/utils/package.json +++ b/tools/utils/package.json @@ -1,6 +1,6 @@ { "name": "@airswap/utils", - "version": "4.3.1", + "version": "4.3.2", "description": "AirSwap: Utilities for Developers", "repository": { "type": "git", diff --git a/tools/utils/src/swap-erc20.ts b/tools/utils/src/swap-erc20.ts index c41783e78..98568fece 100644 --- a/tools/utils/src/swap-erc20.ts +++ b/tools/utils/src/swap-erc20.ts @@ -7,7 +7,7 @@ import { SignTypedDataVersion, } from '@metamask/eth-sig-util' -import { abi as ERC20_ABI } from '@openzeppelin/contracts/build/contracts/ERC20.json' +import { abi as ERC20_ABI } from './abis/ERC20.json' const erc20Interface = new ethers.utils.Interface(ERC20_ABI) import {