Compare commits

...

6 Commits

Author SHA1 Message Date
Noah Khamliche
9b9c47ef56 Merge branch 'development' into feat/RedactedCurvePool 2022-02-28 15:37:33 -05:00
Noah Khamliche
dfcde47ab3 added WETH/BTRFLY pool on curve mainnet 2022-02-23 20:35:18 -05:00
Noah Khamliche
424066c1a2 remove comments 2022-02-17 10:26:51 -05:00
Noah Khamliche
d8a489843e removed ohmv2/dai and ohmv2/weth, routing is the same without the search overhead 2022-02-17 10:21:17 -05:00
Noah Khamliche
914449025c updated changelog 2022-02-17 10:07:37 -05:00
Noah Khamliche
49f129aa30 fixed btrfly routing to include the ohmV2/dai, ohmV2/btfly, and ohmV2/weth pools 2022-02-17 10:05:28 -05:00
2 changed files with 17 additions and 0 deletions

View File

@@ -35,6 +35,7 @@
"note": "Fixed btrfly routing to include the ohmV2/dai, ohmV2/btfly, and ohmV2/weth pools",
"pr": 427
}
],
"timestamp": 1645113751
},

View File

@@ -631,6 +631,7 @@ export const CURVE_POOLS = {
USDP: '0x42d7025938bec20b69cbae5a77421082407f053a', // usdp
ib: '0x2dded6da1bf5dbdf597c45fcfaa3194e53ecfeaf', // iron bank
link: '0xf178c0b5bb7e7abf4e12a4838c7b7c5ba2c623c0', // link
btrflyweth: '0xf43b15ab692fde1f9c24a9fce700adcc809d5391',
// StableSwap "open pools" (crv.finance)
TUSD: '0xecd5e75afb02efa118af914515d6521aabd189f1',
STABLEx: '0x3252efd4ea2d6c78091a1f43982ee2c3659cc3d1',
@@ -1004,12 +1005,27 @@ const createCurveV2MetaTriPool = (info: { tokens: string[]; pool: string; gasSch
gasSchedule: info.gasSchedule,
});
const createCurveFactoryCryptoExchangePool = (info: { tokens: string[]; pool: string; gasSchedule: number }) => ({
exchangeFunctionSelector: CurveFunctionSelectors.exchange_underlying_uint256,
sellQuoteFunctionSelector: CurveFunctionSelectors.get_dy_uint256,
buyQuoteFunctionSelector: CurveFunctionSelectors.None,
tokens: info.tokens,
metaTokens: undefined,
poolAddress: info.pool,
gasSchedule: info.gasSchedule,
});
/**
* Mainnet Curve configuration
* The tokens are in order of their index, which each curve defines
* I.e DaiUsdc curve has DAI as index 0 and USDC as index 1
*/
export const CURVE_MAINNET_INFOS: { [name: string]: CurveInfo } = {
[CURVE_POOLS.btrflyweth]: createCurveFactoryCryptoExchangePool({
tokens: [MAINNET_TOKENS.WETH, MAINNET_TOKENS.BTRFLY],
pool: CURVE_POOLS.btrflyweth,
gasSchedule: 411e3,
}),
[CURVE_POOLS.compound]: createCurveExchangeUnderlyingPool({
tokens: [MAINNET_TOKENS.DAI, MAINNET_TOKENS.USDC],
pool: CURVE_POOLS.compound,