Skip to content

Commit

Permalink
⬆️ upgrade protocol and other dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
cruzdanilo committed May 19, 2023
1 parent e7db7c7 commit ceebd3c
Show file tree
Hide file tree
Showing 7 changed files with 818 additions and 448 deletions.
8 changes: 5 additions & 3 deletions actions/onMarketUpdate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ import { type BigNumber } from '@ethersproject/bignumber';
import { StaticJsonRpcProvider } from '@ethersproject/providers';
import { Interface, type LogDescription } from '@ethersproject/abi';
import { type ChatPostMessageArguments, WebClient } from '@slack/web-api';
import { type ActionFn, Network, type TransactionEvent } from '@tenderly/actions';
import {
type ActionFn, type GatewayNetwork, Network, type TransactionEvent,
} from '@tenderly/actions';
import type { MarketInterface } from './types/Market';
import type { Previewer } from './types/Previewer';
import formatMaturity from './utils/formatMaturity';
Expand All @@ -31,8 +33,8 @@ export default (async ({ storage, secrets, gateways }, {
}[chainId] ?? 'https://etherscan.io';

const [{ address: previewerAddress }, rpc] = await Promise.all([
import(`@exactly-protocol/protocol/deployments/${network}/Previewer.json`) as Promise<{ address: string }>,
Object.values<string>(Network).includes(network) ? gateways.getGateway(network as Network) : secrets.get(`RPC_${chainId}`),
import(`@exactly/protocol/deployments/${network}/Previewer.json`) as Promise<{ address: string }>,
network !== 'optimism' ? gateways.getGateway(network as GatewayNetwork) : secrets.get(`RPC_${chainId}`),
]);
const provider = new StaticJsonRpcProvider(rpc);
const previewer = new Contract(previewerAddress, previewerABI, provider) as Previewer;
Expand Down
32 changes: 16 additions & 16 deletions actions/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions actions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
"@ethersproject/hash": "^5.7.0",
"@ethersproject/logger": "^5.7.0",
"@ethersproject/providers": "^5.7.2",
"@exactly-protocol/protocol": "^0.2.7",
"@exactly/protocol": "^0.2.10",
"@slack/web-api": "^6.8.1",
"@tenderly/actions": "^0.1.1",
"@tenderly/actions": "^0.2.3",
"no-case": "^3.0.4"
}
}
Loading

0 comments on commit ceebd3c

Please sign in to comment.