Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gyro protocol fees #466

Closed
wants to merge 12 commits into from
2 changes: 1 addition & 1 deletion modules/network/arbitrum.ts
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ export const arbitrumNetworkConfig: NetworkConfig = {
new PhantomStableAprService(),
new BoostedPoolAprService(),
new SwapFeeAprService(arbitrumNetworkData.balancer.swapProtocolFeePercentage),
new GaugeAprService(gaugeSubgraphService, tokenService, [arbitrumNetworkData.bal!.address]),
new GaugeAprService(tokenService, [arbitrumNetworkData.bal!.address]),
],
poolStakingServices: [new GaugeStakingService(gaugeSubgraphService, arbitrumNetworkData.bal!.address)],
tokenPriceHandlers: [
Expand Down
2 changes: 1 addition & 1 deletion modules/network/avalanche.ts
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ export const avalancheNetworkConfig: NetworkConfig = {
new PhantomStableAprService(),
new BoostedPoolAprService(),
new SwapFeeAprService(avalancheNetworkData.balancer.swapProtocolFeePercentage),
new GaugeAprService(gaugeSubgraphService, tokenService, [avalancheNetworkData.bal!.address]),
new GaugeAprService(tokenService, [avalancheNetworkData.bal!.address]),
],
poolStakingServices: [new GaugeStakingService(gaugeSubgraphService, avalancheNetworkData.bal!.address)],
tokenPriceHandlers: [
Expand Down
4 changes: 2 additions & 2 deletions modules/network/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ const baseNetworkData: NetworkData = {
},
protocolToken: 'bal',
bal: {
address: '0x4158734D47Fc9692176B5085E0F52ee0Da5d47F1 ',
address: '0x4158734d47fc9692176b5085e0f52ee0da5d47f1',
},
veBal: {
address: '0xc128a9954e6c874ea3d62ce62b468ba073093f25',
Expand Down Expand Up @@ -122,7 +122,7 @@ export const baseNetworkConfig: NetworkConfig = {
new IbTokensAprService(baseNetworkData.ibAprConfig),
new BoostedPoolAprService(),
new SwapFeeAprService(baseNetworkData.balancer.swapProtocolFeePercentage),
new GaugeAprService(gaugeSubgraphService, tokenService, [baseNetworkData.bal!.address]),
new GaugeAprService(tokenService, [baseNetworkData.bal!.address]),
],
poolStakingServices: [new GaugeStakingService(gaugeSubgraphService, baseNetworkData.bal!.address)],
tokenPriceHandlers: [
Expand Down
2 changes: 1 addition & 1 deletion modules/network/gnosis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ export const gnosisNetworkConfig: NetworkConfig = {
new PhantomStableAprService(),
new BoostedPoolAprService(),
new SwapFeeAprService(gnosisNetworkData.balancer.swapProtocolFeePercentage),
new GaugeAprService(gaugeSubgraphService, tokenService, [gnosisNetworkData.bal!.address]),
new GaugeAprService(tokenService, [gnosisNetworkData.bal!.address]),
],
poolStakingServices: [new GaugeStakingService(gaugeSubgraphService, gnosisNetworkData.bal!.address)],
tokenPriceHandlers: [
Expand Down
8 changes: 6 additions & 2 deletions modules/network/mainnet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,12 @@ export const mainnetNetworkData: NetworkData = {
},
gaugeControllerAddress: '0xc128468b7ce63ea702c1f104d55a2566b13d3abd',
gaugeControllerHelperAddress: '0x8e5698dc4897dc12243c8642e77b4f21349db97c',
gyro: {
config: '0xac89cc9d78bbad7eb3a02601b4d65daa1f908aa6'
},
balancer: {
vault: '0xba12222222228d8ba445958a75a0704d566bf2c8',
tokenAdmin: '0xf302f9f50958c5593770fdf4d4812309ff77414f',
composableStablePoolFactories: [
'0xf9ac7b9df2b3454e841110cce5550bd5ac6f875f',
'0x85a80afee867adf27b50bdb7b76da70f1e853062',
Expand Down Expand Up @@ -319,7 +323,7 @@ export const mainnetNetworkData: NetworkData = {
isIbYield: true,
},
ETHx: {
tokenAddress: '0x0f7f961648ae6db43c75663ac7e5414eb79b5704',
tokenAddress: '0xa35b1b31ce002fbf2058d22f30f95d405200a15b',
sourceUrl: 'https://universe.staderlabs.com/eth/apy',
path: 'value',
isIbYield: true,
Expand Down Expand Up @@ -364,7 +368,7 @@ export const mainnetNetworkConfig: NetworkConfig = {
new PhantomStableAprService(),
new BoostedPoolAprService(),
new SwapFeeAprService(mainnetNetworkData.balancer.swapProtocolFeePercentage),
new GaugeAprService(gaugeSubgraphService, tokenService, [mainnetNetworkData.bal!.address]),
new GaugeAprService(tokenService, [mainnetNetworkData.bal!.address]),
],
poolStakingServices: [new GaugeStakingService(gaugeSubgraphService, mainnetNetworkData.bal!.address)],
tokenPriceHandlers: [
Expand Down
4 changes: 4 additions & 0 deletions modules/network/network-config-types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,12 @@ export interface NetworkData {
};
gaugeControllerAddress?: string;
gaugeControllerHelperAddress?: string;
gyro?: {
config: string;
};
balancer: {
vault: string;
tokenAdmin?: string;
weightedPoolV2Factories: string[];
composableStablePoolFactories: string[];
yieldProtocolFeePercentage: number;
Expand Down
5 changes: 4 additions & 1 deletion modules/network/optimism.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ const optimismNetworkData: NetworkData = {
address: '0xc128a9954e6c874ea3d62ce62b468ba073093f25',
delegationProxy: '0x9da18982a33fd0c7051b19f0d7c76f2d5e7e017c',
},
gyro: {
config: '0x32acb44fc929339b9f16f0449525cc590d2a23f3'
},
balancer: {
vault: '0xba12222222228d8ba445958a75a0704d566bf2c8',
composableStablePoolFactories: [
Expand Down Expand Up @@ -253,7 +256,7 @@ export const optimismNetworkConfig: NetworkConfig = {
new PhantomStableAprService(),
new BoostedPoolAprService(),
new SwapFeeAprService(optimismNetworkData.balancer.swapProtocolFeePercentage),
new GaugeAprService(gaugeSubgraphService, tokenService, [
new GaugeAprService(tokenService, [
optimismNetworkData.beets!.address,
optimismNetworkData.bal!.address,
]),
Expand Down
5 changes: 4 additions & 1 deletion modules/network/polygon.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ const polygonNetworkData: NetworkData = {
address: '0xc128a9954e6c874ea3d62ce62b468ba073093f25',
delegationProxy: '0x0f08eef2c785aa5e7539684af04755dec1347b7c',
},
gyro: {
config: '0xfdc2e9e03f515804744a40d0f8d25c16e93fbe67'
},
balancer: {
vault: '0xba12222222228d8ba445958a75a0704d566bf2c8',
composableStablePoolFactories: [
Expand Down Expand Up @@ -263,7 +266,7 @@ export const polygonNetworkConfig: NetworkConfig = {
new PhantomStableAprService(),
new BoostedPoolAprService(),
new SwapFeeAprService(polygonNetworkData.balancer.swapProtocolFeePercentage),
new GaugeAprService(gaugeSubgraphService, tokenService, [polygonNetworkData.bal!.address]),
new GaugeAprService(tokenService, [polygonNetworkData.bal!.address]),
],
poolStakingServices: [new GaugeStakingService(gaugeSubgraphService, polygonNetworkData.bal!.address)],
tokenPriceHandlers: [
Expand Down
2 changes: 1 addition & 1 deletion modules/network/zkevm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ export const zkevmNetworkConfig: NetworkConfig = {
new PhantomStableAprService(),
new BoostedPoolAprService(),
new SwapFeeAprService(zkevmNetworkData.balancer.swapProtocolFeePercentage),
new GaugeAprService(gaugeSubgraphService, tokenService, [zkevmNetworkData.bal!.address]),
new GaugeAprService(tokenService, [zkevmNetworkData.bal!.address]),
],
poolStakingServices: [new GaugeStakingService(gaugeSubgraphService, zkevmNetworkData.bal!.address)],
tokenPriceHandlers: [
Expand Down
Loading