@pendle/core-v2 0.8.0-beta-9 → 0.8.0-beta-11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/AaveV3/PendleAaveV3SCY.sol/PendleAaveV3SCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/AaveV3/PendleAaveV3SCY.sol/PendleAaveV3SCY.json +2 -2
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/AaveV3/WadRayMath.sol/WadRayMath.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/AaveV3/WadRayMath.sol/WadRayMath.json +2 -2
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/BenQi/PendleQiTokenHelper.sol/PendleQiTokenHelper.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/BenQi/PendleQiTokenHelper.sol/PendleQiTokenHelper.json +2 -2
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/BenQi/PendleQiTokenSCY.sol/PendleQiTokenSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/BenQi/PendleQiTokenSCY.sol/PendleQiTokenSCY.json +2 -2
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleERC4626SCY.sol/PendleERC4626SCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleERC4626SCY.sol/PendleERC4626SCY.json +2 -2
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleStargateSCY.sol/PendleStargatePool.dbg.json +4 -0
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleStargateSCY.sol/PendleStargatePool.json +837 -0
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleWstEthSCY.sol/PendleWstEthSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleWstEthSCY.sol/PendleWstEthSCY.json +2 -2
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleYearnVaultScy.sol/PendleYearnVaultSCY.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/SCY-implementations/PendleYearnVaultScy.sol/PendleYearnVaultSCY.json +2 -2
- package/build/artifacts/contracts/SuperComposableYield/base-implementations/SCYBase.sol/SCYBase.dbg.json +1 -1
- package/build/artifacts/contracts/SuperComposableYield/base-implementations/SCYBaseWithRewards.sol/SCYBaseWithRewards.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/CelerAbstracts/CelerReceiverUpg.sol/CelerReceiverUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/CelerAbstracts/CelerSenderUpg.sol/CelerSenderUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/GaugeController/PendleGaugeControllerBaseUpg.sol/PendleGaugeControllerBaseUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/GaugeController/PendleGaugeControllerMainchain.sol/PendleGaugeControllerMainchainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/GaugeController/PendleGaugeControllerMainchain.sol/PendleGaugeControllerMainchainUpg.json +2 -2
- package/build/artifacts/contracts/core/LiquidityMining/GaugeController/PendleGaugeControllerSidechain.sol/PendleGaugeControllerSidechainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/GaugeController/PendleGaugeControllerSidechain.sol/PendleGaugeControllerSidechainUpg.json +2 -2
- package/build/artifacts/contracts/core/LiquidityMining/PendleGauge.sol/PendleGauge.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.json +2 -2
- package/build/artifacts/contracts/core/LiquidityMining/VotingController/VotingControllerStorageUpg.sol/VotingControllerStorageUpg.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.json +2 -2
- package/build/artifacts/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.dbg.json +1 -1
- package/build/artifacts/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.json +2 -2
- package/build/artifacts/contracts/core/LiquidityMining/VotingEscrow/VotingEscrowTokenBase.sol/VotingEscrowTokenBase.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarket.sol/PendleMarket.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarket.sol/PendleMarket.json +105 -30
- package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.json +2 -2
- package/build/artifacts/contracts/core/PendleERC20.sol/PendleERC20.dbg.json +1 -1
- package/build/artifacts/contracts/core/PendleERC20.sol/PendleERC20.json +2 -2
- package/build/artifacts/contracts/core/PendleERC20Permit.sol/PendleERC20Permit.dbg.json +1 -1
- package/build/artifacts/contracts/core/PendleERC20Permit.sol/PendleERC20Permit.json +2 -2
- package/build/artifacts/contracts/core/PendleRouter.sol/PendleRouter.dbg.json +1 -1
- package/build/artifacts/contracts/core/PendleRouter.sol/PendleRouter.json +2 -2
- package/build/artifacts/contracts/core/YieldContracts/InterestManagerYT.sol/InterestManagerYT.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendlePrincipalToken.sol/PendlePrincipalToken.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendlePrincipalToken.sol/PendlePrincipalToken.json +2 -2
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactory.sol/PendleYieldContractFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactory.sol/PendleYieldContractFactory.json +2 -2
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.json +2 -83
- package/build/artifacts/contracts/core/actions/ActionCallback.sol/ActionCallback.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionCallback.sol/ActionCallback.json +2 -2
- package/build/artifacts/contracts/core/actions/ActionCore.sol/ActionCore.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionCore.sol/ActionCore.json +16 -206
- package/build/artifacts/contracts/core/actions/ActionYT.sol/ActionYT.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/ActionYT.sol/ActionYT.json +117 -12
- package/build/artifacts/contracts/core/actions/base/ActionSCYAndPTBase.sol/ActionSCYAndPTBase.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/base/ActionSCYAndPTBase.sol/ActionSCYAndPTBase.json +148 -0
- package/build/artifacts/contracts/core/actions/base/ActionSCYAndPYBase.sol/ActionSCYAndPYBase.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/base/ActionSCYAndPYBase.sol/ActionSCYAndPYBase.json +148 -0
- package/build/artifacts/contracts/core/actions/base/ActionSCYAndYTBase.sol/ActionSCYAndYTBase.dbg.json +1 -1
- package/build/artifacts/contracts/core/actions/base/ActionSCYAndYTBase.sol/ActionSCYAndYTBase.json +173 -0
- package/build/artifacts/contracts/core/actions/base/CallbackHelper.sol/CallbackHelper.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IAToken.sol/IAToken.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IAavePool.sol/IAavePool.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IAaveRewardsController.sol/IAaveRewardsController.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IBenQiComptroller.sol/IBenQiComptroller.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IBenQiInterestRateModel.sol/IBenQiInterestRateModel.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/ICelerMessageBus.sol/ICelerMessageBus.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/ICelerMessageReceiverApp.sol/ICelerMessageReceiverApp.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IERC4626.sol/IERC4626.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IJoePair.sol/IJoePair.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IJoeRouter01.sol/IJoeRouter01.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IJoeRouter02.sol/IJoeRouter02.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionCore.sol/IPActionCore.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionCore.sol/IPActionCore.json +0 -338
- package/build/artifacts/contracts/interfaces/IPActionYT.sol/IPActionYT.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionYT.sol/IPActionYT.json +0 -68
- package/build/artifacts/contracts/interfaces/IPAllAction.sol/IPAllAction.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllAction.sol/IPAllAction.json +0 -406
- package/build/artifacts/contracts/interfaces/IPGaugeController.sol/IPGaugeController.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPGaugeControllerMainchain.sol/IPGaugeControllerMainchain.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPGovernanceManager.sol/IPGovernanceManager.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPInterestManagerYT.sol/IPInterestManagerYT.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMarket.sol/IPMarket.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMarket.sol/IPMarket.json +28 -28
- package/build/artifacts/contracts/interfaces/IPMarketFactory.sol/IPMarketFactory.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMarketSwapCallback.sol/IPMarketSwapCallback.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPPermissionsV2Upg.sol/IPermissionsV2Upg.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPPrincipalToken.sol/IPPrincipalToken.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPRouterStatic.sol/IPRouterStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPRouterStatic.sol/IPRouterStatic.json +5 -0
- package/build/artifacts/contracts/interfaces/IPVeToken.sol/IPVeToken.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingController.sol/IPVotingController.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingEscrow.sol/IPVotingEscrow.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldContractFactory.sol/IPYieldContractFactory.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldToken.sol/IPYieldToken.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldToken.sol/IPYieldToken.json +0 -81
- package/build/artifacts/contracts/interfaces/IQiAvax.sol/IQiAvax.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IQiErc20.sol/IQiErc20.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IQiToken.sol/IQiToken.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IREDACTEDStaking.sol/IREDACTEDStaking.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IRewardManager.sol/IRewardManager.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IStargateLPStaking.sol/IStargateLPStaking.dbg.json +4 -0
- package/build/artifacts/contracts/interfaces/IStargateLPStaking.sol/IStargateLPStaking.json +47 -0
- package/build/artifacts/contracts/interfaces/IStargatePool.sol/IStargatePool.dbg.json +4 -0
- package/build/artifacts/contracts/interfaces/IStargatePool.sol/IStargatePool.json +56 -0
- package/build/artifacts/contracts/interfaces/IStargateRouter.sol/IStargateRouter.dbg.json +4 -0
- package/build/artifacts/contracts/interfaces/IStargateRouter.sol/IStargateRouter.json +63 -0
- package/build/artifacts/contracts/interfaces/ISuperComposableYield.sol/ISuperComposableYield.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IWETH.sol/IWETH.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IWXBTRFLY.sol/IWXBTRFLY.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IWstETH.sol/IWstETH.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IYearnVault.sol/IYearnVault.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/RewardManager.sol/RewardManager.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/RewardManagerAbstract.sol/RewardManagerAbstract.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/SCY/SCYIndex.sol/SCYIndexLib.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/SCY/SCYIndex.sol/SCYIndexLib.json +2 -2
- package/build/artifacts/contracts/libraries/SCY/SCYUtils.sol/SCYUtils.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/SCY/SCYUtils.sol/SCYUtils.json +2 -2
- package/build/artifacts/contracts/libraries/VeBalanceLib.sol/VeBalanceLib.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/VeBalanceLib.sol/VeBalanceLib.json +2 -2
- package/build/artifacts/contracts/libraries/VeHistoryLib.sol/Checkpoints.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/VeHistoryLib.sol/Checkpoints.json +2 -2
- package/build/artifacts/contracts/libraries/helpers/ArrayLib.sol/ArrayLib.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/helpers/ArrayLib.sol/ArrayLib.json +2 -2
- package/build/artifacts/contracts/libraries/helpers/ExpiryUtilsLib.sol/ExpiryUtils.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/helpers/ExpiryUtilsLib.sol/ExpiryUtils.json +2 -2
- package/build/artifacts/contracts/libraries/helpers/MiniHelpers.sol/MiniHelpers.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/helpers/MiniHelpers.sol/MiniHelpers.json +2 -2
- package/build/artifacts/contracts/libraries/helpers/SSTORE2Deployer.sol/SSTORE2Deployer.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/helpers/SSTORE2Deployer.sol/SSTORE2Deployer.json +2 -2
- package/build/artifacts/contracts/libraries/helpers/TokenHelper.sol/TokenHelper.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/LogExpMath.sol/LogExpMath.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/LogExpMath.sol/LogExpMath.json +2 -2
- package/build/artifacts/contracts/libraries/math/MarketApproxLib.sol/MarketApproxLib.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/MarketApproxLib.sol/MarketApproxLib.json +2 -2
- package/build/artifacts/contracts/libraries/math/MarketMathCore.sol/MarketMathCore.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/MarketMathCore.sol/MarketMathCore.json +2 -2
- package/build/artifacts/contracts/libraries/math/Math.sol/Math.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/Math.sol/Math.json +2 -2
- package/build/artifacts/contracts/libraries/math/WeekMath.sol/WeekMath.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/math/WeekMath.sol/WeekMath.json +2 -2
- package/build/artifacts/contracts/libraries/solmate/SSTORE2.sol/SSTORE2.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/solmate/SSTORE2.sol/SSTORE2.json +2 -2
- package/build/artifacts/contracts/libraries/traderjoe/JoeLibrary.sol/JoeLibrary.dbg.json +1 -1
- package/build/artifacts/contracts/libraries/traderjoe/JoeLibrary.sol/JoeLibrary.json +2 -2
- package/build/artifacts/contracts/libraries/traderjoe/PendleJoeSwapHelperUpg.sol/PendleJoeSwapHelperUpg.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.json +7 -2
- package/build/artifacts/contracts/periphery/PendleGovernanceManager.sol/PendleGovernanceManager.dbg.json +1 -1
- package/build/artifacts/contracts/periphery/PendleGovernanceManager.sol/PendleGovernanceManager.json +2 -2
- package/build/artifacts/contracts/periphery/PermissionsV2Upg.sol/PermissionsV2Upg.dbg.json +1 -1
- package/contracts/core/PendleRouter.sol +8 -0
- package/contracts/core/YieldContracts/PendleYieldToken.sol +13 -5
- package/contracts/core/actions/ActionCore.sol +80 -0
- package/contracts/core/actions/base/ActionSCYAndPYBase.sol +36 -0
- package/contracts/interfaces/IPActionCore.sol +78 -0
- package/contracts/interfaces/IPRouterStatic.sol +2 -1
- package/contracts/offchain-helpers/RouterStatic.sol +56 -4
- package/deployments/43113-benqi.json +2 -2
- package/deployments/43113-core.json +1 -1
- package/deployments/43113-markets/benqi-market-5C60ba.json +7 -0
- package/deployments/43113-markets/benqi-market-611eA3.json +7 -0
- package/deployments/80001-benqi.json +2 -2
- package/deployments/80001-core.json +1 -1
- package/deployments/80001-markets/benqi-market-5E1104.json +7 -0
- package/deployments/80001-markets/benqi-market-c68429.json +7 -0
- package/package.json +1 -1
- package/typechain-types/ActionCore.ts +38 -180
- package/typechain-types/ActionSCYAndPTBase.ts +129 -3
- package/typechain-types/ActionSCYAndPYBase.ts +129 -3
- package/typechain-types/ActionSCYAndYTBase.ts +149 -3
- package/typechain-types/ActionYT.ts +117 -31
- package/typechain-types/IPActionCore.ts +3 -271
- package/typechain-types/IPActionYT.ts +3 -63
- package/typechain-types/IPAllAction.ts +3 -329
- package/typechain-types/IPMarket.ts +38 -38
- package/typechain-types/IPRouterStatic.ts +6 -3
- package/typechain-types/IPYieldToken.ts +0 -74
- package/typechain-types/IStargateLPStaking.ts +143 -0
- package/typechain-types/IStargatePool.ts +129 -0
- package/typechain-types/IStargateRouter.ts +159 -0
- package/typechain-types/PendleMarket.ts +142 -38
- package/typechain-types/PendleStargatePool.ts +1089 -0
- package/typechain-types/PendleYieldToken.ts +0 -74
- package/typechain-types/RouterStatic.ts +6 -3
- package/typechain-types/factories/ActionCallback__factory.ts +1 -1
- package/typechain-types/factories/ActionCore__factory.ts +15 -205
- package/typechain-types/factories/ActionSCYAndPTBase__factory.ts +148 -0
- package/typechain-types/factories/ActionSCYAndPYBase__factory.ts +148 -0
- package/typechain-types/factories/ActionSCYAndYTBase__factory.ts +173 -0
- package/typechain-types/factories/ActionYT__factory.ts +116 -11
- package/typechain-types/factories/ERC20__factory.ts +1 -1
- package/typechain-types/factories/IPActionCore__factory.ts +0 -338
- package/typechain-types/factories/IPActionYT__factory.ts +0 -68
- package/typechain-types/factories/IPAllAction__factory.ts +0 -406
- package/typechain-types/factories/IPMarket__factory.ts +28 -28
- package/typechain-types/factories/IPRouterStatic__factory.ts +5 -0
- package/typechain-types/factories/IPYieldToken__factory.ts +0 -81
- package/typechain-types/factories/IStargateLPStaking__factory.ts +62 -0
- package/typechain-types/factories/IStargatePool__factory.ts +68 -0
- package/typechain-types/factories/IStargateRouter__factory.ts +78 -0
- package/typechain-types/factories/PendleAaveV3SCY__factory.ts +1 -1
- package/typechain-types/factories/PendleERC20Permit__factory.ts +1 -1
- package/typechain-types/factories/PendleERC20__factory.ts +1 -1
- package/typechain-types/factories/PendleERC4626SCY__factory.ts +1 -1
- package/typechain-types/factories/PendleGaugeControllerMainchainUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleGaugeControllerSidechainUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleGovernanceManager__factory.ts +1 -1
- package/typechain-types/factories/PendleMarketFactory__factory.ts +1 -1
- package/typechain-types/factories/PendleMarket__factory.ts +104 -29
- package/typechain-types/factories/PendlePrincipalToken__factory.ts +1 -1
- package/typechain-types/factories/PendleQiTokenHelper__factory.ts +1 -1
- package/typechain-types/factories/PendleQiTokenSCY__factory.ts +1 -1
- package/typechain-types/factories/PendleRouter__factory.ts +1 -1
- package/typechain-types/factories/PendleStargatePool__factory.ts +929 -0
- package/typechain-types/factories/PendleVotingControllerUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleWstEthSCY__factory.ts +1 -1
- package/typechain-types/factories/PendleYearnVaultScy__factory.ts +1 -1
- package/typechain-types/factories/PendleYieldContractFactory__factory.ts +1 -1
- package/typechain-types/factories/PendleYieldToken__factory.ts +1 -82
- package/typechain-types/factories/RouterStatic__factory.ts +6 -1
- package/typechain-types/factories/VotingEscrowPendleMainchain__factory.ts +1 -1
- package/typechain-types/factories/VotingEscrowPendleSidechain__factory.ts +1 -1
- package/typechain-types/hardhat.d.ts +36 -0
- package/typechain-types/index.ts +8 -0
|
@@ -43,6 +43,37 @@ contract ActionCore is IPActionCore, ActionSCYAndPTBase {
|
|
|
43
43
|
emit AddLiquidity(msg.sender, market, receiver, scyUsed, ptUsed, netLpOut);
|
|
44
44
|
}
|
|
45
45
|
|
|
46
|
+
function addLiquiditySinglePt(
|
|
47
|
+
address receiver,
|
|
48
|
+
address market,
|
|
49
|
+
uint256 netPtIn,
|
|
50
|
+
uint256 minLpOut,
|
|
51
|
+
ApproxParams memory guessPtSwapToScy
|
|
52
|
+
) external returns (uint256 netLpOut) {
|
|
53
|
+
require(false, "NOT IMPLEMENTED");
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
function addLiquiditySingleScy(
|
|
57
|
+
address receiver,
|
|
58
|
+
address market,
|
|
59
|
+
uint256 netScyIn,
|
|
60
|
+
uint256 minLpOut,
|
|
61
|
+
ApproxParams memory guessPtReceivedFromScy
|
|
62
|
+
) external returns (uint256 netLpOut) {
|
|
63
|
+
require(false, "NOT IMPLEMENTED");
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
function addLiquiditySingleRawToken(
|
|
67
|
+
address receiver,
|
|
68
|
+
address market,
|
|
69
|
+
uint256 netRawTokenIn,
|
|
70
|
+
uint256 minLpOut,
|
|
71
|
+
address[] calldata path,
|
|
72
|
+
ApproxParams memory guessPtReceivedFromScy
|
|
73
|
+
) external returns (uint256 netLpOut) {
|
|
74
|
+
require(false, "NOT IMPLEMENTED");
|
|
75
|
+
}
|
|
76
|
+
|
|
46
77
|
/// @dev refer to the internal function
|
|
47
78
|
function removeLiquidity(
|
|
48
79
|
address receiver,
|
|
@@ -62,6 +93,35 @@ contract ActionCore is IPActionCore, ActionSCYAndPTBase {
|
|
|
62
93
|
emit RemoveLiquidity(msg.sender, market, receiver, lpToRemove, netPtOut, netScyOut);
|
|
63
94
|
}
|
|
64
95
|
|
|
96
|
+
function removeLiquiditySinglePt(
|
|
97
|
+
address receiver,
|
|
98
|
+
address market,
|
|
99
|
+
uint256 lpToRemove,
|
|
100
|
+
uint256 minPtOut,
|
|
101
|
+
ApproxParams memory guessPtOut
|
|
102
|
+
) external returns (uint256 netPtOut) {
|
|
103
|
+
require(false, "NOT IMPLEMENTED");
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
function removeLiquiditySingleScy(
|
|
107
|
+
address receiver,
|
|
108
|
+
address market,
|
|
109
|
+
uint256 lpToRemove,
|
|
110
|
+
uint256 minScyOut
|
|
111
|
+
) external returns (uint256 netScyOut) {
|
|
112
|
+
require(false, "NOT IMPLEMENTED");
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
function removeLiquiditySingleRawToken(
|
|
116
|
+
address receiver,
|
|
117
|
+
address market,
|
|
118
|
+
uint256 lpToRemove,
|
|
119
|
+
uint256 minRawTokenOut,
|
|
120
|
+
address[] memory path
|
|
121
|
+
) external returns (uint256 netRawTokenOut) {
|
|
122
|
+
require(false, "NOT IMPLEMENTED");
|
|
123
|
+
}
|
|
124
|
+
|
|
65
125
|
/// @dev refer to the internal function
|
|
66
126
|
function swapExactPtForScy(
|
|
67
127
|
address receiver,
|
|
@@ -169,6 +229,26 @@ contract ActionCore is IPActionCore, ActionSCYAndPTBase {
|
|
|
169
229
|
);
|
|
170
230
|
}
|
|
171
231
|
|
|
232
|
+
function mintPyFromScy(
|
|
233
|
+
address receiver,
|
|
234
|
+
address YT,
|
|
235
|
+
uint256 netScyIn,
|
|
236
|
+
uint256 minPyOut
|
|
237
|
+
) external returns (uint256 netPyOut) {
|
|
238
|
+
netPyOut = _mintPyFromScy(receiver, YT, netScyIn, minPyOut, true);
|
|
239
|
+
emit MintPyFromScy(msg.sender, receiver, YT, netScyIn, netPyOut);
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
function redeemPyToScy(
|
|
243
|
+
address receiver,
|
|
244
|
+
address YT,
|
|
245
|
+
uint256 netPyIn,
|
|
246
|
+
uint256 minScyOut
|
|
247
|
+
) external returns (uint256 netScyOut) {
|
|
248
|
+
netScyOut = _redeemPyToScy(receiver, YT, netPyIn, minScyOut, true);
|
|
249
|
+
emit RedeemPyToScy(msg.sender, receiver, YT, netPyIn, netScyOut);
|
|
250
|
+
}
|
|
251
|
+
|
|
172
252
|
/// @dev refer to the internal function
|
|
173
253
|
function swapExactRawTokenForPt(
|
|
174
254
|
address receiver,
|
|
@@ -129,4 +129,40 @@ abstract contract ActionSCYAndPYBase is PendleJoeSwapHelperUpg, TokenHelper {
|
|
|
129
129
|
|
|
130
130
|
netRawTokenOut = _redeemScyToRawToken(receiver, SCY, 0, minRawTokenOut, path, false);
|
|
131
131
|
}
|
|
132
|
+
|
|
133
|
+
function _mintPyFromScy(
|
|
134
|
+
address receiver,
|
|
135
|
+
address YT,
|
|
136
|
+
uint256 netScyIn,
|
|
137
|
+
uint256 minPyOut,
|
|
138
|
+
bool doPull
|
|
139
|
+
) internal returns (uint256 netPyOut) {
|
|
140
|
+
address SCY = IPYieldToken(YT).SCY();
|
|
141
|
+
|
|
142
|
+
if (doPull) {
|
|
143
|
+
IERC20(SCY).safeTransferFrom(msg.sender, YT, netScyIn);
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
netPyOut = IPYieldToken(YT).mintPY(receiver, receiver);
|
|
147
|
+
require(netPyOut >= minPyOut, "insufficient PY out");
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
function _redeemPyToScy(
|
|
151
|
+
address receiver,
|
|
152
|
+
address YT,
|
|
153
|
+
uint256 netPyIn,
|
|
154
|
+
uint256 minScyOut,
|
|
155
|
+
bool doPull
|
|
156
|
+
) internal returns (uint256 netScyOut) {
|
|
157
|
+
address PT = IPYieldToken(YT).PT();
|
|
158
|
+
|
|
159
|
+
if (doPull) {
|
|
160
|
+
bool needToBurnYt = (!IPYieldToken(YT).isExpired());
|
|
161
|
+
IERC20(PT).safeTransferFrom(msg.sender, YT, netPyIn);
|
|
162
|
+
if (needToBurnYt) IERC20(YT).safeTransferFrom(msg.sender, YT, netPyIn);
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
netScyOut = IPYieldToken(YT).redeemPY(receiver);
|
|
166
|
+
require(netScyOut >= minScyOut, "insufficient SCY out");
|
|
167
|
+
}
|
|
132
168
|
}
|
|
@@ -57,6 +57,22 @@ interface IPActionCore {
|
|
|
57
57
|
uint256 netRawTokenOut
|
|
58
58
|
);
|
|
59
59
|
|
|
60
|
+
event MintPyFromScy(
|
|
61
|
+
address indexed caller,
|
|
62
|
+
address indexed receiver,
|
|
63
|
+
address indexed YT,
|
|
64
|
+
uint256 netScyIn,
|
|
65
|
+
uint256 netPyOut
|
|
66
|
+
);
|
|
67
|
+
|
|
68
|
+
event RedeemPyToScy(
|
|
69
|
+
address indexed caller,
|
|
70
|
+
address indexed receiver,
|
|
71
|
+
address indexed YT,
|
|
72
|
+
uint256 netPyIn,
|
|
73
|
+
uint256 netScyOut
|
|
74
|
+
);
|
|
75
|
+
|
|
60
76
|
event MintPyFromRawToken(
|
|
61
77
|
address indexed caller,
|
|
62
78
|
address indexed receiver,
|
|
@@ -89,6 +105,31 @@ interface IPActionCore {
|
|
|
89
105
|
uint256 ptUsed
|
|
90
106
|
);
|
|
91
107
|
|
|
108
|
+
function addLiquiditySinglePt(
|
|
109
|
+
address receiver,
|
|
110
|
+
address market,
|
|
111
|
+
uint256 netPtIn,
|
|
112
|
+
uint256 minLpOut,
|
|
113
|
+
ApproxParams memory guessPtSwapToScy
|
|
114
|
+
) external returns (uint256 netLpOut);
|
|
115
|
+
|
|
116
|
+
function addLiquiditySingleScy(
|
|
117
|
+
address receiver,
|
|
118
|
+
address market,
|
|
119
|
+
uint256 netScyIn,
|
|
120
|
+
uint256 minLpOut,
|
|
121
|
+
ApproxParams memory guessPtReceivedFromScy
|
|
122
|
+
) external returns (uint256 netLpOut);
|
|
123
|
+
|
|
124
|
+
function addLiquiditySingleRawToken(
|
|
125
|
+
address receiver,
|
|
126
|
+
address market,
|
|
127
|
+
uint256 netRawTokenIn,
|
|
128
|
+
uint256 minLpOut,
|
|
129
|
+
address[] calldata path,
|
|
130
|
+
ApproxParams memory guessPtReceivedFromScy
|
|
131
|
+
) external returns (uint256 netLpOut);
|
|
132
|
+
|
|
92
133
|
function removeLiquidity(
|
|
93
134
|
address receiver,
|
|
94
135
|
address market,
|
|
@@ -97,6 +138,29 @@ interface IPActionCore {
|
|
|
97
138
|
uint256 ptOutMin
|
|
98
139
|
) external returns (uint256 netScyOut, uint256 netPtOut);
|
|
99
140
|
|
|
141
|
+
function removeLiquiditySinglePt(
|
|
142
|
+
address receiver,
|
|
143
|
+
address market,
|
|
144
|
+
uint256 lpToRemove,
|
|
145
|
+
uint256 minPtOut,
|
|
146
|
+
ApproxParams memory guessPtOut
|
|
147
|
+
) external returns (uint256 netPtOut);
|
|
148
|
+
|
|
149
|
+
function removeLiquiditySingleScy(
|
|
150
|
+
address receiver,
|
|
151
|
+
address market,
|
|
152
|
+
uint256 lpToRemove,
|
|
153
|
+
uint256 minScyOut
|
|
154
|
+
) external returns (uint256 netScyOut);
|
|
155
|
+
|
|
156
|
+
function removeLiquiditySingleRawToken(
|
|
157
|
+
address receiver,
|
|
158
|
+
address market,
|
|
159
|
+
uint256 lpToRemove,
|
|
160
|
+
uint256 minRawTokenOut,
|
|
161
|
+
address[] memory path
|
|
162
|
+
) external returns (uint256 netRawTokenOut);
|
|
163
|
+
|
|
100
164
|
function swapExactPtForScy(
|
|
101
165
|
address receiver,
|
|
102
166
|
address market,
|
|
@@ -159,6 +223,20 @@ interface IPActionCore {
|
|
|
159
223
|
address[] memory path
|
|
160
224
|
) external returns (uint256 netRawTokenOut);
|
|
161
225
|
|
|
226
|
+
function mintPyFromScy(
|
|
227
|
+
address receiver,
|
|
228
|
+
address YT,
|
|
229
|
+
uint256 netScyIn,
|
|
230
|
+
uint256 minPyOut
|
|
231
|
+
) external returns (uint256 netPyOut);
|
|
232
|
+
|
|
233
|
+
function redeemPyToScy(
|
|
234
|
+
address receiver,
|
|
235
|
+
address YT,
|
|
236
|
+
uint256 netPyIn,
|
|
237
|
+
uint256 minScyOut
|
|
238
|
+
) external returns (uint256 netScyOut);
|
|
239
|
+
|
|
162
240
|
function swapExactRawTokenForPt(
|
|
163
241
|
address receiver,
|
|
164
242
|
address market,
|
|
@@ -83,7 +83,8 @@ contract RouterStatic is IPRouterStatic {
|
|
|
83
83
|
address pt,
|
|
84
84
|
address scy,
|
|
85
85
|
MarketState memory state,
|
|
86
|
-
int256 impliedYield
|
|
86
|
+
int256 impliedYield,
|
|
87
|
+
uint256 exchangeRate
|
|
87
88
|
)
|
|
88
89
|
{
|
|
89
90
|
IPMarket _market = IPMarket(market);
|
|
@@ -93,6 +94,7 @@ contract RouterStatic is IPRouterStatic {
|
|
|
93
94
|
scy = address(SCY);
|
|
94
95
|
state = _market.readState(true);
|
|
95
96
|
impliedYield = getPtImpliedYield(market);
|
|
97
|
+
exchangeRate = getExchangeRate(market);
|
|
96
98
|
}
|
|
97
99
|
|
|
98
100
|
// ============= USER INFO =============
|
|
@@ -159,6 +161,28 @@ contract RouterStatic is IPRouterStatic {
|
|
|
159
161
|
);
|
|
160
162
|
}
|
|
161
163
|
|
|
164
|
+
function addLiquiditySinglePtStatic(address market, uint256 netPtIn)
|
|
165
|
+
external
|
|
166
|
+
returns (uint256 netLpOut)
|
|
167
|
+
{
|
|
168
|
+
require(false, "NOT IMPLEMENTED");
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
function addLiquiditySingleScy(address market, uint256 netScyIn)
|
|
172
|
+
external
|
|
173
|
+
returns (uint256 netLpOut)
|
|
174
|
+
{
|
|
175
|
+
require(false, "NOT IMPLEMENTED");
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
function addLiquiditySingleBaseToken(
|
|
179
|
+
address market,
|
|
180
|
+
address baseToken,
|
|
181
|
+
uint256 netBaseTokenIn
|
|
182
|
+
) external returns (uint256 netLpOut) {
|
|
183
|
+
require(false, "NOT IMPLEMENTED");
|
|
184
|
+
}
|
|
185
|
+
|
|
162
186
|
function removeLiquidityStatic(address market, uint256 lpToRemove)
|
|
163
187
|
external
|
|
164
188
|
view
|
|
@@ -168,6 +192,28 @@ contract RouterStatic is IPRouterStatic {
|
|
|
168
192
|
(netScyOut, netPtOut) = state.removeLiquidity(lpToRemove);
|
|
169
193
|
}
|
|
170
194
|
|
|
195
|
+
function removeLiquiditySinglePtStatic(address market, uint256 lpToRemove)
|
|
196
|
+
external
|
|
197
|
+
returns (uint256 netPtOut)
|
|
198
|
+
{
|
|
199
|
+
require(false, "NOT IMPLEMENTED");
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
function removeLiquiditySingleScy(address market, uint256 lpToRemove)
|
|
203
|
+
external
|
|
204
|
+
returns (uint256 netScyOut)
|
|
205
|
+
{
|
|
206
|
+
require(false, "NOT IMPLEMENTED");
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
function removeLiquiditySingleBaseToken(
|
|
210
|
+
address market,
|
|
211
|
+
uint256 lpToRemove,
|
|
212
|
+
address baseToken
|
|
213
|
+
) external returns (uint256 netBaseTokenOut) {
|
|
214
|
+
require(false, "NOT IMPLEMENTED");
|
|
215
|
+
}
|
|
216
|
+
|
|
171
217
|
function swapExactPtForScyStatic(address market, uint256 exactPtIn)
|
|
172
218
|
public
|
|
173
219
|
view
|
|
@@ -457,16 +503,22 @@ contract RouterStatic is IPRouterStatic {
|
|
|
457
503
|
userMarketInfo.market = market;
|
|
458
504
|
userMarketInfo.lpBalance = userLp;
|
|
459
505
|
|
|
506
|
+
(ISuperComposableYield SCY, IPPrincipalToken PT, ) = _market.readTokens();
|
|
507
|
+
(userMarketInfo.assetBalance.assetType, userMarketInfo.assetBalance.assetAddress, ) = SCY
|
|
508
|
+
.assetInfo();
|
|
509
|
+
|
|
460
510
|
MarketState memory state = _market.readState(false);
|
|
461
511
|
uint256 totalLp = uint256(state.totalLp);
|
|
512
|
+
|
|
513
|
+
if (totalLp == 0) {
|
|
514
|
+
return userMarketInfo;
|
|
515
|
+
}
|
|
516
|
+
|
|
462
517
|
uint256 userPt = (userLp * uint256(state.totalPt)) / totalLp;
|
|
463
518
|
uint256 userScy = (userLp * uint256(state.totalScy)) / totalLp;
|
|
464
519
|
|
|
465
|
-
(ISuperComposableYield SCY, IPPrincipalToken PT, ) = _market.readTokens();
|
|
466
520
|
userMarketInfo.ptBalance = TokenAmount(address(PT), userPt);
|
|
467
521
|
userMarketInfo.scyBalance = TokenAmount(address(SCY), userScy);
|
|
468
|
-
(userMarketInfo.assetBalance.assetType, userMarketInfo.assetBalance.assetAddress, ) = SCY
|
|
469
|
-
.assetInfo();
|
|
470
522
|
userMarketInfo.assetBalance.amount = (userScy * SCY.exchangeRate()) / Math.ONE;
|
|
471
523
|
}
|
|
472
524
|
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
"QI": "0x09Fe18C4C0cFE929a6CD40903129F9bA3C837866",
|
|
4
4
|
"USD": "0x2018ecc38fbca2ce3A62f96f9F0D38F0DEE2f99D",
|
|
5
5
|
"qiUSD": "0x884f8d66862b03434E11f4Bd5527A1119c115D83",
|
|
6
|
-
"scyQiUSD": "
|
|
6
|
+
"scyQiUSD": "0x4c91cC2062ABE2000A0E8AdF6b9b3Ceea839EAF7",
|
|
7
7
|
"WAVAX": "0xD323E5337713D2e01fb341D960BC31e1FB42348d",
|
|
8
8
|
"qiAVAX": "0xABD65178Aa35051277b062327A70644F10D3cB9d",
|
|
9
|
-
"scyQiAVAX": "
|
|
9
|
+
"scyQiAVAX": "0xe0c34CeF3980988a71aFC902FD7B12E0c51961E3"
|
|
10
10
|
}
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"yieldContractFactory": "0x2B233F133f3DA67698453F4A251BAF8BAc1E584d",
|
|
9
9
|
"marketFactory": "0xE3a730f28EAe40309A9868Fb5b66B5BaaF531204",
|
|
10
10
|
"router": "0xFEdBED4682D136925d30FFb9B8977CC9b3a6c406",
|
|
11
|
-
"routerStatic": "
|
|
11
|
+
"routerStatic": "0x1436Cb03C753bB9fAc7fcfE5627d08F143D6d8ed",
|
|
12
12
|
"startTime": 1657756800,
|
|
13
13
|
"vePendle": "0xD05B49500F35d879F3Bf220c81BE3ff9d73Ca205",
|
|
14
14
|
"votingController": "0x449f676be160C5C682E1E64934f29641D6096116",
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
"QI": "0x48a6107e24de381E283340871C927A2Fa2844e17",
|
|
4
4
|
"USD": "0x0059a72A5e545F6998AF038aBBB625FC702b1a97",
|
|
5
5
|
"qiUSD": "0x03d73AC818312802536a41e0C9fCbff342B2A62C",
|
|
6
|
-
"scyQiUSD": "
|
|
6
|
+
"scyQiUSD": "0xff1B93a18Ac40CADE55a1F62A19c92ec2e5b0B78",
|
|
7
7
|
"WAVAX": "0xd965c925Fd933029F8e5b7AD0C13bC875a026b09",
|
|
8
8
|
"qiAVAX": "0x7b42e48BEd90Ab5b2392984182B87bfF6B9c8863",
|
|
9
|
-
"scyQiAVAX": "
|
|
9
|
+
"scyQiAVAX": "0xB180706D89f10A3529eEA66aC467dE26eaC7aCc5"
|
|
10
10
|
}
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"yieldContractFactory": "0xa8E22cc2E74dACb43E73cFa89172bfa30eFA0A56",
|
|
9
9
|
"marketFactory": "0x5539C4BCcff8d5881eCb1B95D2f6E7Eb47f0f801",
|
|
10
10
|
"router": "0x24d7CEaFBA7c7b32BE200aD6dA38C03797F0611f",
|
|
11
|
-
"routerStatic": "
|
|
11
|
+
"routerStatic": "0xf68aD0dF5E6034A934bE0e3E8b23Ab77f9778315",
|
|
12
12
|
"startTime": 1657756800,
|
|
13
13
|
"vePendle": "0x35d294d0922838b0899Cbf4C35f4945B2b3D20f1",
|
|
14
14
|
"gaugeController": "0x36e65521b2a1AEBA9a009226e75125cEcf00702f"
|
package/package.json
CHANGED