From dd1f58446984dadfe8f3d88c45a10743bdf6470f Mon Sep 17 00:00:00 2001 From: GopherJ Date: Sun, 19 Nov 2023 09:49:00 +0800 Subject: [PATCH 01/13] feat: add sepolia & arbitrun sepolia Signed-off-by: GopherJ --- hardhat.config.ts | 16 ++++++++++ helper-hardhat-config.ts | 16 ++++++++++ helpers/contracts-deployments.ts | 5 ++- helpers/hardhat-constants.ts | 9 ++++-- helpers/misc-utils.ts | 5 +++ helpers/types.ts | 4 +++ market-config/index.ts | 39 +++++++++++++++++++++++ package.json | 8 ++--- yarn.lock | 53 ++++++++++++++++++-------------- 9 files changed, 123 insertions(+), 32 deletions(-) diff --git a/hardhat.config.ts b/hardhat.config.ts index 55eb6d5e8..eccf200b3 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -27,6 +27,8 @@ import { MOONBASE_ETHERSCAN_KEY, LINEA_ETHERSCAN_KEY, LINEA_GOERLI_ETHERSCAN_KEY, + SEPOLIA_ETHERSCAN_KEY, + ARBITRUM_SEPOLIA_ETHERSCAN_KEY, } from "./helpers/hardhat-constants"; import {accounts} from "./wallets"; import {accounts as evmAccounts} from "./evm-wallets"; @@ -190,6 +192,11 @@ const hardhatConfig: HardhatUserConfig = { url: NETWORKS_RPC_URL[eEthereumNetwork.goerli], accounts: DEPLOYER, }, + sepolia: { + chainId: CHAINS_ID[eEthereumNetwork.sepolia], + url: NETWORKS_RPC_URL[eEthereumNetwork.sepolia], + accounts: DEPLOYER, + }, arbitrum: { chainId: CHAINS_ID[eEthereumNetwork.arbitrum], url: NETWORKS_RPC_URL[eEthereumNetwork.arbitrum], @@ -200,6 +207,11 @@ const hardhatConfig: HardhatUserConfig = { url: NETWORKS_RPC_URL[eEthereumNetwork.arbitrumGoerli], accounts: DEPLOYER, }, + arbitrumSepolia: { + chainId: CHAINS_ID[eEthereumNetwork.arbitrumSepolia], + url: NETWORKS_RPC_URL[eEthereumNetwork.arbitrumSepolia], + accounts: DEPLOYER, + }, polygon: { chainId: CHAINS_ID[eEthereumNetwork.polygon], url: NETWORKS_RPC_URL[eEthereumNetwork.polygon], @@ -257,8 +269,10 @@ const hardhatConfig: HardhatUserConfig = { localhost: ETHERSCAN_KEY, mainnet: ETHERSCAN_KEY, goerli: GOERLI_ETHERSCAN_KEY, + sepolia: SEPOLIA_ETHERSCAN_KEY, arbitrum: ARBITRUM_ETHERSCAN_KEY, arbitrumGoerli: ARBITRUM_GOERLI_ETHERSCAN_KEY, + arbitrumSepolia: ARBITRUM_SEPOLIA_ETHERSCAN_KEY, polygon: POLYGON_ETHERSCAN_KEY, polygonMumbai: POLYGON_MUMBAI_ETHERSCAN_KEY, polygonZkevm: POLYGON_ZKEVM_ETHERSCAN_KEY, @@ -271,8 +285,10 @@ const hardhatConfig: HardhatUserConfig = { customChains: [ eEthereumNetwork.localhost, eEthereumNetwork.goerli, + eEthereumNetwork.sepolia, eEthereumNetwork.arbitrum, eEthereumNetwork.arbitrumGoerli, + eEthereumNetwork.arbitrumSepolia, eEthereumNetwork.polygon, eEthereumNetwork.polygonZkevm, eEthereumNetwork.polygonMumbai, diff --git a/helper-hardhat-config.ts b/helper-hardhat-config.ts index 50717531b..58f733a0a 100644 --- a/helper-hardhat-config.ts +++ b/helper-hardhat-config.ts @@ -9,6 +9,7 @@ import { FORK_BLOCK_NUMBER, FORK_CHAINID, GOERLI_CHAINID, + SEPOLIA_CHAINID, HARDHAT_CHAINID, INFURA_KEY, L1_RPC_URL, @@ -27,6 +28,7 @@ import { TENDERLY_FORK_ID, ZKSYNC_CHAINID, ZKSYNC_GOERLI_CHAINID, + ARBITRUM_SEPOLIA_CHAINID, } from "./helpers/hardhat-constants"; dotenv.config(); @@ -55,6 +57,12 @@ export const NETWORKS_RPC_URL: iParamsPerNetwork = { (ALCHEMY_KEY ? `https://eth-goerli.alchemyapi.io/v2/${ALCHEMY_KEY}` : `https://goerli.infura.io/v3/${INFURA_KEY}`), + [eEthereumNetwork.sepolia]: + L1_RPC_URL || + RPC_URL || + (ALCHEMY_KEY + ? `https://eth-sepolia.alchemyapi.io/v2/${ALCHEMY_KEY}` + : `https://sepolia.infura.io/v3/${INFURA_KEY}`), [eEthereumNetwork.mainnet]: L1_RPC_URL || RPC_URL || @@ -77,6 +85,10 @@ export const NETWORKS_RPC_URL: iParamsPerNetwork = { L2_RPC_URL || RPC_URL || `https://arb-goerli.g.alchemy.com/v2/${ALCHEMY_KEY}`, + [eEthereumNetwork.arbitrumSepolia]: + L2_RPC_URL || + RPC_URL || + `https://arb-sepolia.g.alchemy.com/v2/${ALCHEMY_KEY}`, [eEthereumNetwork.polygon]: RPC_URL || `https://polygon-mainnet.g.alchemy.com/v2/${ALCHEMY_KEY}`, [eEthereumNetwork.polygonMumbai]: @@ -110,6 +122,7 @@ export const NETWORKS_RPC_URL: iParamsPerNetwork = { export const CHAINS_ID: iParamsPerNetwork = { [eEthereumNetwork.mainnet]: MAINNET_CHAINID, [eEthereumNetwork.goerli]: GOERLI_CHAINID, + [eEthereumNetwork.sepolia]: SEPOLIA_CHAINID, [eEthereumNetwork.hardhat]: FORK ? FORK_CHAINID : HARDHAT_CHAINID, [eEthereumNetwork.anvil]: HARDHAT_CHAINID, [eEthereumNetwork.ganache]: undefined, @@ -119,6 +132,7 @@ export const CHAINS_ID: iParamsPerNetwork = { [eEthereumNetwork.moonbase]: MOONBASE_CHAINID, [eEthereumNetwork.arbitrum]: ARBITRUM_ONE_CHAINID, [eEthereumNetwork.arbitrumGoerli]: ARBITRUM_GOERLI_CHAINID, + [eEthereumNetwork.arbitrumSepolia]: ARBITRUM_SEPOLIA_CHAINID, [eEthereumNetwork.polygon]: POLYGON_CHAINID, [eEthereumNetwork.polygonMumbai]: POLYGON_MUMBAI_CHAINID, [eEthereumNetwork.polygonZkevm]: POLYGON_ZKEVM_CHAINID, @@ -132,6 +146,7 @@ export const CHAINS_ID: iParamsPerNetwork = { export const BLOCK_TO_FORK: iParamsPerNetwork = { [eEthereumNetwork.mainnet]: undefined, [eEthereumNetwork.goerli]: undefined, + [eEthereumNetwork.sepolia]: undefined, [eEthereumNetwork.hardhat]: undefined, [eEthereumNetwork.anvil]: undefined, [eEthereumNetwork.ganache]: undefined, @@ -141,6 +156,7 @@ export const BLOCK_TO_FORK: iParamsPerNetwork = { [eEthereumNetwork.moonbase]: undefined, [eEthereumNetwork.arbitrum]: undefined, [eEthereumNetwork.arbitrumGoerli]: undefined, + [eEthereumNetwork.arbitrumSepolia]: undefined, [eEthereumNetwork.polygon]: undefined, [eEthereumNetwork.polygonMumbai]: undefined, [eEthereumNetwork.polygonZkevm]: undefined, diff --git a/helpers/contracts-deployments.ts b/helpers/contracts-deployments.ts index b825dbb2f..bd01db02f 100644 --- a/helpers/contracts-deployments.ts +++ b/helpers/contracts-deployments.ts @@ -957,14 +957,13 @@ export const deployPoolComponents = async ( const config = getParaSpaceConfig(); const treasuryAddress = config.Treasury; - const cApe = await getAutoCompoundApe(); const poolApeStaking = allTokens.APE ? ((await withSaveAndVerify( await getContractFactory("PoolApeStaking", apeStakingLibraries), eContractid.PoolApeStakingImpl, [ provider, - cApe.address, + (await getAutoCompoundApe()).address, allTokens.APE.address, allTokens.USDC.address, (await getUniswapV3SwapRouter()).address, @@ -987,7 +986,7 @@ export const deployPoolComponents = async ( ? ((await withSaveAndVerify( await getContractFactory("PoolBorrowAndStake", BorrowAndStakeLibraries), eContractid.PoolBorrowAndStakeImpl, - [provider, cApe.address, allTokens.APE.address], + [provider, (await getAutoCompoundApe()).address, allTokens.APE.address], verify, false, BorrowAndStakeLibraries, diff --git a/helpers/hardhat-constants.ts b/helpers/hardhat-constants.ts index ef66a0b05..cdd8730ae 100644 --- a/helpers/hardhat-constants.ts +++ b/helpers/hardhat-constants.ts @@ -22,6 +22,7 @@ const getPrivateKeyfromEncryptedJson = ( export const HARDHAT_CHAINID = 31337; export const GOERLI_CHAINID = 5; +export const SEPOLIA_CHAINID = 11155111; export const FORK_CHAINID = 522; export const MAINNET_CHAINID = 1; export const PARALLEL_CHAINID = 1592; @@ -29,6 +30,7 @@ export const MOONBEAM_CHAINID = 1284; export const MOONBASE_CHAINID = 1287; export const ARBITRUM_ONE_CHAINID = 42161; export const ARBITRUM_GOERLI_CHAINID = 421613; +export const ARBITRUM_SEPOLIA_CHAINID = 421613; export const POLYGON_CHAINID = 137; export const POLYGON_ZKEVM_CHAINID = 1101; export const POLYGON_ZKEVM_GOERLI_CHAINID = 1442; @@ -67,10 +69,14 @@ export const DB_PATH = process.env.DB_PATH ?? ":memory:"; export const ETHERSCAN_KEY = process.env.ETHERSCAN_KEY || ""; export const GOERLI_ETHERSCAN_KEY = process.env.GOERLI_ETHERSCAN_KEY || ETHERSCAN_KEY; +export const SEPOLIA_ETHERSCAN_KEY = + process.env.SEPOLIA_ETHERSCAN_KEY || ETHERSCAN_KEY; export const ARBITRUM_ETHERSCAN_KEY = process.env.ARBITRUM_ETHERSCAN_KEY || ETHERSCAN_KEY; export const ARBITRUM_GOERLI_ETHERSCAN_KEY = process.env.ARBITRUM_GOERLI_ETHERSCAN_KEY || ARBITRUM_ETHERSCAN_KEY; +export const ARBITRUM_SEPOLIA_ETHERSCAN_KEY = + process.env.ARBITRUM_SEPOLIA_ETHERSCAN_KEY || ARBITRUM_ETHERSCAN_KEY; export const POLYGON_ETHERSCAN_KEY = process.env.POLYGON_ETHERSCAN_KEY || ETHERSCAN_KEY; export const POLYGON_MUMBAI_ETHERSCAN_KEY = @@ -498,5 +504,4 @@ export const XTOKEN_TYPE_UPGRADE_WHITELIST = .split(/\s?,\s?/) .map((x) => +x); export const XTOKEN_SYMBOL_UPGRADE_WHITELIST = - process.env.XTOKEN_SYMBOL_UPGRADE_WHITELIST?.trim() - .split(/\s?,\s?/); + process.env.XTOKEN_SYMBOL_UPGRADE_WHITELIST?.trim().split(/\s?,\s?/); diff --git a/helpers/misc-utils.ts b/helpers/misc-utils.ts index 011ff7f3a..36cf9f704 100644 --- a/helpers/misc-utils.ts +++ b/helpers/misc-utils.ts @@ -28,6 +28,8 @@ import { MOONBASE_CHAINID, LINEA_CHAINID, LINEA_GOERLI_CHAINID, + SEPOLIA_CHAINID, + ARBITRUM_SEPOLIA_CHAINID, } from "./hardhat-constants"; import {ConstructorArgs, eContractid, tEthereumAddress} from "./types"; import dotenv from "dotenv"; @@ -57,7 +59,9 @@ export const isPublicTestnet = (): boolean => { return ( [ GOERLI_CHAINID, + SEPOLIA_CHAINID, ARBITRUM_GOERLI_CHAINID, + ARBITRUM_SEPOLIA_CHAINID, ZKSYNC_GOERLI_CHAINID, POLYGON_ZKEVM_GOERLI_CHAINID, POLYGON_MUMBAI_CHAINID, @@ -67,6 +71,7 @@ export const isPublicTestnet = (): boolean => { [ eEthereumNetwork.goerli, eEthereumNetwork.arbitrumGoerli, + eEthereumNetwork.arbitrumSepolia, eEthereumNetwork.zksyncGoerli, eEthereumNetwork.polygonZkevmGoerli, eEthereumNetwork.polygonMumbai, diff --git a/helpers/types.ts b/helpers/types.ts index 5e6c1842e..c74d68748 100644 --- a/helpers/types.ts +++ b/helpers/types.ts @@ -84,6 +84,7 @@ export type ParaSpaceLibraryAddresses = Libraries; export enum eEthereumNetwork { ropsten = "ropsten", goerli = "goerli", + sepolia = "sepolia", mainnet = "mainnet", hardhat = "hardhat", tenderlyMain = "tenderlyMain", @@ -95,6 +96,7 @@ export enum eEthereumNetwork { moonbase = "moonbase", arbitrum = "arbitrum", arbitrumGoerli = "arbitrumGoerli", + arbitrumSepolia = "arbitrumSepolia", polygon = "polygon", polygonMumbai = "polygonMumbai", polygonZkevm = "polygonZkevm", @@ -745,6 +747,7 @@ export type iParamsPerNetworkAll = iEthereumParamsPerNetwork; export interface iEthereumParamsPerNetwork { [eEthereumNetwork.goerli]: T; + [eEthereumNetwork.sepolia]: T; [eEthereumNetwork.mainnet]: T; [eEthereumNetwork.hardhat]: T; [eEthereumNetwork.anvil]: T; @@ -755,6 +758,7 @@ export interface iEthereumParamsPerNetwork { [eEthereumNetwork.moonbase]: T; [eEthereumNetwork.arbitrum]: T; [eEthereumNetwork.arbitrumGoerli]: T; + [eEthereumNetwork.arbitrumSepolia]: T; [eEthereumNetwork.polygon]: T; [eEthereumNetwork.polygonMumbai]: T; [eEthereumNetwork.polygonZkevm]: T; diff --git a/market-config/index.ts b/market-config/index.ts index 5eecaa4cf..6f016d5b2 100644 --- a/market-config/index.ts +++ b/market-config/index.ts @@ -630,6 +630,44 @@ export const ArbitrumGoerliConfig: IParaSpaceConfiguration = { Mocks: MocksUSDConfig, Oracle: ArbitrumOracleConfig, }; +export const ArbitrumSepoliaConfig: IParaSpaceConfiguration = { + // BASIC INFO + ...CommonConfig, + ParaSpaceTeam: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", + Treasury: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", + Tokens: { + sAPE: "0x0000000000000000000000000000000000000001", + }, + YogaLabs: {}, + Uniswap: {}, + Marketplace: {}, + Chainlink: {}, + BendDAO: {}, + Stakefish: {}, + // RESERVE ASSETS - CONFIG, ASSETS, BORROW RATES, + ReservesConfig: { + DAI: strategyDAI, + USDC: strategyUSDC, + USDT: strategyUSDT, + FRAX: strategyFRAX, + WETH: strategyWETH, + WBTC: strategyWBTC, + aWETH: strategyAWETH, + cETH: strategyCETH, + PUNK: strategyPUNK, + BLUR: strategyBLUR, + DOODLE: strategyDoodles, + WPUNKS: strategyWPunks, + MOONBIRD: strategyMoonbird, + MEEBITS: strategyMeebits, + AZUKI: strategyAzuki, + OTHR: strategyOthr, + CLONEX: strategyClonex, + BLOCKS: strategyBLOCKS, + SEWER: strategySEWER, + PPG: strategyPudgyPenguins, + }, +}; export const ZkSyncGoerliConfig: IParaSpaceConfiguration = { // BASIC INFO @@ -1022,6 +1060,7 @@ export const ParaSpaceConfigs: Partial< [eEthereumNetwork.goerli]: GoerliConfig, [eEthereumNetwork.mainnet]: MainnetConfig, [eEthereumNetwork.arbitrumGoerli]: ArbitrumGoerliConfig, + [eEthereumNetwork.arbitrumSepolia]: ArbitrumSepoliaConfig, [eEthereumNetwork.arbitrum]: ArbitrumConfig, [eEthereumNetwork.polygon]: PolygonConfig, [eEthereumNetwork.polygonMumbai]: PolygonMumbaiConfig, diff --git a/package.json b/package.json index 2b9547652..3923cfe2f 100644 --- a/package.json +++ b/package.json @@ -47,12 +47,12 @@ "@safe-global/safe-ethers-lib": "^1.7.0", "@safe-global/safe-service-client": "^1.5.0", "@tenderly/hardhat-tenderly": "1.1.0-beta.5", - "@typechain/ethers-v5": "^11.0.0", - "@typechain/hardhat": "^6.1.2", + "@typechain/ethers-v5": "^11.1.2", + "@typechain/hardhat": "^9.1.0", "@types/chai": "^4.2.11", "@types/lowdb": "1.0.9", "@types/mocha": "^9.1.1", - "@types/node": "^18.0.6", + "@types/node": "^20.9.2", "@typescript-eslint/eslint-plugin": "5.33.0", "@typescript-eslint/parser": "5.33.0", "@uniswap/v3-periphery": "1.4.1", @@ -79,7 +79,7 @@ "hardhat-contract-sizer": "^2.0.3", "hardhat-deploy": "^0.11.30", "hardhat-gas-reporter": "^1.0.9", - "hardhat-typechain": "^0.3.3", + "hardhat-typechain": "^0.3.5", "husky": "^8.0.1", "lodash": "^4.17.21", "lowdb": "1.0.0", diff --git a/yarn.lock b/yarn.lock index ee72519f1..e45cccd70 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1619,12 +1619,12 @@ __metadata: "@safe-global/safe-ethers-lib": ^1.7.0 "@safe-global/safe-service-client": ^1.5.0 "@tenderly/hardhat-tenderly": 1.1.0-beta.5 - "@typechain/ethers-v5": ^11.0.0 - "@typechain/hardhat": ^6.1.2 + "@typechain/ethers-v5": ^11.1.2 + "@typechain/hardhat": ^9.1.0 "@types/chai": ^4.2.11 "@types/lowdb": 1.0.9 "@types/mocha": ^9.1.1 - "@types/node": ^18.0.6 + "@types/node": ^20.9.2 "@typescript-eslint/eslint-plugin": 5.33.0 "@typescript-eslint/parser": 5.33.0 "@uniswap/v3-periphery": 1.4.1 @@ -1651,7 +1651,7 @@ __metadata: hardhat-contract-sizer: ^2.0.3 hardhat-deploy: ^0.11.30 hardhat-gas-reporter: ^1.0.9 - hardhat-typechain: ^0.3.3 + hardhat-typechain: ^0.3.5 husky: ^8.0.1 lodash: ^4.17.21 lowdb: 1.0.0 @@ -2061,9 +2061,9 @@ __metadata: languageName: node linkType: hard -"@typechain/ethers-v5@npm:^11.0.0": - version: 11.1.1 - resolution: "@typechain/ethers-v5@npm:11.1.1" +"@typechain/ethers-v5@npm:^11.1.2": + version: 11.1.2 + resolution: "@typechain/ethers-v5@npm:11.1.2" dependencies: lodash: ^4.17.15 ts-essentials: ^7.0.1 @@ -2071,9 +2071,9 @@ __metadata: "@ethersproject/abi": ^5.0.0 "@ethersproject/providers": ^5.0.0 ethers: ^5.1.3 - typechain: ^8.3.1 + typechain: ^8.3.2 typescript: ">=4.3.0" - checksum: af4f3198c4f76e38cf45f992482329b172e1c668f5a5c4743764ab5011d928cdc66a1feb9c02dba80a14fb3124bc37f39a6956f5323c0ac32f919e09cfb2a3b8 + checksum: 4f2d458306094c8e57bc0e05c86c1def210bd8b2cadd1062218cbc35fe3f6ac98aca08646c935a6fa5e57599be9fc0ddd2d4f7cf960fe28e27bf3ed58906c71f languageName: node linkType: hard @@ -2089,19 +2089,17 @@ __metadata: languageName: node linkType: hard -"@typechain/hardhat@npm:^6.1.2": - version: 6.1.6 - resolution: "@typechain/hardhat@npm:6.1.6" +"@typechain/hardhat@npm:^9.1.0": + version: 9.1.0 + resolution: "@typechain/hardhat@npm:9.1.0" dependencies: fs-extra: ^9.1.0 peerDependencies: - "@ethersproject/abi": ^5.4.7 - "@ethersproject/providers": ^5.4.7 - "@typechain/ethers-v5": ^10.2.1 - ethers: ^5.4.7 + "@typechain/ethers-v6": ^0.5.1 + ethers: ^6.1.0 hardhat: ^2.9.9 - typechain: ^8.1.1 - checksum: f214bebf7860956230478cb92696ba757829cfd9dc65ac99c3bc7e539378310318d92b009054186f446595c8ffc1a81e9c6d028da0eb04253253049ea1b6e8d3 + typechain: ^8.3.2 + checksum: a05998ce89bb4a297f233f4489e4af2a3ad0abcedd75392096745a378d7c5bab9650fcd5dd778c9deaf790bf16e3a849b3ed91a6ae916173df6dfc9e574efcbc languageName: node linkType: hard @@ -2298,10 +2296,12 @@ __metadata: languageName: node linkType: hard -"@types/node@npm:^18.0.6": - version: 18.17.8 - resolution: "@types/node@npm:18.17.8" - checksum: ebb71526368c9c58f03e2c2408bfda4aa686c13d84226e2c9b48d9c4aee244fb82e672aaf4aa8ccb6e4993b4274d5f4b2b3d52d0a2e57ab187ae653903376411 +"@types/node@npm:^20.9.2": + version: 20.9.2 + resolution: "@types/node@npm:20.9.2" + dependencies: + undici-types: ~5.26.4 + checksum: 5bbb8fb2248fc5c5c4071d9809fb9af85997677c07124d65665202b53283a3b7bdff26fb844e9ee407e3847dfce6399c2b01e3329ea44a4b720647b1b987c678 languageName: node linkType: hard @@ -8515,7 +8515,7 @@ __metadata: languageName: node linkType: hard -"hardhat-typechain@npm:^0.3.3": +"hardhat-typechain@npm:^0.3.5": version: 0.3.5 resolution: "hardhat-typechain@npm:0.3.5" peerDependencies: @@ -15363,6 +15363,13 @@ __metadata: languageName: node linkType: hard +"undici-types@npm:~5.26.4": + version: 5.26.5 + resolution: "undici-types@npm:5.26.5" + checksum: 3192ef6f3fd5df652f2dc1cd782b49d6ff14dc98e5dced492aa8a8c65425227da5da6aafe22523c67f035a272c599bb89cfe803c1db6311e44bed3042fc25487 + languageName: node + linkType: hard + "undici@npm:^5.14.0": version: 5.23.0 resolution: "undici@npm:5.23.0" From 958a5b732a936740ce4f5aa30e78810eeab2dfda Mon Sep 17 00:00:00 2001 From: GopherJ Date: Sun, 26 Nov 2023 19:21:05 +0800 Subject: [PATCH 02/13] chore: support batch Signed-off-by: GopherJ --- helpers/hardhat-constants.ts | 2 +- tasks/dev/reserveConfigurator.ts | 142 ++++++++++++++++--------------- 2 files changed, 75 insertions(+), 69 deletions(-) diff --git a/helpers/hardhat-constants.ts b/helpers/hardhat-constants.ts index cdd8730ae..2ad45acb6 100644 --- a/helpers/hardhat-constants.ts +++ b/helpers/hardhat-constants.ts @@ -223,7 +223,7 @@ export const MULTI_SIG_NONCE = process.env.MULTI_SIG_NONCE ? parseInt(process.env.MULTI_SIG_NONCE) : undefined; export const MULTI_SEND_CHUNK_SIZE = parseInt( - process.env.MULTI_SEND_CHUNK_SIZE || "30" + process.env.MULTI_SEND_CHUNK_SIZE || "45" ); export const VERSION = version; diff --git a/tasks/dev/reserveConfigurator.ts b/tasks/dev/reserveConfigurator.ts index d045689c1..42cb291ec 100644 --- a/tasks/dev/reserveConfigurator.ts +++ b/tasks/dev/reserveConfigurator.ts @@ -4,9 +4,9 @@ import {DRY_RUN} from "../../helpers/hardhat-constants"; import {waitForTx} from "../../helpers/misc-utils"; task("set-ltv", "Set LTV") - .addPositionalParam("asset", "asset") + .addPositionalParam("assets", "assets") .addPositionalParam("ltv", "ltv") - .setAction(async ({asset, ltv}, DRE) => { + .setAction(async ({assets, ltv}, DRE) => { await DRE.run("set-DRE"); const {dryRunEncodedData} = await import("../../helpers/contracts-helpers"); const { @@ -19,40 +19,42 @@ task("set-ltv", "Set LTV") const configurator = await getPoolConfiguratorProxy(); const [reservesData] = await ui.getReservesData(provider.address); - const reserveData = reservesData.find( - (x) => x.underlyingAsset === utils.getAddress(asset) - ); - if (!reserveData) { - return; - } + for (const asset of assets.split(",")) { + const reserveData = reservesData.find( + (x) => x.underlyingAsset === utils.getAddress(asset) + ); + if (!reserveData) { + return; + } - const encodedData = configurator.interface.encodeFunctionData( - "configureReserveAsCollateral", - [ - reserveData.underlyingAsset, - ltv, - reserveData.reserveLiquidationThreshold, - reserveData.reserveLiquidationBonus, - ] - ); - if (DRY_RUN) { - await dryRunEncodedData(configurator.address, encodedData); - } else { - await waitForTx( - await configurator.configureReserveAsCollateral( + const encodedData = configurator.interface.encodeFunctionData( + "configureReserveAsCollateral", + [ reserveData.underlyingAsset, ltv, reserveData.reserveLiquidationThreshold, - reserveData.reserveLiquidationBonus - ) + reserveData.reserveLiquidationBonus, + ] ); + if (DRY_RUN) { + await dryRunEncodedData(configurator.address, encodedData); + } else { + await waitForTx( + await configurator.configureReserveAsCollateral( + reserveData.underlyingAsset, + ltv, + reserveData.reserveLiquidationThreshold, + reserveData.reserveLiquidationBonus + ) + ); + } } }); task("set-liquidation-threshold", "Set liquidation threshold") - .addPositionalParam("asset", "asset") + .addPositionalParam("assets", "assets") .addPositionalParam("liquidationThreshold", "liquidation threshold") - .setAction(async ({asset, liquidationThreshold}, DRE) => { + .setAction(async ({assets, liquidationThreshold}, DRE) => { await DRE.run("set-DRE"); const {dryRunEncodedData} = await import("../../helpers/contracts-helpers"); const { @@ -65,40 +67,42 @@ task("set-liquidation-threshold", "Set liquidation threshold") const configurator = await getPoolConfiguratorProxy(); const [reservesData] = await ui.getReservesData(provider.address); - const reserveData = reservesData.find( - (x) => x.underlyingAsset === utils.getAddress(asset) - ); - if (!reserveData) { - return; - } + for (const asset of assets.split(",")) { + const reserveData = reservesData.find( + (x) => x.underlyingAsset === utils.getAddress(asset) + ); + if (!reserveData) { + return; + } - const encodedData = configurator.interface.encodeFunctionData( - "configureReserveAsCollateral", - [ - reserveData.underlyingAsset, - reserveData.baseLTVasCollateral, - liquidationThreshold, - reserveData.reserveLiquidationBonus, - ] - ); - if (DRY_RUN) { - await dryRunEncodedData(configurator.address, encodedData); - } else { - await waitForTx( - await configurator.configureReserveAsCollateral( + const encodedData = configurator.interface.encodeFunctionData( + "configureReserveAsCollateral", + [ reserveData.underlyingAsset, reserveData.baseLTVasCollateral, liquidationThreshold, - reserveData.reserveLiquidationBonus - ) + reserveData.reserveLiquidationBonus, + ] ); + if (DRY_RUN) { + await dryRunEncodedData(configurator.address, encodedData); + } else { + await waitForTx( + await configurator.configureReserveAsCollateral( + reserveData.underlyingAsset, + reserveData.baseLTVasCollateral, + liquidationThreshold, + reserveData.reserveLiquidationBonus + ) + ); + } } }); task("set-reserve-factor", "Set reserve factor") - .addPositionalParam("asset", "asset") + .addPositionalParam("assets", "assets") .addPositionalParam("reserveFactor", "reserve factor") - .setAction(async ({asset, reserveFactor}, DRE) => { + .setAction(async ({assets, reserveFactor}, DRE) => { await DRE.run("set-DRE"); const {dryRunEncodedData} = await import("../../helpers/contracts-helpers"); const { @@ -111,26 +115,28 @@ task("set-reserve-factor", "Set reserve factor") const configurator = await getPoolConfiguratorProxy(); const [reservesData] = await ui.getReservesData(provider.address); - const reserveData = reservesData.find( - (x) => x.underlyingAsset === utils.getAddress(asset) - ); - if (!reserveData) { - return; - } + for (const asset of assets.split(",")) { + const reserveData = reservesData.find( + (x) => x.underlyingAsset === utils.getAddress(asset) + ); + if (!reserveData) { + return; + } - const encodedData = configurator.interface.encodeFunctionData( - "setReserveFactor", - [reserveData.underlyingAsset, reserveFactor] - ); - if (DRY_RUN) { - await dryRunEncodedData(configurator.address, encodedData); - } else { - await waitForTx( - await configurator.setReserveFactor( - reserveData.underlyingAsset, - reserveFactor - ) + const encodedData = configurator.interface.encodeFunctionData( + "setReserveFactor", + [reserveData.underlyingAsset, reserveFactor] ); + if (DRY_RUN) { + await dryRunEncodedData(configurator.address, encodedData); + } else { + await waitForTx( + await configurator.setReserveFactor( + reserveData.underlyingAsset, + reserveFactor + ) + ); + } } }); From 72b6bcff71a6a65ca1b4bdbc03ba1e68da3c5270 Mon Sep 17 00:00:00 2001 From: GopherJ Date: Tue, 28 Nov 2023 10:28:51 +0800 Subject: [PATCH 03/13] feat: add set-timelock-strategy Signed-off-by: GopherJ --- Makefile | 4 ++++ tasks/dev/reserveConfigurator.ts | 40 ++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+) diff --git a/Makefile b/Makefile index 857afca13..2d21ab442 100644 --- a/Makefile +++ b/Makefile @@ -576,6 +576,10 @@ set-interest-rate-strategy: set-auction-strategy: make TASK_NAME=set-auction-strategy run-task +.PHONY: set-timelock-strategy +set-timelock-strategy: + make TASK_NAME=set-timelock-strategy run-task + .PHONY: set-supply-cap set-supply-cap: make TASK_NAME=set-supply-cap run-task diff --git a/tasks/dev/reserveConfigurator.ts b/tasks/dev/reserveConfigurator.ts index 42cb291ec..6aaebcc3a 100644 --- a/tasks/dev/reserveConfigurator.ts +++ b/tasks/dev/reserveConfigurator.ts @@ -222,6 +222,46 @@ task("set-auction-strategy", "Set auction strategy") } }); +task("set-timelock-strategy", "Set timelock strategy") + .addPositionalParam("assets", "assets") + .addPositionalParam("timeLockStrategyAddress", "time lock strategy address") + .setAction(async ({assets, timeLockStrategyAddress}, DRE) => { + await DRE.run("set-DRE"); + const {dryRunEncodedData} = await import("../../helpers/contracts-helpers"); + const { + getPoolConfiguratorProxy, + getPoolAddressesProvider, + getUiPoolDataProvider, + } = await import("../../helpers/contracts-getters"); + const ui = await getUiPoolDataProvider(); + const provider = await getPoolAddressesProvider(); + const configurator = await getPoolConfiguratorProxy(); + const [reservesData] = await ui.getReservesData(provider.address); + + for (const asset of assets.split(",")) { + const reserveData = reservesData.find( + (x) => x.underlyingAsset === utils.getAddress(asset) + ); + if (!reserveData) { + continue; + } + const encodedData = configurator.interface.encodeFunctionData( + "setReserveTimeLockStrategyAddress", + [reserveData.underlyingAsset, timeLockStrategyAddress] + ); + if (DRY_RUN) { + await dryRunEncodedData(configurator.address, encodedData); + } else { + await waitForTx( + await configurator.setReserveTimeLockStrategyAddress( + reserveData.underlyingAsset, + timeLockStrategyAddress + ) + ); + } + } + }); + task("set-supply-cap", "Set supply cap") .addPositionalParam("asset", "asset") .addPositionalParam("supplyCap", "new supply cap") From e3a2c514ed6255d90efd09a151cd4ed4d8710fbc Mon Sep 17 00:00:00 2001 From: GopherJ Date: Tue, 28 Nov 2023 12:46:06 +0800 Subject: [PATCH 04/13] chore: add parax dev Signed-off-by: GopherJ --- hardhat.config.ts | 8 ++++++++ helper-hardhat-config.ts | 7 +++++++ helpers/hardhat-constants.ts | 8 ++++++++ helpers/types.ts | 2 ++ market-config/index.ts | 40 ++++++++++++++++++++++++++++++++---- 5 files changed, 61 insertions(+), 4 deletions(-) diff --git a/hardhat.config.ts b/hardhat.config.ts index eccf200b3..a5256e544 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -29,6 +29,7 @@ import { LINEA_GOERLI_ETHERSCAN_KEY, SEPOLIA_ETHERSCAN_KEY, ARBITRUM_SEPOLIA_ETHERSCAN_KEY, + PARAX_DEV_ETHERSCAN_KEY, } from "./helpers/hardhat-constants"; import {accounts} from "./wallets"; import {accounts as evmAccounts} from "./evm-wallets"; @@ -212,6 +213,11 @@ const hardhatConfig: HardhatUserConfig = { url: NETWORKS_RPC_URL[eEthereumNetwork.arbitrumSepolia], accounts: DEPLOYER, }, + paraxDev: { + chainId: CHAINS_ID[eEthereumNetwork.paraxDev], + url: NETWORKS_RPC_URL[eEthereumNetwork.paraxDev], + accounts: DEPLOYER, + }, polygon: { chainId: CHAINS_ID[eEthereumNetwork.polygon], url: NETWORKS_RPC_URL[eEthereumNetwork.polygon], @@ -273,6 +279,7 @@ const hardhatConfig: HardhatUserConfig = { arbitrum: ARBITRUM_ETHERSCAN_KEY, arbitrumGoerli: ARBITRUM_GOERLI_ETHERSCAN_KEY, arbitrumSepolia: ARBITRUM_SEPOLIA_ETHERSCAN_KEY, + paraxDev: PARAX_DEV_ETHERSCAN_KEY, polygon: POLYGON_ETHERSCAN_KEY, polygonMumbai: POLYGON_MUMBAI_ETHERSCAN_KEY, polygonZkevm: POLYGON_ZKEVM_ETHERSCAN_KEY, @@ -289,6 +296,7 @@ const hardhatConfig: HardhatUserConfig = { eEthereumNetwork.arbitrum, eEthereumNetwork.arbitrumGoerli, eEthereumNetwork.arbitrumSepolia, + eEthereumNetwork.paraxDev, eEthereumNetwork.polygon, eEthereumNetwork.polygonZkevm, eEthereumNetwork.polygonMumbai, diff --git a/helper-hardhat-config.ts b/helper-hardhat-config.ts index 58f733a0a..c8c8c6806 100644 --- a/helper-hardhat-config.ts +++ b/helper-hardhat-config.ts @@ -29,6 +29,7 @@ import { ZKSYNC_CHAINID, ZKSYNC_GOERLI_CHAINID, ARBITRUM_SEPOLIA_CHAINID, + PARAX_DEV_CHAINID, } from "./helpers/hardhat-constants"; dotenv.config(); @@ -89,6 +90,10 @@ export const NETWORKS_RPC_URL: iParamsPerNetwork = { L2_RPC_URL || RPC_URL || `https://arb-sepolia.g.alchemy.com/v2/${ALCHEMY_KEY}`, + [eEthereumNetwork.paraxDev]: + L2_RPC_URL || + RPC_URL || + `https://nitrorpc-widespread-brown-mosquito-de4v5k1jm5.t.conduit.xyz`, [eEthereumNetwork.polygon]: RPC_URL || `https://polygon-mainnet.g.alchemy.com/v2/${ALCHEMY_KEY}`, [eEthereumNetwork.polygonMumbai]: @@ -133,6 +138,7 @@ export const CHAINS_ID: iParamsPerNetwork = { [eEthereumNetwork.arbitrum]: ARBITRUM_ONE_CHAINID, [eEthereumNetwork.arbitrumGoerli]: ARBITRUM_GOERLI_CHAINID, [eEthereumNetwork.arbitrumSepolia]: ARBITRUM_SEPOLIA_CHAINID, + [eEthereumNetwork.paraxDev]: PARAX_DEV_CHAINID, [eEthereumNetwork.polygon]: POLYGON_CHAINID, [eEthereumNetwork.polygonMumbai]: POLYGON_MUMBAI_CHAINID, [eEthereumNetwork.polygonZkevm]: POLYGON_ZKEVM_CHAINID, @@ -157,6 +163,7 @@ export const BLOCK_TO_FORK: iParamsPerNetwork = { [eEthereumNetwork.arbitrum]: undefined, [eEthereumNetwork.arbitrumGoerli]: undefined, [eEthereumNetwork.arbitrumSepolia]: undefined, + [eEthereumNetwork.paraxDev]: undefined, [eEthereumNetwork.polygon]: undefined, [eEthereumNetwork.polygonMumbai]: undefined, [eEthereumNetwork.polygonZkevm]: undefined, diff --git a/helpers/hardhat-constants.ts b/helpers/hardhat-constants.ts index 2ad45acb6..b43d6d92b 100644 --- a/helpers/hardhat-constants.ts +++ b/helpers/hardhat-constants.ts @@ -26,6 +26,7 @@ export const SEPOLIA_CHAINID = 11155111; export const FORK_CHAINID = 522; export const MAINNET_CHAINID = 1; export const PARALLEL_CHAINID = 1592; +export const PARAX_DEV_CHAINID = 4009937698923195; export const MOONBEAM_CHAINID = 1284; export const MOONBASE_CHAINID = 1287; export const ARBITRUM_ONE_CHAINID = 42161; @@ -77,6 +78,8 @@ export const ARBITRUM_GOERLI_ETHERSCAN_KEY = process.env.ARBITRUM_GOERLI_ETHERSCAN_KEY || ARBITRUM_ETHERSCAN_KEY; export const ARBITRUM_SEPOLIA_ETHERSCAN_KEY = process.env.ARBITRUM_SEPOLIA_ETHERSCAN_KEY || ARBITRUM_ETHERSCAN_KEY; +export const PARAX_DEV_ETHERSCAN_KEY = + process.env.PARAX_DEV_ETHERSCAN_KEY || ETHERSCAN_KEY; export const POLYGON_ETHERSCAN_KEY = process.env.POLYGON_ETHERSCAN_KEY || ETHERSCAN_KEY; export const POLYGON_MUMBAI_ETHERSCAN_KEY = @@ -128,6 +131,8 @@ export const ETHERSCAN_APIS = { goerli: "https://api-goerli.etherscan.io/api", arbitrum: "https://api.arbiscan.io/api", arbitrumGoerli: "https://api-goerli.arbiscan.io/api", + paraxDev: + "https://explorerl2new-widespread-brown-mosquito-de4v5k1jm5.t.conduit.xyz/api", polygon: "https://api.polygonscan.com/api", matic: "https://api.polygonscan.com/api", polygonMumbai: "https://api-mumbai.polygonscan.com/api", @@ -147,8 +152,11 @@ export const BROWSER_URLS = { goerli: "https://goerli.etherscan.io", arbitrum: "https://arbiscan.io", arbitrumGoerli: "https://goerli.arbiscan.io", + arbitrumSepolia: "https://sepolia.arbiscan.io", polygonZkevm: "https://zkevm.polygonscan.com", polygonZkevmGoerli: "https://testnet-zkevm.polygonscan.com", + paraxDev: + "https://explorerl2new-widespread-brown-mosquito-de4v5k1jm5.t.conduit.xyz", polygon: "https://polygonscan.com", matic: "https://polygonscan.com", polygonMumbai: "https://mumbai.polygonscan.com", diff --git a/helpers/types.ts b/helpers/types.ts index c74d68748..e6317c714 100644 --- a/helpers/types.ts +++ b/helpers/types.ts @@ -97,6 +97,7 @@ export enum eEthereumNetwork { arbitrum = "arbitrum", arbitrumGoerli = "arbitrumGoerli", arbitrumSepolia = "arbitrumSepolia", + paraxDev = "paraxDev", polygon = "polygon", polygonMumbai = "polygonMumbai", polygonZkevm = "polygonZkevm", @@ -759,6 +760,7 @@ export interface iEthereumParamsPerNetwork { [eEthereumNetwork.arbitrum]: T; [eEthereumNetwork.arbitrumGoerli]: T; [eEthereumNetwork.arbitrumSepolia]: T; + [eEthereumNetwork.paraxDev]: T; [eEthereumNetwork.polygon]: T; [eEthereumNetwork.polygonMumbai]: T; [eEthereumNetwork.polygonZkevm]: T; diff --git a/market-config/index.ts b/market-config/index.ts index 6f016d5b2..4e8e59303 100644 --- a/market-config/index.ts +++ b/market-config/index.ts @@ -630,16 +630,49 @@ export const ArbitrumGoerliConfig: IParaSpaceConfiguration = { Mocks: MocksUSDConfig, Oracle: ArbitrumOracleConfig, }; + export const ArbitrumSepoliaConfig: IParaSpaceConfiguration = { // BASIC INFO ...CommonConfig, ParaSpaceTeam: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", Treasury: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", - Tokens: { - sAPE: "0x0000000000000000000000000000000000000001", + YogaLabs: {}, + Uniswap: {}, + Tokens: {}, + Marketplace: {}, + Chainlink: {}, + BendDAO: {}, + Stakefish: {}, + // RESERVE ASSETS - CONFIG, ASSETS, BORROW RATES, + ReservesConfig: { + DAI: strategyDAI, + USDC: strategyUSDC, + USDT: strategyUSDT, + FRAX: strategyFRAX, + WETH: strategyWETH, + WBTC: strategyWBTC, + PUNK: strategyPUNK, + BLUR: strategyBLUR, + DOODLE: strategyDoodles, + WPUNKS: strategyWPunks, + MOONBIRD: strategyMoonbird, + MEEBITS: strategyMeebits, + AZUKI: strategyAzuki, + OTHR: strategyOthr, + CLONEX: strategyClonex, + BLOCKS: strategyBLOCKS, + SEWER: strategySEWER, + PPG: strategyPudgyPenguins, }, +}; +export const ParaxDevConfig: IParaSpaceConfiguration = { + // BASIC INFO + ...CommonConfig, + ParaSpaceTeam: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", + Treasury: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", YogaLabs: {}, Uniswap: {}, + Tokens: {}, Marketplace: {}, Chainlink: {}, BendDAO: {}, @@ -652,8 +685,6 @@ export const ArbitrumSepoliaConfig: IParaSpaceConfiguration = { FRAX: strategyFRAX, WETH: strategyWETH, WBTC: strategyWBTC, - aWETH: strategyAWETH, - cETH: strategyCETH, PUNK: strategyPUNK, BLUR: strategyBLUR, DOODLE: strategyDoodles, @@ -1061,6 +1092,7 @@ export const ParaSpaceConfigs: Partial< [eEthereumNetwork.mainnet]: MainnetConfig, [eEthereumNetwork.arbitrumGoerli]: ArbitrumGoerliConfig, [eEthereumNetwork.arbitrumSepolia]: ArbitrumSepoliaConfig, + [eEthereumNetwork.paraxDev]: ParaxDevConfig, [eEthereumNetwork.arbitrum]: ArbitrumConfig, [eEthereumNetwork.polygon]: PolygonConfig, [eEthereumNetwork.polygonMumbai]: PolygonMumbaiConfig, From d986b8bcdfc2a73c536a4a7b907f5a9e3532ee77 Mon Sep 17 00:00:00 2001 From: GopherJ Date: Tue, 28 Nov 2023 14:21:38 +0800 Subject: [PATCH 05/13] chore: add missing info Signed-off-by: GopherJ --- Makefile | 4 ++-- helpers/hardhat-constants.ts | 4 ++++ helpers/misc-utils.ts | 3 +++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 2d21ab442..b498f34b7 100644 --- a/Makefile +++ b/Makefile @@ -448,8 +448,8 @@ send-eth: set-traits-multipliers: make SCRIPT_PATH=./scripts/dev/11.set-traits-multipliers.ts run -.PHONY: set-timelock-strategy -set-timelock-strategy: +.PHONY: update-timelock-strategy +update-timelock-strategy: make SCRIPT_PATH=./scripts/dev/12.set-timelock-strategy.ts run .PHONY: acl diff --git a/helpers/hardhat-constants.ts b/helpers/hardhat-constants.ts index b43d6d92b..79f91da3c 100644 --- a/helpers/hardhat-constants.ts +++ b/helpers/hardhat-constants.ts @@ -113,6 +113,9 @@ export const ETHERSCAN_NETWORKS = [ "mainnet", "goerli", "arbitrum", + "arbitrumGoerli", + "arbitrumSepolia", + "paraxDev", "polygon", "matic", "polygonMumbai", @@ -131,6 +134,7 @@ export const ETHERSCAN_APIS = { goerli: "https://api-goerli.etherscan.io/api", arbitrum: "https://api.arbiscan.io/api", arbitrumGoerli: "https://api-goerli.arbiscan.io/api", + arbitrumSepolia: "https://api-sepolia.arbiscan.io/api", paraxDev: "https://explorerl2new-widespread-brown-mosquito-de4v5k1jm5.t.conduit.xyz/api", polygon: "https://api.polygonscan.com/api", diff --git a/helpers/misc-utils.ts b/helpers/misc-utils.ts index 36cf9f704..9c1667032 100644 --- a/helpers/misc-utils.ts +++ b/helpers/misc-utils.ts @@ -30,6 +30,7 @@ import { LINEA_GOERLI_CHAINID, SEPOLIA_CHAINID, ARBITRUM_SEPOLIA_CHAINID, + PARAX_DEV_CHAINID, } from "./hardhat-constants"; import {ConstructorArgs, eContractid, tEthereumAddress} from "./types"; import dotenv from "dotenv"; @@ -62,6 +63,7 @@ export const isPublicTestnet = (): boolean => { SEPOLIA_CHAINID, ARBITRUM_GOERLI_CHAINID, ARBITRUM_SEPOLIA_CHAINID, + PARAX_DEV_CHAINID, ZKSYNC_GOERLI_CHAINID, POLYGON_ZKEVM_GOERLI_CHAINID, POLYGON_MUMBAI_CHAINID, @@ -72,6 +74,7 @@ export const isPublicTestnet = (): boolean => { eEthereumNetwork.goerli, eEthereumNetwork.arbitrumGoerli, eEthereumNetwork.arbitrumSepolia, + eEthereumNetwork.paraxDev, eEthereumNetwork.zksyncGoerli, eEthereumNetwork.polygonZkevmGoerli, eEthereumNetwork.polygonMumbai, From 7d7801066a2b33d8e7f99ab5b6cb2401e0c1c313 Mon Sep 17 00:00:00 2001 From: GopherJ Date: Tue, 28 Nov 2023 14:37:09 +0800 Subject: [PATCH 06/13] chore: fix parax dev deployment Signed-off-by: GopherJ --- helpers/hardhat-constants.ts | 2 ++ helpers/types.ts | 2 +- market-config/index.ts | 11 ++++++----- scripts/deployments/steps/10_allAggregators.ts | 10 ++++++---- scripts/deployments/steps/24_accountAbstraction.ts | 13 +++++++++---- 5 files changed, 24 insertions(+), 14 deletions(-) diff --git a/helpers/hardhat-constants.ts b/helpers/hardhat-constants.ts index 79f91da3c..93a986c2f 100644 --- a/helpers/hardhat-constants.ts +++ b/helpers/hardhat-constants.ts @@ -517,3 +517,5 @@ export const XTOKEN_TYPE_UPGRADE_WHITELIST = .map((x) => +x); export const XTOKEN_SYMBOL_UPGRADE_WHITELIST = process.env.XTOKEN_SYMBOL_UPGRADE_WHITELIST?.trim().split(/\s?,\s?/); + +export const STACKUP_KEY = process.env.STACKUP_KEY || ""; diff --git a/helpers/types.ts b/helpers/types.ts index e6317c714..7cdf7da7e 100644 --- a/helpers/types.ts +++ b/helpers/types.ts @@ -953,7 +953,7 @@ export interface ICommonConfiguration { Governance: IGovernanceConfig; - AccountAbstraction: IAccountAbstraction; + AccountAbstraction: IAccountAbstraction | undefined; } export interface IParaSpaceConfiguration extends ICommonConfiguration { diff --git a/market-config/index.ts b/market-config/index.ts index 4e8e59303..f18fda770 100644 --- a/market-config/index.ts +++ b/market-config/index.ts @@ -1,5 +1,5 @@ import {ZERO_ADDRESS} from "../helpers/constants"; -import {MULTI_SEND, MULTI_SIG} from "../helpers/hardhat-constants"; +import {MULTI_SEND, MULTI_SIG, STACKUP_KEY} from "../helpers/hardhat-constants"; import { eEthereumNetwork, ERC20TokenContractId, @@ -137,10 +137,7 @@ export const CommonConfig: Pick< }, // ParaSpaceV1 ParaSpaceV1: undefined, - AccountAbstraction: { - rpcUrl: `https://api.stackup.sh/v1/node/${process.env.STACKUP_KEY}`, - paymasterUrl: `https://api.stackup.sh/v1/paymaster/${process.env.STACKUP_KEY}`, - }, + AccountAbstraction: undefined, }; export const HardhatConfig: IParaSpaceConfiguration = { @@ -1078,6 +1075,10 @@ export const MainnetConfig: IParaSpaceConfiguration = { TimeLockV1: "0x59B72FdB45B3182c8502cC297167FE4f821f332d", P2PPairStakingV1: "0xf090Eb4c2B63e7B26E8Bb09e6Fc0cC3A7586263B", }, + AccountAbstraction: { + rpcUrl: `https://api.stackup.sh/v1/node/${STACKUP_KEY}`, + paymasterUrl: `https://api.stackup.sh/v1/paymaster/${STACKUP_KEY}`, + }, }; export const ParaSpaceConfigs: Partial< diff --git a/scripts/deployments/steps/10_allAggregators.ts b/scripts/deployments/steps/10_allAggregators.ts index 39469b580..0280a8b39 100644 --- a/scripts/deployments/steps/10_allAggregators.ts +++ b/scripts/deployments/steps/10_allAggregators.ts @@ -11,9 +11,11 @@ import { getAllTokens, getFirstSigner, getPoolAddressesProvider, - getPriceOracle, } from "../../../helpers/contracts-getters"; -import {getEthersSignersAddresses} from "../../../helpers/contracts-helpers"; +import { + getContractAddressInDb, + getEthersSignersAddresses, +} from "../../../helpers/contracts-helpers"; import {GLOBAL_OVERRIDES} from "../../../helpers/hardhat-constants"; import {getParaSpaceConfig, waitForTx} from "../../../helpers/misc-utils"; import { @@ -23,6 +25,7 @@ import { import { ERC20TokenContractId, ERC721TokenContractId, + eContractid, } from "../../../helpers/types"; export const deployNftOracle = async (verify = false) => { @@ -69,7 +72,6 @@ export const step_10 = async (verify = false) => { try { const allTokens = await getAllTokens(); const addressesProvider = await getPoolAddressesProvider(); - const fallbackOracle = await getPriceOracle(); const paraSpaceConfig = getParaSpaceConfig(); const oracleConfig = paraSpaceConfig.Oracle; const chainlinkConfig = paraSpaceConfig.Chainlink; @@ -93,7 +95,7 @@ export const step_10 = async (verify = false) => { addressesProvider.address, tokens, aggregators, - fallbackOracle.address, + (await getContractAddressInDb(eContractid.PriceOracle)) || ZERO_ADDRESS, oracleConfig.BaseCurrency == ZERO_ADDRESS ? oracleConfig.BaseCurrency : allTokens[oracleConfig.BaseCurrency].address, diff --git a/scripts/deployments/steps/24_accountAbstraction.ts b/scripts/deployments/steps/24_accountAbstraction.ts index 46399bdba..e95edad2a 100644 --- a/scripts/deployments/steps/24_accountAbstraction.ts +++ b/scripts/deployments/steps/24_accountAbstraction.ts @@ -1,3 +1,4 @@ +import {ZERO_ADDRESS} from "../../../helpers/constants"; import {deployAccountFactory} from "../../../helpers/contracts-deployments"; import {getParaSpaceConfig, isLocalTestnet} from "../../../helpers/misc-utils"; import {Client} from "userop"; @@ -6,10 +7,14 @@ export const step_24 = async (verify = false) => { const paraSpaceConfig = getParaSpaceConfig(); try { if (!isLocalTestnet()) { - const client = Client.init(paraSpaceConfig.AccountAbstraction.rpcUrl); - - const entryPoint = (await client).entryPoint.address; - await deployAccountFactory(entryPoint, verify); + await deployAccountFactory( + paraSpaceConfig.AccountAbstraction?.rpcUrl + ? ( + await Client.init(paraSpaceConfig.AccountAbstraction.rpcUrl) + ).entryPoint.address + : ZERO_ADDRESS, + verify + ); } } catch (error) { console.error(error); From fc6438d4d2d875369231205bb802b55293f9b9a8 Mon Sep 17 00:00:00 2001 From: GopherJ Date: Tue, 28 Nov 2023 14:39:06 +0800 Subject: [PATCH 07/13] chore: display more contracts' size Signed-off-by: GopherJ --- hardhat.config.ts | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/hardhat.config.ts b/hardhat.config.ts index a5256e544..f85028fb6 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -77,12 +77,7 @@ const hardhatConfig: HardhatUserConfig = { alphaSort: true, runOnCompile: false, disambiguatePaths: false, - except: [ - "Mock*", - "ApeCoinStaking", - "SwapRouter", - "NonfungiblePositionManager", - ], + except: ["Mock*"], strict: true, }, paths: { From df429952577d0605038eb18c7bf0f38753eba68e Mon Sep 17 00:00:00 2001 From: GopherJ Date: Fri, 1 Dec 2023 11:48:12 +0800 Subject: [PATCH 08/13] chore: allow no entrypoint Signed-off-by: GopherJ --- scripts/upgrade/accountAbstraction.ts | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/scripts/upgrade/accountAbstraction.ts b/scripts/upgrade/accountAbstraction.ts index 832bf4b48..a261cbd97 100644 --- a/scripts/upgrade/accountAbstraction.ts +++ b/scripts/upgrade/accountAbstraction.ts @@ -4,17 +4,19 @@ import {getAccountRegistry} from "../../helpers/contracts-getters"; import {dryRunEncodedData} from "../../helpers/contracts-helpers"; import {DRY_RUN, GLOBAL_OVERRIDES} from "../../helpers/hardhat-constants"; import {getParaSpaceConfig, waitForTx} from "../../helpers/misc-utils"; +import {ZERO_ADDRESS} from "../../helpers/constants"; export const upgradeAccountAbstraction = async (verify = false) => { console.time("deploy AccountAbstraction"); const paraSpaceConfig = getParaSpaceConfig(); - const client = Client.init(paraSpaceConfig.AccountAbstraction.rpcUrl); const accountRegistry = await getAccountRegistry(); const account = await deployAccount( - ( - await client - ).entryPoint.address, + paraSpaceConfig.AccountAbstraction?.rpcUrl + ? ( + await Client.init(paraSpaceConfig.AccountAbstraction.rpcUrl) + ).entryPoint.address + : ZERO_ADDRESS, verify ); From 8b1c2ee9bd6e7d56d3e8e7c3bd0fd63145f6020a Mon Sep 17 00:00:00 2001 From: zhoujia6139 Date: Thu, 7 Dec 2023 15:03:34 +0800 Subject: [PATCH 09/13] chore: aUSDC --- .husky/pre-push | 6 ------ helper-hardhat-config.ts | 2 +- helpers/hardhat-constants.ts | 2 +- helpers/init-helpers.ts | 3 ++- helpers/types.ts | 2 ++ market-config/index.ts | 10 +++++++++- market-config/mocks.ts | 2 ++ market-config/rateStrategies.ts | 8 ++++++++ market-config/reservesConfigs.ts | 18 ++++++++++++++++++ market-config/timeLockStrategies.ts | 12 ++++++++++++ scripts/upgrade/ntoken.ts | 6 ++++-- 11 files changed, 59 insertions(+), 12 deletions(-) delete mode 100755 .husky/pre-push diff --git a/.husky/pre-push b/.husky/pre-push deleted file mode 100755 index 4779cffc9..000000000 --- a/.husky/pre-push +++ /dev/null @@ -1,6 +0,0 @@ -#!/usr/bin/env sh -. "$(dirname -- "$0")/_/husky.sh" - -yarn typechain -yarn lint -yarn size diff --git a/helper-hardhat-config.ts b/helper-hardhat-config.ts index c8c8c6806..f6412aeb4 100644 --- a/helper-hardhat-config.ts +++ b/helper-hardhat-config.ts @@ -93,7 +93,7 @@ export const NETWORKS_RPC_URL: iParamsPerNetwork = { [eEthereumNetwork.paraxDev]: L2_RPC_URL || RPC_URL || - `https://nitrorpc-widespread-brown-mosquito-de4v5k1jm5.t.conduit.xyz`, + `https://nitrorpc-compact-lime-moose-5r7g6fkl78.t.conduit.xyz`, [eEthereumNetwork.polygon]: RPC_URL || `https://polygon-mainnet.g.alchemy.com/v2/${ALCHEMY_KEY}`, [eEthereumNetwork.polygonMumbai]: diff --git a/helpers/hardhat-constants.ts b/helpers/hardhat-constants.ts index 93a986c2f..23975bbb7 100644 --- a/helpers/hardhat-constants.ts +++ b/helpers/hardhat-constants.ts @@ -26,7 +26,7 @@ export const SEPOLIA_CHAINID = 11155111; export const FORK_CHAINID = 522; export const MAINNET_CHAINID = 1; export const PARALLEL_CHAINID = 1592; -export const PARAX_DEV_CHAINID = 4009937698923195; +export const PARAX_DEV_CHAINID = 3163830386846714; export const MOONBEAM_CHAINID = 1284; export const MOONBASE_CHAINID = 1287; export const ARBITRUM_ONE_CHAINID = 42161; diff --git a/helpers/init-helpers.ts b/helpers/init-helpers.ts index a8cb6c807..70508561f 100644 --- a/helpers/init-helpers.ts +++ b/helpers/init-helpers.ts @@ -420,7 +420,8 @@ export const initReservesByHelper = async ( variableDebtTokenToUse = stKSMVariableDebtTokenImplementationAddress; } else if ( reserveSymbol === ERC20TokenContractId.aWETH || - reserveSymbol === ERC20TokenContractId.awstETH + reserveSymbol === ERC20TokenContractId.awstETH || + reserveSymbol === ERC20TokenContractId.aUSDC ) { if (!pTokenATokenImplementationAddress) { pTokenATokenImplementationAddress = ( diff --git a/helpers/types.ts b/helpers/types.ts index 7cdf7da7e..015bd4126 100644 --- a/helpers/types.ts +++ b/helpers/types.ts @@ -458,6 +458,7 @@ export interface iAssetBase { DAI: T; WETH: T; USDC: T; + aUSDC: T; USDT: T; FRAX: T; WBTC: T; @@ -591,6 +592,7 @@ export enum ERC20TokenContractId { DAI = "DAI", WETH = "WETH", USDC = "USDC", + aUSDC = "aUSDC", USDT = "USDT", FRAX = "FRAX", WBTC = "WBTC", diff --git a/market-config/index.ts b/market-config/index.ts index f18fda770..e20c29968 100644 --- a/market-config/index.ts +++ b/market-config/index.ts @@ -78,6 +78,7 @@ import { strategyEXRP, strategyuBAYC, strategyuPPG, + strategyAUSDC, } from "./reservesConfigs"; export const CommonConfig: Pick< @@ -667,9 +668,15 @@ export const ParaxDevConfig: IParaSpaceConfiguration = { ...CommonConfig, ParaSpaceTeam: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", Treasury: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", + ParaSpaceAdmin: "0x28abAC3E3F1fbC8Aa4Ded74C1589026038f889d8", + EmergencyAdmins: ["0x28abAC3E3F1fbC8Aa4Ded74C1589026038f889d8"], + RiskAdmin: "0x28abAC3E3F1fbC8Aa4Ded74C1589026038f889d8", + GatewayAdmin: "0x28abAC3E3F1fbC8Aa4Ded74C1589026038f889d8", YogaLabs: {}, Uniswap: {}, - Tokens: {}, + Tokens: { + aUSDC: "0x259CdA67f5a3836aEBb207b94f0b57f548921631", + }, Marketplace: {}, Chainlink: {}, BendDAO: {}, @@ -694,6 +701,7 @@ export const ParaxDevConfig: IParaSpaceConfiguration = { BLOCKS: strategyBLOCKS, SEWER: strategySEWER, PPG: strategyPudgyPenguins, + aUSDC: strategyAUSDC, }, }; diff --git a/market-config/mocks.ts b/market-config/mocks.ts index 6d4fdc362..19c131648 100644 --- a/market-config/mocks.ts +++ b/market-config/mocks.ts @@ -6,6 +6,7 @@ export const MOCK_CHAINLINK_AGGREGATORS_PRICES = { // ERC20 DAI: parseEther("0.000908578801039414").toString(), USDC: parseEther("0.000915952223931999").toString(), + aUSDC: parseEther("0.000477910115122588").toString(), USDT: parseEther("0.000915952223931999").toString(), FRAX: parseEther("0.000915952223931999").toString(), WETH: parseEther("1").toString(), @@ -72,6 +73,7 @@ export const MOCK_CHAINLINK_AGGREGATORS_USD_PRICES = { // ERC20 DAI: parseUnits("1", 8).toString(), USDC: parseUnits("1", 8).toString(), + aUSDC: parseUnits("1", 8).toString(), USDT: parseUnits("1", 8).toString(), FRAX: parseUnits("1", 8).toString(), WETH: parseUnits("1896", 8).toString(), diff --git a/market-config/rateStrategies.ts b/market-config/rateStrategies.ts index 3d3cc4b67..2c8b2ddaf 100644 --- a/market-config/rateStrategies.ts +++ b/market-config/rateStrategies.ts @@ -17,6 +17,14 @@ export const rateStrategyUSDC: IInterestRateStrategyParams = { variableRateSlope2: utils.parseUnits("0.60", 27).toString(), }; +export const rateStrategyaUSDC: IInterestRateStrategyParams = { + name: "rateStrategyaUSDC", + optimalUsageRatio: utils.parseUnits("0.9", 27).toString(), + baseVariableBorrowRate: utils.parseUnits("0", 27).toString(), + variableRateSlope1: utils.parseUnits("0.04", 27).toString(), + variableRateSlope2: utils.parseUnits("0.60", 27).toString(), +}; + export const rateStrategyUSDT: IInterestRateStrategyParams = { name: "rateStrategyUSDT", optimalUsageRatio: utils.parseUnits("0.9", 27).toString(), diff --git a/market-config/reservesConfigs.ts b/market-config/reservesConfigs.ts index 70c0ea388..e498a748d 100644 --- a/market-config/reservesConfigs.ts +++ b/market-config/reservesConfigs.ts @@ -28,6 +28,7 @@ import { rateStrategyAAVE, rateStrategyAPE, rateStrategyARB, + rateStrategyaUSDC, rateStrategyBAL, rateStrategyBLUR, rateStrategyCRV, @@ -114,6 +115,7 @@ import { timeLockStrategyEXRP, timeLockStrategyuPPG, timeLockStrategyuBAYC, + timeLockStrategyaUSDC, } from "./timeLockStrategies"; export const strategyDAI: IReserveParams = { @@ -148,6 +150,22 @@ export const strategyUSDC: IReserveParams = { supplyCap: "0", }; +export const strategyAUSDC: IReserveParams = { + strategy: rateStrategyaUSDC, + auctionStrategy: auctionStrategyZero, + timeLockStrategy: timeLockStrategyaUSDC, + baseLTVAsCollateral: "8700", + liquidationThreshold: "8900", + liquidationProtocolFeePercentage: "0", + liquidationBonus: "10450", + borrowingEnabled: true, + reserveDecimals: "6", + xTokenImpl: eContractid.PTokenATokenImpl, + reserveFactor: "1000", + borrowCap: "0", + supplyCap: "0", +}; + export const strategyUSDT: IReserveParams = { strategy: rateStrategyUSDT, auctionStrategy: auctionStrategyZero, diff --git a/market-config/timeLockStrategies.ts b/market-config/timeLockStrategies.ts index 14fa32282..fe705e005 100644 --- a/market-config/timeLockStrategies.ts +++ b/market-config/timeLockStrategies.ts @@ -13,6 +13,18 @@ export const timeLockStrategyUSDC: ITimeLockStrategyParams = { period: "86400", }; +export const timeLockStrategyaUSDC: ITimeLockStrategyParams = { + name: "timeLockStrategyaUSDC", + minThreshold: parseUnits("105000", 6).toString(), + midThreshold: parseUnits("400000", 6).toString(), + minWaitTime: "12", + midWaitTime: "7200", + maxWaitTime: "21600", + poolPeriodWaitTime: "600", + poolPeriodLimit: parseUnits("1875000", 6).toString(), + period: "86400", +}; + export const timeLockStrategyUSDT: ITimeLockStrategyParams = { name: "timeLockStrategyUSDT", minThreshold: parseUnits("105000", 6).toString(), diff --git a/scripts/upgrade/ntoken.ts b/scripts/upgrade/ntoken.ts index ba3ca36f6..21713a50b 100644 --- a/scripts/upgrade/ntoken.ts +++ b/scripts/upgrade/ntoken.ts @@ -76,12 +76,14 @@ export const upgradeNToken = async (verify = false) => { continue; } - if (XTOKEN_SYMBOL_UPGRADE_WHITELIST && !XTOKEN_SYMBOL_UPGRADE_WHITELIST.includes(symbol)) { + if ( + XTOKEN_SYMBOL_UPGRADE_WHITELIST && + !XTOKEN_SYMBOL_UPGRADE_WHITELIST.includes(symbol) + ) { console.log(symbol + "not in XTOKEN_SYMBOL_UPGRADE_WHITELIST, skip..."); continue; } - if (xTokenType == XTokenType.NTokenBAYC) { if (!nTokenBAYCImplementationAddress) { console.log("deploy NTokenBAYC implementation"); From 5bf41f0ccb953a02ce852a389c0b892493eb90ee Mon Sep 17 00:00:00 2001 From: GopherJ Date: Fri, 22 Dec 2023 11:01:10 +0800 Subject: [PATCH 10/13] chore: update parax dev urls Signed-off-by: GopherJ --- helper-hardhat-config.ts | 2 +- helpers/hardhat-constants.ts | 6 +++--- helpers/misc-utils.ts | 1 + 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/helper-hardhat-config.ts b/helper-hardhat-config.ts index c8c8c6806..51d2cf966 100644 --- a/helper-hardhat-config.ts +++ b/helper-hardhat-config.ts @@ -93,7 +93,7 @@ export const NETWORKS_RPC_URL: iParamsPerNetwork = { [eEthereumNetwork.paraxDev]: L2_RPC_URL || RPC_URL || - `https://nitrorpc-widespread-brown-mosquito-de4v5k1jm5.t.conduit.xyz`, + `https://rpc-surprised-harlequin-bonobo-fvcy2k9oqh.t.conduit.xyz`, [eEthereumNetwork.polygon]: RPC_URL || `https://polygon-mainnet.g.alchemy.com/v2/${ALCHEMY_KEY}`, [eEthereumNetwork.polygonMumbai]: diff --git a/helpers/hardhat-constants.ts b/helpers/hardhat-constants.ts index 93a986c2f..f3cae37b7 100644 --- a/helpers/hardhat-constants.ts +++ b/helpers/hardhat-constants.ts @@ -26,7 +26,7 @@ export const SEPOLIA_CHAINID = 11155111; export const FORK_CHAINID = 522; export const MAINNET_CHAINID = 1; export const PARALLEL_CHAINID = 1592; -export const PARAX_DEV_CHAINID = 4009937698923195; +export const PARAX_DEV_CHAINID = 2982896226593698; export const MOONBEAM_CHAINID = 1284; export const MOONBASE_CHAINID = 1287; export const ARBITRUM_ONE_CHAINID = 42161; @@ -136,7 +136,7 @@ export const ETHERSCAN_APIS = { arbitrumGoerli: "https://api-goerli.arbiscan.io/api", arbitrumSepolia: "https://api-sepolia.arbiscan.io/api", paraxDev: - "https://explorerl2new-widespread-brown-mosquito-de4v5k1jm5.t.conduit.xyz/api", + "https://explorerl2new-surprised-harlequin-bonobo-fvcy2k9oqh.t.conduit.xyz/api", polygon: "https://api.polygonscan.com/api", matic: "https://api.polygonscan.com/api", polygonMumbai: "https://api-mumbai.polygonscan.com/api", @@ -160,7 +160,7 @@ export const BROWSER_URLS = { polygonZkevm: "https://zkevm.polygonscan.com", polygonZkevmGoerli: "https://testnet-zkevm.polygonscan.com", paraxDev: - "https://explorerl2new-widespread-brown-mosquito-de4v5k1jm5.t.conduit.xyz", + "https://explorerl2new-surprised-harlequin-bonobo-fvcy2k9oqh.t.conduit.xyz", polygon: "https://polygonscan.com", matic: "https://polygonscan.com", polygonMumbai: "https://mumbai.polygonscan.com", diff --git a/helpers/misc-utils.ts b/helpers/misc-utils.ts index 9c1667032..fad421a01 100644 --- a/helpers/misc-utils.ts +++ b/helpers/misc-utils.ts @@ -72,6 +72,7 @@ export const isPublicTestnet = (): boolean => { ].includes(DRE.network.config.chainId!) || [ eEthereumNetwork.goerli, + eEthereumNetwork.sepolia, eEthereumNetwork.arbitrumGoerli, eEthereumNetwork.arbitrumSepolia, eEthereumNetwork.paraxDev, From f759c6dd8c3994bd8e50ecf307ea4ce5fed62549 Mon Sep 17 00:00:00 2001 From: GopherJ Date: Fri, 5 Jan 2024 16:04:28 +0800 Subject: [PATCH 11/13] feat: add neon & parallel Signed-off-by: GopherJ --- hardhat.config.ts | 42 +++++++++++++++++++++--------------- helper-hardhat-config.ts | 7 +++++- helpers/hardhat-constants.ts | 14 +++++++++++- helpers/misc-utils.ts | 22 ++++++++++++++++++- helpers/types.ts | 2 ++ market-config/index.ts | 2 ++ 6 files changed, 69 insertions(+), 20 deletions(-) diff --git a/hardhat.config.ts b/hardhat.config.ts index f85028fb6..112b0d42a 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -30,6 +30,8 @@ import { SEPOLIA_ETHERSCAN_KEY, ARBITRUM_SEPOLIA_ETHERSCAN_KEY, PARAX_DEV_ETHERSCAN_KEY, + NEON_ETHERSCAN_KEY, + PARALLEL_ETHERSCAN_KEY, } from "./helpers/hardhat-constants"; import {accounts} from "./wallets"; import {accounts as evmAccounts} from "./evm-wallets"; @@ -152,13 +154,23 @@ const hardhatConfig: HardhatUserConfig = { allowUnlimitedContractSize: true, timeout: 9000000, }, + hardhat: { + hardfork: HARDFORK, + blockGasLimit: DEFAULT_BLOCK_GAS_LIMIT, + gas: DEFAULT_BLOCK_GAS_LIMIT, + gasPrice: "auto", + chainId: CHAINS_ID[eEthereumNetwork.hardhat], + throwOnTransactionFailures: true, + throwOnCallFailures: true, + accounts, + loggingEnabled: VERBOSE, + forking: buildForkConfig(), + allowUnlimitedContractSize: true, + }, parallel: { url: NETWORKS_RPC_URL[eEthereumNetwork.parallel], chainId: CHAINS_ID[eEthereumNetwork.parallel], - accounts: evmAccounts.map(({privateKey}) => privateKey), - gasPrice: 4e9, - gas: 4e6, - allowUnlimitedContractSize: true, + accounts: DEPLOYER, }, moonbeam: { chainId: CHAINS_ID[eEthereumNetwork.moonbeam], @@ -170,19 +182,6 @@ const hardhatConfig: HardhatUserConfig = { url: NETWORKS_RPC_URL[eEthereumNetwork.moonbase], accounts: DEPLOYER, }, - hardhat: { - hardfork: HARDFORK, - blockGasLimit: DEFAULT_BLOCK_GAS_LIMIT, - gas: DEFAULT_BLOCK_GAS_LIMIT, - gasPrice: "auto", - chainId: CHAINS_ID[eEthereumNetwork.hardhat], - throwOnTransactionFailures: true, - throwOnCallFailures: true, - accounts, - loggingEnabled: VERBOSE, - forking: buildForkConfig(), - allowUnlimitedContractSize: true, - }, goerli: { chainId: CHAINS_ID[eEthereumNetwork.goerli], url: NETWORKS_RPC_URL[eEthereumNetwork.goerli], @@ -259,6 +258,11 @@ const hardhatConfig: HardhatUserConfig = { url: NETWORKS_RPC_URL[eEthereumNetwork.lineaGoerli], accounts: DEPLOYER, }, + neon: { + chainId: CHAINS_ID[eEthereumNetwork.neon], + url: NETWORKS_RPC_URL[eEthereumNetwork.neon], + accounts: DEPLOYER, + }, mainnet: { chainId: CHAINS_ID[eEthereumNetwork.mainnet], url: NETWORKS_RPC_URL[eEthereumNetwork.mainnet], @@ -283,6 +287,8 @@ const hardhatConfig: HardhatUserConfig = { moonbase: MOONBASE_ETHERSCAN_KEY, linea: LINEA_ETHERSCAN_KEY, lineaGoerli: LINEA_GOERLI_ETHERSCAN_KEY, + neon: NEON_ETHERSCAN_KEY, + parallel: PARALLEL_ETHERSCAN_KEY, }, customChains: [ eEthereumNetwork.localhost, @@ -302,6 +308,8 @@ const hardhatConfig: HardhatUserConfig = { eEthereumNetwork.moonbase, eEthereumNetwork.linea, eEthereumNetwork.lineaGoerli, + eEthereumNetwork.neon, + eEthereumNetwork.parallel, ].map((network) => ({ network, chainId: CHAINS_ID[network]!, diff --git a/helper-hardhat-config.ts b/helper-hardhat-config.ts index 51d2cf966..a9cc60d28 100644 --- a/helper-hardhat-config.ts +++ b/helper-hardhat-config.ts @@ -30,6 +30,7 @@ import { ZKSYNC_GOERLI_CHAINID, ARBITRUM_SEPOLIA_CHAINID, PARAX_DEV_CHAINID, + NEON_CHAINID, } from "./helpers/hardhat-constants"; dotenv.config(); @@ -75,7 +76,7 @@ export const NETWORKS_RPC_URL: iParamsPerNetwork = { [eEthereumNetwork.ganache]: RPC_URL || "http://localhost:8545", [eEthereumNetwork.tenderlyMain]: RPC_URL || `https://rpc.tenderly.co/fork/${TENDERLY_FORK_ID}`, - [eEthereumNetwork.parallel]: RPC_URL || "http://localhost:29933", + [eEthereumNetwork.parallel]: RPC_URL || "https://rpc.parallel.fi", [eEthereumNetwork.moonbeam]: "https://rpc.api.moonbeam.network", [eEthereumNetwork.moonbase]: "https://rpc.testnet.moonbeam.network", [eEthereumNetwork.arbitrum]: @@ -122,6 +123,8 @@ export const NETWORKS_RPC_URL: iParamsPerNetwork = { (INFURA_KEY ? `https://linea-goerli.infura.io/v3/${INFURA_KEY}` : `https://rpc.goerli.linea.build`), + [eEthereumNetwork.neon]: + RPC_URL || `https://neon-proxy-mainnet.solana.p2p.org`, }; export const CHAINS_ID: iParamsPerNetwork = { @@ -147,6 +150,7 @@ export const CHAINS_ID: iParamsPerNetwork = { [eEthereumNetwork.zksyncGoerli]: ZKSYNC_GOERLI_CHAINID, [eEthereumNetwork.linea]: LINEA_CHAINID, [eEthereumNetwork.lineaGoerli]: LINEA_GOERLI_CHAINID, + [eEthereumNetwork.neon]: NEON_CHAINID, }; export const BLOCK_TO_FORK: iParamsPerNetwork = { @@ -172,4 +176,5 @@ export const BLOCK_TO_FORK: iParamsPerNetwork = { [eEthereumNetwork.zksyncGoerli]: undefined, [eEthereumNetwork.linea]: undefined, [eEthereumNetwork.lineaGoerli]: undefined, + [eEthereumNetwork.neon]: undefined, }; diff --git a/helpers/hardhat-constants.ts b/helpers/hardhat-constants.ts index f3cae37b7..b6efcc530 100644 --- a/helpers/hardhat-constants.ts +++ b/helpers/hardhat-constants.ts @@ -25,7 +25,7 @@ export const GOERLI_CHAINID = 5; export const SEPOLIA_CHAINID = 11155111; export const FORK_CHAINID = 522; export const MAINNET_CHAINID = 1; -export const PARALLEL_CHAINID = 1592; +export const PARALLEL_CHAINID = 1024; export const PARAX_DEV_CHAINID = 2982896226593698; export const MOONBEAM_CHAINID = 1284; export const MOONBASE_CHAINID = 1287; @@ -40,6 +40,7 @@ export const ZKSYNC_CHAINID = 324; export const ZKSYNC_GOERLI_CHAINID = 280; export const LINEA_GOERLI_CHAINID = 59140; export const LINEA_CHAINID = 59144; +export const NEON_CHAINID = 245022934; export const INFURA_KEY = process.env.INFURA_KEY || ""; export const ALCHEMY_KEY = process.env.ALCHEMY_KEY || ""; @@ -108,6 +109,11 @@ export const ETHERSCAN_VERIFICATION_JOBS = parseInt( export const ETHERSCAN_VERIFICATION_MAX_RETRIES = parseInt( process.env.ETHERSCAN_VERIFICATION_MAX_RETRIES || "3" ); +export const NEON_ETHERSCAN_KEY = + process.env.NEON_ETHERSCAN_KEY || ETHERSCAN_KEY; +export const PARALLEL_ETHERSCAN_KEY = + process.env.PARALLEL_ETHERSCAN_KEY || ETHERSCAN_KEY; + export const ETHERSCAN_NETWORKS = [ "localhost", "mainnet", @@ -127,6 +133,8 @@ export const ETHERSCAN_NETWORKS = [ "lineaGoerli", "moonbeam", "moonbase", + "neon", + "parallel", ]; export const ETHERSCAN_APIS = { localhost: "http://localhost:4000/api", @@ -149,6 +157,8 @@ export const ETHERSCAN_APIS = { moonbase: "https://api-moonbase.moonscan.io/api", linea: "http://explorer.linea.build/api", lineaGoerli: "https://explorer.goerli.linea.build/api", + neon: "https://neonscan.org/api", + parallel: "https://explorer.parallel.fi/api", }; export const BROWSER_URLS = { localhost: "http://localhost:4000", @@ -170,6 +180,8 @@ export const BROWSER_URLS = { moonbase: "https://moonbase.moonscan.io", linea: "https://explorer.linea.build", lineaGoerli: "https://explorer.goerli.linea.build", + neon: "https://neonscan.org", + parallel: "https://explorer.parallel.fi", }; export const DEPLOY_START = parseInt(process.env.DEPLOY_START || "0"); diff --git a/helpers/misc-utils.ts b/helpers/misc-utils.ts index fad421a01..fa0d3e2d9 100644 --- a/helpers/misc-utils.ts +++ b/helpers/misc-utils.ts @@ -31,6 +31,8 @@ import { SEPOLIA_CHAINID, ARBITRUM_SEPOLIA_CHAINID, PARAX_DEV_CHAINID, + NEON_CHAINID, + PARALLEL_CHAINID, } from "./hardhat-constants"; import {ConstructorArgs, eContractid, tEthereumAddress} from "./types"; import dotenv from "dotenv"; @@ -146,6 +148,22 @@ export const isLinea = (): boolean => { ); }; +export const isNeon = (): boolean => { + // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + return ( + [NEON_CHAINID].includes(DRE.network.config.chainId!) || + [eEthereumNetwork.neon].includes(FORK as eEthereumNetwork) + ); +}; + +export const isParallel = (): boolean => { + // eslint-disable-next-line @typescript-eslint/no-non-null-assertion + return ( + [PARALLEL_CHAINID].includes(DRE.network.config.chainId!) || + [eEthereumNetwork.parallel].includes(FORK as eEthereumNetwork) + ); +}; + export const isMainnet = (): boolean => isEthereum() || isMoonbeam() || @@ -153,7 +171,9 @@ export const isMainnet = (): boolean => isZkSync() || isPolygon() || isPolygonZkEVM() || - isLinea(); + isLinea() || + isNeon() || + isParallel(); export const safeTransactionServiceUrl = (): string => { return isMoonbeam() diff --git a/helpers/types.ts b/helpers/types.ts index 015bd4126..8eea650db 100644 --- a/helpers/types.ts +++ b/helpers/types.ts @@ -106,6 +106,7 @@ export enum eEthereumNetwork { zksyncGoerli = "zksyncGoerli", linea = "linea", lineaGoerli = "lineaGoerli", + neon = "neon", } export enum eContractid { @@ -771,6 +772,7 @@ export interface iEthereumParamsPerNetwork { [eEthereumNetwork.zksyncGoerli]: T; [eEthereumNetwork.linea]: T; [eEthereumNetwork.lineaGoerli]: T; + [eEthereumNetwork.neon]: T; } export enum RateMode { diff --git a/market-config/index.ts b/market-config/index.ts index e20c29968..58de81e47 100644 --- a/market-config/index.ts +++ b/market-config/index.ts @@ -1111,4 +1111,6 @@ export const ParaSpaceConfigs: Partial< [eEthereumNetwork.zksyncGoerli]: ZkSyncGoerliConfig, [eEthereumNetwork.linea]: LineaConfig, [eEthereumNetwork.lineaGoerli]: LineaGoerliConfig, + [eEthereumNetwork.parallel]: HardhatConfig, + [eEthereumNetwork.neon]: HardhatConfig, }; From 15c3ebd2acb7e9536b86a5ce5905edb9c104dabd Mon Sep 17 00:00:00 2001 From: GopherJ Date: Fri, 5 Jan 2024 16:10:02 +0800 Subject: [PATCH 12/13] fix: parax dev Signed-off-by: GopherJ --- hardhat.config.ts | 13 ++++++------- helper-hardhat-config.ts | 8 ++++---- helpers/hardhat-constants.ts | 12 ++++++------ helpers/misc-utils.ts | 6 +++--- helpers/types.ts | 4 ++-- market-config/index.ts | 2 +- 6 files changed, 22 insertions(+), 23 deletions(-) diff --git a/hardhat.config.ts b/hardhat.config.ts index 112b0d42a..310611deb 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -29,12 +29,11 @@ import { LINEA_GOERLI_ETHERSCAN_KEY, SEPOLIA_ETHERSCAN_KEY, ARBITRUM_SEPOLIA_ETHERSCAN_KEY, - PARAX_DEV_ETHERSCAN_KEY, + PARALLEL_DEV_ETHERSCAN_KEY, NEON_ETHERSCAN_KEY, PARALLEL_ETHERSCAN_KEY, } from "./helpers/hardhat-constants"; import {accounts} from "./wallets"; -import {accounts as evmAccounts} from "./evm-wallets"; import { buildForkConfig, CHAINS_ID, @@ -207,9 +206,9 @@ const hardhatConfig: HardhatUserConfig = { url: NETWORKS_RPC_URL[eEthereumNetwork.arbitrumSepolia], accounts: DEPLOYER, }, - paraxDev: { - chainId: CHAINS_ID[eEthereumNetwork.paraxDev], - url: NETWORKS_RPC_URL[eEthereumNetwork.paraxDev], + parallelDev: { + chainId: CHAINS_ID[eEthereumNetwork.parallelDev], + url: NETWORKS_RPC_URL[eEthereumNetwork.parallelDev], accounts: DEPLOYER, }, polygon: { @@ -278,7 +277,7 @@ const hardhatConfig: HardhatUserConfig = { arbitrum: ARBITRUM_ETHERSCAN_KEY, arbitrumGoerli: ARBITRUM_GOERLI_ETHERSCAN_KEY, arbitrumSepolia: ARBITRUM_SEPOLIA_ETHERSCAN_KEY, - paraxDev: PARAX_DEV_ETHERSCAN_KEY, + parallelDev: PARALLEL_DEV_ETHERSCAN_KEY, polygon: POLYGON_ETHERSCAN_KEY, polygonMumbai: POLYGON_MUMBAI_ETHERSCAN_KEY, polygonZkevm: POLYGON_ZKEVM_ETHERSCAN_KEY, @@ -297,7 +296,7 @@ const hardhatConfig: HardhatUserConfig = { eEthereumNetwork.arbitrum, eEthereumNetwork.arbitrumGoerli, eEthereumNetwork.arbitrumSepolia, - eEthereumNetwork.paraxDev, + eEthereumNetwork.parallelDev, eEthereumNetwork.polygon, eEthereumNetwork.polygonZkevm, eEthereumNetwork.polygonMumbai, diff --git a/helper-hardhat-config.ts b/helper-hardhat-config.ts index a9cc60d28..c4c30ff8e 100644 --- a/helper-hardhat-config.ts +++ b/helper-hardhat-config.ts @@ -29,7 +29,7 @@ import { ZKSYNC_CHAINID, ZKSYNC_GOERLI_CHAINID, ARBITRUM_SEPOLIA_CHAINID, - PARAX_DEV_CHAINID, + PARALLEL_DEV_CHAINID, NEON_CHAINID, } from "./helpers/hardhat-constants"; @@ -91,7 +91,7 @@ export const NETWORKS_RPC_URL: iParamsPerNetwork = { L2_RPC_URL || RPC_URL || `https://arb-sepolia.g.alchemy.com/v2/${ALCHEMY_KEY}`, - [eEthereumNetwork.paraxDev]: + [eEthereumNetwork.parallelDev]: L2_RPC_URL || RPC_URL || `https://rpc-surprised-harlequin-bonobo-fvcy2k9oqh.t.conduit.xyz`, @@ -141,7 +141,7 @@ export const CHAINS_ID: iParamsPerNetwork = { [eEthereumNetwork.arbitrum]: ARBITRUM_ONE_CHAINID, [eEthereumNetwork.arbitrumGoerli]: ARBITRUM_GOERLI_CHAINID, [eEthereumNetwork.arbitrumSepolia]: ARBITRUM_SEPOLIA_CHAINID, - [eEthereumNetwork.paraxDev]: PARAX_DEV_CHAINID, + [eEthereumNetwork.parallelDev]: PARALLEL_DEV_CHAINID, [eEthereumNetwork.polygon]: POLYGON_CHAINID, [eEthereumNetwork.polygonMumbai]: POLYGON_MUMBAI_CHAINID, [eEthereumNetwork.polygonZkevm]: POLYGON_ZKEVM_CHAINID, @@ -167,7 +167,7 @@ export const BLOCK_TO_FORK: iParamsPerNetwork = { [eEthereumNetwork.arbitrum]: undefined, [eEthereumNetwork.arbitrumGoerli]: undefined, [eEthereumNetwork.arbitrumSepolia]: undefined, - [eEthereumNetwork.paraxDev]: undefined, + [eEthereumNetwork.parallelDev]: undefined, [eEthereumNetwork.polygon]: undefined, [eEthereumNetwork.polygonMumbai]: undefined, [eEthereumNetwork.polygonZkevm]: undefined, diff --git a/helpers/hardhat-constants.ts b/helpers/hardhat-constants.ts index b6efcc530..ca2df4817 100644 --- a/helpers/hardhat-constants.ts +++ b/helpers/hardhat-constants.ts @@ -26,7 +26,7 @@ export const SEPOLIA_CHAINID = 11155111; export const FORK_CHAINID = 522; export const MAINNET_CHAINID = 1; export const PARALLEL_CHAINID = 1024; -export const PARAX_DEV_CHAINID = 2982896226593698; +export const PARALLEL_DEV_CHAINID = 2982896226593698; export const MOONBEAM_CHAINID = 1284; export const MOONBASE_CHAINID = 1287; export const ARBITRUM_ONE_CHAINID = 42161; @@ -79,8 +79,8 @@ export const ARBITRUM_GOERLI_ETHERSCAN_KEY = process.env.ARBITRUM_GOERLI_ETHERSCAN_KEY || ARBITRUM_ETHERSCAN_KEY; export const ARBITRUM_SEPOLIA_ETHERSCAN_KEY = process.env.ARBITRUM_SEPOLIA_ETHERSCAN_KEY || ARBITRUM_ETHERSCAN_KEY; -export const PARAX_DEV_ETHERSCAN_KEY = - process.env.PARAX_DEV_ETHERSCAN_KEY || ETHERSCAN_KEY; +export const PARALLEL_DEV_ETHERSCAN_KEY = + process.env.PARALLEL_DEV_ETHERSCAN_KEY || ETHERSCAN_KEY; export const POLYGON_ETHERSCAN_KEY = process.env.POLYGON_ETHERSCAN_KEY || ETHERSCAN_KEY; export const POLYGON_MUMBAI_ETHERSCAN_KEY = @@ -121,7 +121,7 @@ export const ETHERSCAN_NETWORKS = [ "arbitrum", "arbitrumGoerli", "arbitrumSepolia", - "paraxDev", + "parallelDev", "polygon", "matic", "polygonMumbai", @@ -143,7 +143,7 @@ export const ETHERSCAN_APIS = { arbitrum: "https://api.arbiscan.io/api", arbitrumGoerli: "https://api-goerli.arbiscan.io/api", arbitrumSepolia: "https://api-sepolia.arbiscan.io/api", - paraxDev: + parallelDev: "https://explorerl2new-surprised-harlequin-bonobo-fvcy2k9oqh.t.conduit.xyz/api", polygon: "https://api.polygonscan.com/api", matic: "https://api.polygonscan.com/api", @@ -169,7 +169,7 @@ export const BROWSER_URLS = { arbitrumSepolia: "https://sepolia.arbiscan.io", polygonZkevm: "https://zkevm.polygonscan.com", polygonZkevmGoerli: "https://testnet-zkevm.polygonscan.com", - paraxDev: + parallelDev: "https://explorerl2new-surprised-harlequin-bonobo-fvcy2k9oqh.t.conduit.xyz", polygon: "https://polygonscan.com", matic: "https://polygonscan.com", diff --git a/helpers/misc-utils.ts b/helpers/misc-utils.ts index fa0d3e2d9..b8a41a6f4 100644 --- a/helpers/misc-utils.ts +++ b/helpers/misc-utils.ts @@ -30,7 +30,7 @@ import { LINEA_GOERLI_CHAINID, SEPOLIA_CHAINID, ARBITRUM_SEPOLIA_CHAINID, - PARAX_DEV_CHAINID, + PARALLEL_DEV_CHAINID, NEON_CHAINID, PARALLEL_CHAINID, } from "./hardhat-constants"; @@ -65,7 +65,7 @@ export const isPublicTestnet = (): boolean => { SEPOLIA_CHAINID, ARBITRUM_GOERLI_CHAINID, ARBITRUM_SEPOLIA_CHAINID, - PARAX_DEV_CHAINID, + PARALLEL_DEV_CHAINID, ZKSYNC_GOERLI_CHAINID, POLYGON_ZKEVM_GOERLI_CHAINID, POLYGON_MUMBAI_CHAINID, @@ -77,7 +77,7 @@ export const isPublicTestnet = (): boolean => { eEthereumNetwork.sepolia, eEthereumNetwork.arbitrumGoerli, eEthereumNetwork.arbitrumSepolia, - eEthereumNetwork.paraxDev, + eEthereumNetwork.parallelDev, eEthereumNetwork.zksyncGoerli, eEthereumNetwork.polygonZkevmGoerli, eEthereumNetwork.polygonMumbai, diff --git a/helpers/types.ts b/helpers/types.ts index 8eea650db..01a7a4ea2 100644 --- a/helpers/types.ts +++ b/helpers/types.ts @@ -97,7 +97,7 @@ export enum eEthereumNetwork { arbitrum = "arbitrum", arbitrumGoerli = "arbitrumGoerli", arbitrumSepolia = "arbitrumSepolia", - paraxDev = "paraxDev", + parallelDev = "parallelDev", polygon = "polygon", polygonMumbai = "polygonMumbai", polygonZkevm = "polygonZkevm", @@ -763,7 +763,7 @@ export interface iEthereumParamsPerNetwork { [eEthereumNetwork.arbitrum]: T; [eEthereumNetwork.arbitrumGoerli]: T; [eEthereumNetwork.arbitrumSepolia]: T; - [eEthereumNetwork.paraxDev]: T; + [eEthereumNetwork.parallelDev]: T; [eEthereumNetwork.polygon]: T; [eEthereumNetwork.polygonMumbai]: T; [eEthereumNetwork.polygonZkevm]: T; diff --git a/market-config/index.ts b/market-config/index.ts index 58de81e47..4f549269f 100644 --- a/market-config/index.ts +++ b/market-config/index.ts @@ -1101,7 +1101,7 @@ export const ParaSpaceConfigs: Partial< [eEthereumNetwork.mainnet]: MainnetConfig, [eEthereumNetwork.arbitrumGoerli]: ArbitrumGoerliConfig, [eEthereumNetwork.arbitrumSepolia]: ArbitrumSepoliaConfig, - [eEthereumNetwork.paraxDev]: ParaxDevConfig, + [eEthereumNetwork.parallelDev]: ParaxDevConfig, [eEthereumNetwork.arbitrum]: ArbitrumConfig, [eEthereumNetwork.polygon]: PolygonConfig, [eEthereumNetwork.polygonMumbai]: PolygonMumbaiConfig, From 6ed990b26d1c51d3c9853c60478d3b57d8c7a244 Mon Sep 17 00:00:00 2001 From: GopherJ Date: Fri, 5 Jan 2024 16:15:38 +0800 Subject: [PATCH 13/13] fix: config Signed-off-by: GopherJ --- market-config/index.ts | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/market-config/index.ts b/market-config/index.ts index 4f549269f..aebe7f02b 100644 --- a/market-config/index.ts +++ b/market-config/index.ts @@ -663,20 +663,14 @@ export const ArbitrumSepoliaConfig: IParaSpaceConfiguration = { PPG: strategyPudgyPenguins, }, }; -export const ParaxDevConfig: IParaSpaceConfiguration = { +export const ParallelDevConfig: IParaSpaceConfiguration = { // BASIC INFO ...CommonConfig, ParaSpaceTeam: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", Treasury: "0x018281853eCC543Aa251732e8FDaa7323247eBeB", - ParaSpaceAdmin: "0x28abAC3E3F1fbC8Aa4Ded74C1589026038f889d8", - EmergencyAdmins: ["0x28abAC3E3F1fbC8Aa4Ded74C1589026038f889d8"], - RiskAdmin: "0x28abAC3E3F1fbC8Aa4Ded74C1589026038f889d8", - GatewayAdmin: "0x28abAC3E3F1fbC8Aa4Ded74C1589026038f889d8", YogaLabs: {}, Uniswap: {}, - Tokens: { - aUSDC: "0x259CdA67f5a3836aEBb207b94f0b57f548921631", - }, + Tokens: {}, Marketplace: {}, Chainlink: {}, BendDAO: {}, @@ -701,7 +695,6 @@ export const ParaxDevConfig: IParaSpaceConfiguration = { BLOCKS: strategyBLOCKS, SEWER: strategySEWER, PPG: strategyPudgyPenguins, - aUSDC: strategyAUSDC, }, }; @@ -1101,7 +1094,7 @@ export const ParaSpaceConfigs: Partial< [eEthereumNetwork.mainnet]: MainnetConfig, [eEthereumNetwork.arbitrumGoerli]: ArbitrumGoerliConfig, [eEthereumNetwork.arbitrumSepolia]: ArbitrumSepoliaConfig, - [eEthereumNetwork.parallelDev]: ParaxDevConfig, + [eEthereumNetwork.parallelDev]: ParallelDevConfig, [eEthereumNetwork.arbitrum]: ArbitrumConfig, [eEthereumNetwork.polygon]: PolygonConfig, [eEthereumNetwork.polygonMumbai]: PolygonMumbaiConfig,