chore: Revert "feat: Add Zerion config generator (#4870)" (#4880)

This reverts commit 250853eff4 until
decent finalizes development.
main
Lee 1 day ago committed by GitHub
parent 63b912b272
commit 3ce70725ee
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 6
      .changeset/metal-clocks-count.md
  2. 31
      typescript/infra/config/environments/mainnet3/warp/configGetters/getBlastZeroNetworkUSDBWarpConfig.ts
  3. 28
      typescript/infra/config/environments/mainnet3/warp/configGetters/getBscZeroNetworkBNBConfig.ts
  4. 53
      typescript/infra/config/environments/mainnet3/warp/configGetters/getEthereumModeScrollZeronetworkWBTCConfig.ts
  5. 28
      typescript/infra/config/environments/mainnet3/warp/configGetters/getPolygonZeroNetworkPolConfig.ts
  6. 4
      typescript/infra/config/environments/mainnet3/warp/warpIds.ts
  7. 9
      typescript/infra/config/warp.ts
  8. 3
      typescript/infra/src/config/warp.ts
  9. 6
      typescript/sdk/src/router/HyperlaneRouterChecker.ts

@ -1,6 +0,0 @@
---
'@hyperlane-xyz/infra': minor
'@hyperlane-xyz/sdk': minor
---
Add Zerion deployments: WBTC, POL, BNB, USDB

@ -1,31 +0,0 @@
import { ethers } from 'ethers';
import {
ChainMap,
RouterConfig,
TokenRouterConfig,
TokenType,
} from '@hyperlane-xyz/sdk';
import { tokens } from '../../../../../src/config/warp.js';
export const getBlastZeroNetworkUSDBWarpConfig = async (
routerConfig: ChainMap<RouterConfig>,
): Promise<ChainMap<TokenRouterConfig>> => {
const blast: TokenRouterConfig = {
...routerConfig.blast,
type: TokenType.collateral,
token: tokens.blast.usdb,
interchainSecurityModule: ethers.constants.AddressZero,
};
const zeronetwork: TokenRouterConfig = {
...routerConfig.zeronetwork,
type: TokenType.synthetic,
interchainSecurityModule: ethers.constants.AddressZero,
};
return {
blast,
zeronetwork,
};
};

@ -1,28 +0,0 @@
import { ethers } from 'ethers';
import {
ChainMap,
RouterConfig,
TokenRouterConfig,
TokenType,
} from '@hyperlane-xyz/sdk';
export const getBscZeroNetworkBNBWarpConfig = async (
routerConfig: ChainMap<RouterConfig>,
): Promise<ChainMap<TokenRouterConfig>> => {
const bsc: TokenRouterConfig = {
...routerConfig.bsc,
type: TokenType.native,
interchainSecurityModule: ethers.constants.AddressZero,
};
const zeronetwork: TokenRouterConfig = {
...routerConfig.zeronetwork,
type: TokenType.synthetic,
interchainSecurityModule: ethers.constants.AddressZero,
};
return {
bsc,
zeronetwork,
};
};

@ -1,53 +0,0 @@
import { ethers } from 'ethers';
import {
ChainMap,
RouterConfig,
TokenRouterConfig,
TokenType,
} from '@hyperlane-xyz/sdk';
import { Address } from '@hyperlane-xyz/utils';
const collateralAddresses: ChainMap<Address> = {
ethereum: '0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599',
mode: '0xcDd475325D6F564d27247D1DddBb0DAc6fA0a5CF',
scroll: '0x3C1BCa5a656e69edCD0D4E36BEbb3FcDAcA60Cf1',
};
export const getEthereumModeScrollZeronetworkWBTCConfig = async (
routerConfig: ChainMap<RouterConfig>,
): Promise<ChainMap<TokenRouterConfig>> => {
const ethereum: TokenRouterConfig = {
...routerConfig.ethereum,
type: TokenType.collateral,
token: collateralAddresses.ethereum,
interchainSecurityModule: ethers.constants.AddressZero,
};
const mode: TokenRouterConfig = {
...routerConfig.mode,
type: TokenType.collateral,
token: collateralAddresses.mode,
interchainSecurityModule: ethers.constants.AddressZero,
};
const scroll: TokenRouterConfig = {
...routerConfig.scroll,
type: TokenType.collateral,
token: collateralAddresses.scroll,
interchainSecurityModule: ethers.constants.AddressZero,
};
const zeronetwork: TokenRouterConfig = {
...routerConfig.zeronetwork,
type: TokenType.synthetic,
interchainSecurityModule: ethers.constants.AddressZero,
};
return {
ethereum,
mode,
scroll,
zeronetwork,
};
};

@ -1,28 +0,0 @@
import { ethers } from 'ethers';
import {
ChainMap,
RouterConfig,
TokenRouterConfig,
TokenType,
} from '@hyperlane-xyz/sdk';
export const getPolygonZeroNetworkPolWarpConfig = async (
routerConfig: ChainMap<RouterConfig>,
): Promise<ChainMap<TokenRouterConfig>> => {
const polygon: TokenRouterConfig = {
...routerConfig.polygon,
type: TokenType.native,
interchainSecurityModule: ethers.constants.AddressZero,
};
const zeronetwork: TokenRouterConfig = {
...routerConfig.zeronetwork,
type: TokenType.synthetic,
interchainSecurityModule: ethers.constants.AddressZero,
};
return {
polygon,
zeronetwork,
};
};

@ -5,8 +5,6 @@ export enum WarpRouteIds {
ArbitrumEthereumZircuitAMPHRETH = 'AMPHRETH/arbitrum-ethereum-zircuit',
ArbitrumNeutronEclip = 'ECLIP/arbitrum-neutron',
ArbitrumNeutronTIA = 'TIA/arbitrum-neutron',
BlastZeroNetworkUSDB = 'USDB/blast-zeronetwork',
BscZeroNetworkBNB = 'BNB/bsc-zeronetwork',
EclipseEthereumSolanaUSDC = 'USDC/eclipsemainnet-ethereum-solanamainnet',
EclipseEthereumSolanaUSDT = 'USDT/eclipsemainnet-ethereum-solanamainnet',
EclipseEthereumTETH = 'tETH/eclipsemainnet-ethereum',
@ -25,8 +23,6 @@ export enum WarpRouteIds {
EthereumVictionUSDT = 'USDT/ethereum-viction',
EthereumZircuitPZETH = 'PZETH/ethereum-zircuit',
EthereumBscLumiaLUMIA = 'LUMIA/bsc-ethereum-lumia',
EthereumModeScrollZeroNetworkWBTC = 'WBTC/ethereum-mode-scroll-zeronetwork',
InevmInjectiveINJ = 'INJ/inevm-injective',
MantapacificNeutronTIA = 'TIA/mantapacific-neutron',
PolygonZeroNetworkPOL = 'POL/polygon-zeronetwork',
}

@ -15,8 +15,6 @@ import { getAncient8EthereumUSDCWarpConfig } from './environments/mainnet3/warp/
import { getArbitrumEthereumZircuitAmphrETHWarpConfig } from './environments/mainnet3/warp/configGetters/getArbitrumEthereumZircuitAmphrETHWarpConfig.js';
import { getArbitrumNeutronEclipWarpConfig } from './environments/mainnet3/warp/configGetters/getArbitrumNeutronEclipWarpConfig.js';
import { getArbitrumNeutronTiaWarpConfig } from './environments/mainnet3/warp/configGetters/getArbitrumNeutronTiaWarpConfig.js';
import { getBlastZeroNetworkUSDBWarpConfig } from './environments/mainnet3/warp/configGetters/getBlastZeroNetworkUSDBWarpConfig.js';
import { getBscZeroNetworkBNBWarpConfig } from './environments/mainnet3/warp/configGetters/getBscZeroNetworkBNBConfig.js';
import { getEclipseEthereumSolanaUSDTWarpConfig } from './environments/mainnet3/warp/configGetters/getEclipseEthereumSolanaUSDTWarpConfig.js';
import { getEclipseEthereumWBTCWarpConfig } from './environments/mainnet3/warp/configGetters/getEclipseEthereumWBTCWarpConfig.js';
import { getEclipseEthereumWeEthsWarpConfig } from './environments/mainnet3/warp/configGetters/getEclipseEthereumWeETHsWarpConfig.js';
@ -25,14 +23,12 @@ import { getEclipseStrideStTiaWarpConfig } from './environments/mainnet3/warp/co
import { getEthereumBscLUMIAWarpConfig } from './environments/mainnet3/warp/configGetters/getEthereumBscLumiaLUMIAWarpConfig.js';
import { getEthereumInevmUSDCWarpConfig } from './environments/mainnet3/warp/configGetters/getEthereumInevmUSDCWarpConfig.js';
import { getEthereumInevmUSDTWarpConfig } from './environments/mainnet3/warp/configGetters/getEthereumInevmUSDTWarpConfig.js';
import { getEthereumModeScrollZeronetworkWBTCConfig } from './environments/mainnet3/warp/configGetters/getEthereumModeScrollZeronetworkWBTCConfig.js';
import { getEthereumSeiFastUSDWarpConfig } from './environments/mainnet3/warp/configGetters/getEthereumSeiFastUSDWarpConfig.js';
import { getEthereumVictionETHWarpConfig } from './environments/mainnet3/warp/configGetters/getEthereumVictionETHWarpConfig.js';
import { getEthereumVictionUSDCWarpConfig } from './environments/mainnet3/warp/configGetters/getEthereumVictionUSDCWarpConfig.js';
import { getEthereumVictionUSDTWarpConfig } from './environments/mainnet3/warp/configGetters/getEthereumVictionUSDTWarpConfig.js';
import { getInevmInjectiveINJWarpConfig } from './environments/mainnet3/warp/configGetters/getInevmInjectiveINJWarpConfig.js';
import { getMantapacificNeutronTiaWarpConfig } from './environments/mainnet3/warp/configGetters/getMantapacificNeutronTiaWarpConfig.js';
import { getPolygonZeroNetworkPolWarpConfig } from './environments/mainnet3/warp/configGetters/getPolygonZeroNetworkPolConfig.js';
import { getRenzoEZETHWarpConfig } from './environments/mainnet3/warp/configGetters/getRenzoEZETHWarpConfig.js';
import { getRenzoPZETHWarpConfig } from './environments/mainnet3/warp/configGetters/getRenzoPZETHWarpConfig.js';
import { WarpRouteIds } from './environments/mainnet3/warp/warpIds.js';
@ -56,8 +52,6 @@ export const warpConfigGetterMap: Record<
[WarpRouteIds.ArbitrumNeutronTIA]: getArbitrumNeutronTiaWarpConfig,
[WarpRouteIds.ArbitrumBaseBlastBscEthereumFraxtalLineaModeOptimismSeiTaikoZircuitEZETH]:
getRenzoEZETHWarpConfig,
[WarpRouteIds.BlastZeroNetworkUSDB]: getBlastZeroNetworkUSDBWarpConfig,
[WarpRouteIds.BscZeroNetworkBNB]: getBscZeroNetworkBNBWarpConfig,
[WarpRouteIds.InevmInjectiveINJ]: getInevmInjectiveINJWarpConfig,
[WarpRouteIds.EthereumSeiFastUSD]: getEthereumSeiFastUSDWarpConfig,
[WarpRouteIds.EthereumVictionETH]: getEthereumVictionETHWarpConfig,
@ -65,8 +59,6 @@ export const warpConfigGetterMap: Record<
[WarpRouteIds.EthereumVictionUSDT]: getEthereumVictionUSDTWarpConfig,
[WarpRouteIds.EthereumZircuitPZETH]: getRenzoPZETHWarpConfig,
[WarpRouteIds.EthereumBscLumiaLUMIA]: getEthereumBscLUMIAWarpConfig,
[WarpRouteIds.EthereumModeScrollZeroNetworkWBTC]:
getEthereumModeScrollZeronetworkWBTCConfig,
[WarpRouteIds.MantapacificNeutronTIA]: getMantapacificNeutronTiaWarpConfig,
[WarpRouteIds.EclipseStrideTIA]: getEclipseStrideTiaWarpConfig,
[WarpRouteIds.EclipseStrideSTTIA]: getEclipseStrideStTiaWarpConfig,
@ -74,7 +66,6 @@ export const warpConfigGetterMap: Record<
getEclipseEthereumSolanaUSDTWarpConfig,
[WarpRouteIds.EclipseEthereumWBTC]: getEclipseEthereumWBTCWarpConfig,
[WarpRouteIds.EclipseEthereumWeETHs]: getEclipseEthereumWeEthsWarpConfig,
[WarpRouteIds.PolygonZeroNetworkPOL]: getPolygonZeroNetworkPolWarpConfig,
};
export async function getWarpConfig(

@ -14,7 +14,4 @@ export const tokens: ChainMap<Record<string, Address>> = {
sei: {
fastUSD: '0x37a4dD9CED2b19Cfe8FAC251cd727b5787E45269',
},
blast: {
usdb: '0x4300000000000000000000000000000000000003',
},
};

@ -5,7 +5,6 @@ import {
addressToBytes32,
assert,
eqAddress,
isZeroishAddress,
rootLogger,
} from '@hyperlane-xyz/utils';
@ -105,10 +104,7 @@ export class HyperlaneRouterChecker<
let expectedConfig = config.interchainSecurityModule;
if (
typeof expectedConfig === 'string' &&
!isZeroishAddress(expectedConfig)
) {
if (typeof expectedConfig === 'string') {
expectedConfig = await ismReader.deriveIsmConfig(expectedConfig);
}

Loading…
Cancel
Save