Skip to content

Commit

Permalink
feat: Support Blast constants (#550)
Browse files Browse the repository at this point in the history
  • Loading branch information
pxrl authored Jul 9, 2024
1 parent f22da17 commit 8febef3
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 8 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@across-protocol/contracts",
"version": "3.0.4",
"version": "3.0.5",
"author": "UMA Team",
"license": "AGPL-3.0-only",
"repository": {
Expand Down Expand Up @@ -32,7 +32,7 @@
"prepublish": "yarn build && hardhat export --export-all ./cache/massExport.json && ts-node ./scripts/processHardhatExport.ts && prettier --write ./deployments/deployments.json && yarn generate-contract-types"
},
"dependencies": {
"@across-protocol/constants": "^3.1.3",
"@across-protocol/constants": "^3.1.5",
"@defi-wonderland/smock": "^2.3.4",
"@eth-optimism/contracts": "^0.5.40",
"@ethersproject/abstract-provider": "5.7.0",
Expand Down
7 changes: 5 additions & 2 deletions tasks/enableL1TokenAcrossEcosystem.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { task } from "hardhat/config";
import assert from "assert";
import { askYesNoQuestion, minimalSpokePoolInterface } from "./utils";
import { TOKEN_SYMBOLS_MAP } from "../utils/constants";
import { TOKEN_SYMBOLS_MAP, CHAIN_IDs } from "../utils/constants";

const enabledChainIds = [1, 10, 137, 42161, 324, 8453, 59144, 34443, 1135]; // Supported mainnet chain IDs.
const enabledChainIds = [1, 10, 137, 42161, 324, 1135, 8453, 34443, 59144, 81457]; // Supported mainnet chain IDs.

const getChainsFromList = (taskArgInput: string): number[] =>
taskArgInput
Expand Down Expand Up @@ -78,7 +78,10 @@ task("enable-l1-token-across-ecosystem", "Enable a provided token across the ent
`Could not find token address on chain ${chainId} in TOKEN_SYMBOLS_MAP for USDC.e or Native USDC`
);
}
} else if (matchedSymbol === "DAI" && chainId === CHAIN_IDs.BLAST) {
return TOKEN_SYMBOLS_MAP.USDB.addresses[chainId]; // DAI maps to USDB on Blast.
}

const l2Address = TOKEN_SYMBOLS_MAP[matchedSymbol].addresses[chainId];
if (l2Address === undefined) {
throw new Error(`Could not find token address on chain ${chainId} in TOKEN_SYMBOLS_MAP`);
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
# yarn lockfile v1


"@across-protocol/constants@^3.1.3":
version "3.1.3"
resolved "https://registry.yarnpkg.com/@across-protocol/constants/-/constants-3.1.3.tgz#534764a4137bd5181ab4214543d0cbbf44a90c63"
integrity sha512-4pUjJrRor9gFPAsskbva6bDK780tzXYMWtqCtBa1jOUc+X3PxC6U6lF7ZoyX+lqU/KcfAWDLg8YEsz+KLm3NrQ==
"@across-protocol/constants@^3.1.5":
version "3.1.5"
resolved "https://registry.yarnpkg.com/@across-protocol/constants/-/constants-3.1.5.tgz#58cdd06816518b5cf1d92d94a4bc175ab0bc9d0c"
integrity sha512-3bqBNdYhVnpNwd9zwxmDWewM0ixRxTiL0SCHmOWlmDEx9xqPFHx5t+GLJWOa18wIoPP5KWv/TyI+fdwi3Tg5Bw==

"@across-protocol/contracts@^0.1.4":
version "0.1.4"
Expand Down

0 comments on commit 8febef3

Please sign in to comment.