@pendle/core-v2 0.16.6-testnet → 0.17.0-daily
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/LiquidityMining/CrossChainMsg/PendleMsgReceiveEndpointUpg.sol/PendleMsgReceiveEndpointUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiveEndpointUpg.sol/PendleMsgReceiveEndpointUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiverAppUpg.sol/PendleMsgReceiverAppUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSendEndpointUpg.sol/PendleMsgSendEndpointUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSendEndpointUpg.sol/PendleMsgSendEndpointUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSenderAppUpg.sol/PendleMsgSenderAppUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/FeeDistributor/EpochResultManager.sol/EpochResultManager.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributorFactory.sol/PendleFeeDistributorFactory.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributorFactory.sol/PendleFeeDistributorFactory.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerBaseUpg.sol/PendleGaugeControllerBaseUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/VotingController/VotingControllerStorageUpg.sol/VotingControllerStorageUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.json +16 -5
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowTokenBase.sol/VotingEscrowTokenBase.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowTokenBase.sol/VotingEscrowTokenBase.json +0 -13
- package/build/artifacts/contracts/LiquidityMining/libraries/VeBalanceLib.sol/VeBalanceLib.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeBalanceLib.sol/VeBalanceLib.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/CheckpointHelper.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/CheckpointHelper.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/Checkpoints.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/Checkpoints.json +2 -2
- package/build/artifacts/contracts/LiquidityMining/libraries/WeekMath.sol/WeekMath.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/WeekMath.sol/WeekMath.json +2 -2
- package/build/artifacts/contracts/core/BulkSeller/BulkSeller.sol/BulkSeller.dbg.json +1 -1
- package/build/artifacts/contracts/core/BulkSeller/BulkSeller.sol/BulkSeller.json +2 -53
- package/build/artifacts/contracts/core/BulkSeller/BulkSellerFactory.sol/BulkSellerFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/BulkSeller/BulkSellerFactory.sol/BulkSellerFactory.json +2 -2
- package/build/artifacts/contracts/core/BulkSeller/BulkSellerMathCore.sol/BulkSellerMathCore.dbg.json +1 -1
- package/build/artifacts/contracts/core/BulkSeller/BulkSellerMathCore.sol/BulkSellerMathCore.json +2 -2
- package/build/artifacts/contracts/core/Market/MarketMathCore.sol/MarketMathCore.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/MarketMathCore.sol/MarketMathCore.json +2 -2
- package/build/artifacts/contracts/core/Market/OracleLib.sol/OracleLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/OracleLib.sol/OracleLib.json +2 -2
- package/build/artifacts/contracts/core/Market/PendleGauge.sol/PendleGauge.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 +25 -13
- package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.json +221 -50
- package/build/artifacts/contracts/core/StandardizedYield/PYIndex.sol/PYIndexLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/PYIndex.sol/PYIndexLib.json +2 -2
- package/build/artifacts/contracts/core/StandardizedYield/SYBase.sol/SYBase.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/SYBase.sol/SYBase.json +141 -0
- package/build/artifacts/contracts/core/StandardizedYield/SYBaseWithRewards.sol/SYBaseWithRewards.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/SYBaseWithRewards.sol/SYBaseWithRewards.json +141 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenHelper.sol/PendleQiTokenHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenHelper.sol/PendleQiTokenHelper.json +2 -2
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenSY.sol/PendleQiTokenSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenSY.sol/PendleQiTokenSY.json +143 -2
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveFraxUsdcSY.sol/PendleCurveFraxUsdcSY.dbg.json +4 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveFraxUsdcSY.sol/PendleCurveFraxUsdcSY.json +1144 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveUsdd3CrvSY.sol/PendleCurveUsdd3CrvSY.dbg.json +4 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveUsdd3CrvSY.sol/PendleCurveUsdd3CrvSY.json +1209 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/Curve3CrvPoolHelper.sol/Curve3CrvPoolHelper.dbg.json +4 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/Curve3CrvPoolHelper.sol/Curve3CrvPoolHelper.json +10 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/CurveFraxUsdcPoolHelper.sol/CurveFraxUsdcPoolHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/CurveFraxUsdcPoolHelper.sol/CurveFraxUsdcPoolHelper.json +3 -82
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/CurveUsdd3CrvPoolHelper.sol/CurveUsdd3CrvPoolHelper.dbg.json +4 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/CurveUsdd3CrvPoolHelper.sol/CurveUsdd3CrvPoolHelper.json +10 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/PendleConvexLPSY.sol/PendleConvexLPSY.dbg.json +4 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/{ConvexCurveLP → base}/PendleConvexLPSY.sol/PendleConvexLPSY.json +142 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleLooksStakingSY.sol/PendleLooksStakingSY.dbg.json +4 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleLooksStakingSY.sol/PendleLooksStakingSY.json +997 -0
- package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleWstEthSY.sol/PendleWstEthSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleWstEthSY.sol/PendleWstEthSY.json +143 -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 +83 -10
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.json +35 -4
- package/build/artifacts/contracts/core/erc20/PendleERC20.sol/PendleERC20.dbg.json +1 -1
- package/build/artifacts/contracts/core/erc20/PendleERC20.sol/PendleERC20.json +2 -2
- package/build/artifacts/contracts/core/erc20/PendleERC20Permit.sol/PendleERC20Permit.dbg.json +1 -1
- package/build/artifacts/contracts/core/erc20/PendleERC20Permit.sol/PendleERC20Permit.json +2 -2
- package/build/artifacts/contracts/core/libraries/BaseSplitCodeFactory.sol/BaseSplitCodeFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/BaseSplitCodeFactory.sol/BaseSplitCodeFactory.json +3 -38
- package/build/artifacts/contracts/core/libraries/BaseSplitCodeFactory.sol/CodeDeployer.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/BaseSplitCodeFactory.sol/CodeDeployer.json +2 -2
- package/build/artifacts/contracts/core/libraries/BoringOwnableUpgradeable.sol/BoringOwnableUpgradeable.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/BoringOwnableUpgradeable.sol/BoringOwnableUpgradeableData.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/BoringOwnableUpgradeable.sol/BoringOwnableUpgradeableData.json +2 -2
- package/build/artifacts/contracts/core/libraries/Errors.sol/Errors.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/Errors.sol/Errors.json +105 -31
- package/build/artifacts/contracts/interfaces/ConvexCurve/IBooster.sol/IBooster.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/ConvexCurve/IBooster.sol/IBooster.json +1 -1
- package/build/artifacts/contracts/interfaces/Curve/ICrvPool.sol/ICrvPool.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/Curve/ICrvPool.sol/ICrvPool.json +14 -7
- package/build/artifacts/contracts/interfaces/Curve/ITriCrvPool.sol/ITriCrvPool.dbg.json +4 -0
- package/build/artifacts/contracts/interfaces/Curve/ITriCrvPool.sol/ITriCrvPool.json +213 -0
- package/build/artifacts/contracts/interfaces/IERC4626.sol/IERC4626.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IERC4626.sol/IERC4626.json +1 -1
- package/build/artifacts/contracts/interfaces/ILooksFeeSharing.sol/ILooksFeeSharing.dbg.json +4 -0
- package/build/artifacts/contracts/interfaces/ILooksFeeSharing.sol/ILooksFeeSharing.json +30 -0
- package/build/artifacts/contracts/interfaces/ILooksStaking.sol/ILooksStaking.dbg.json +4 -0
- package/build/artifacts/contracts/interfaces/ILooksStaking.sol/ILooksStaking.json +76 -0
- package/build/artifacts/contracts/interfaces/IPActionAddRemoveLiq.sol/IPActionAddRemoveLiq.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionAddRemoveLiq.sol/IPActionAddRemoveLiq.json +8 -8
- package/build/artifacts/contracts/interfaces/IPActionMintRedeem.sol/IPActionMintRedeem.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMintRedeem.sol/IPActionMintRedeem.json +18 -18
- package/build/artifacts/contracts/interfaces/IPActionSwapPT.sol/IPActionSwapPT.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSwapPTYT.sol/IPActionSwapPTYT.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSwapYT.sol/IPActionSwapYT.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSwapYT.sol/IPActionSwapYT.json +2 -2
- package/build/artifacts/contracts/interfaces/IPAllAction.sol/IPAllAction.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllAction.sol/IPAllAction.json +28 -28
- package/build/artifacts/contracts/interfaces/IPBulkSeller.sol/IPBulkSeller.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPBulkSeller.sol/IPBulkSeller.json +0 -38
- package/build/artifacts/contracts/interfaces/IPBulkSellerFactory.sol/IPBulkSellerFactory.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 +17 -5
- package/build/artifacts/contracts/interfaces/IPMarketFactory.sol/IPMarketFactory.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMarketFactory.sol/IPMarketFactory.json +50 -19
- package/build/artifacts/contracts/interfaces/IPMsgSendEndpoint.sol/IPMsgSendEndpoint.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMsgSendEndpoint.sol/IPMsgSendEndpoint.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingController.sol/IPVotingController.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingEscrowMainchain.sol/IPVotingEscrowMainchain.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldContractFactory.sol/IPYieldContractFactory.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldContractFactory.sol/IPYieldContractFactory.json +7 -7
- package/build/artifacts/contracts/interfaces/IPYieldToken.sol/IPYieldToken.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldToken.sol/IPYieldToken.json +13 -0
- package/build/artifacts/contracts/interfaces/IStandardizedYield.sol/IStandardizedYield.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/BaseSplitCodeFactoryContract.sol/BaseSplitCodeFactoryContract.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/BaseSplitCodeFactoryContract.sol/BaseSplitCodeFactoryContract.json +2 -2
- package/build/artifacts/contracts/offchain-helpers/BulkSellerOffchain.sol/BulkSellerOffchain.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/BulkSellerOffchain.sol/BulkSellerOffchain.json +58 -2
- package/build/artifacts/contracts/offchain-helpers/MarketMathStatic.sol/MarketMathStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/MarketMathStatic.sol/MarketMathStatic.json +2 -46
- package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.json +138 -62
- package/build/artifacts/contracts/router/ActionAddRemoveLiq.sol/ActionAddRemoveLiq.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionAddRemoveLiq.sol/ActionAddRemoveLiq.json +11 -11
- package/build/artifacts/contracts/router/ActionCallback.sol/ActionCallback.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionCallback.sol/ActionCallback.json +2 -2
- package/build/artifacts/contracts/router/ActionMintRedeem.sol/ActionMintRedeem.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionMintRedeem.sol/ActionMintRedeem.json +20 -20
- package/build/artifacts/contracts/router/ActionMisc.sol/ActionMisc.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionMisc.sol/ActionMisc.json +2 -2
- package/build/artifacts/contracts/router/ActionSwapPT.sol/ActionSwapPT.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionSwapPT.sol/ActionSwapPT.json +2 -2
- package/build/artifacts/contracts/router/ActionSwapPTYT.sol/ActionSwapPTYT.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionSwapPTYT.sol/ActionSwapPTYT.json +3 -3
- package/build/artifacts/contracts/router/ActionSwapYT.sol/ActionSwapYT.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionSwapYT.sol/ActionSwapYT.json +4 -4
- package/build/artifacts/contracts/router/PendleRouter.sol/PendleRouter.dbg.json +1 -1
- package/build/artifacts/contracts/router/PendleRouter.sol/PendleRouter.json +2 -186
- package/build/artifacts/contracts/router/base/ActionBaseMintRedeem.sol/ActionBaseMintRedeem.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtInLib.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtInLib.json +2 -2
- package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtOutLib.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtOutLib.json +2 -2
- package/build/artifacts/contracts/router/kyberswap/AggregationRouterHelper.sol/AggregationRouterHelper.dbg.json +1 -1
- package/build/artifacts/contracts/router/kyberswap/AggregationRouterHelper.sol/AggregationRouterHelper.json +2 -2
- package/build/artifacts/contracts/router/kyberswap/KyberSwapHelper.sol/KyberSwapHelper.dbg.json +1 -1
- package/contracts/LiquidityMining/CrossChainMsg/PendleMsgSenderAppUpg.sol +1 -1
- package/contracts/LiquidityMining/GaugeController/PendleGaugeControllerBaseUpg.sol +1 -1
- package/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol +3 -6
- package/contracts/LiquidityMining/VotingController/VotingControllerStorageUpg.sol +1 -1
- package/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol +7 -4
- package/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol +10 -5
- package/contracts/LiquidityMining/VotingEscrow/VotingEscrowTokenBase.sol +3 -6
- package/contracts/LiquidityMining/libraries/VeHistoryLib.sol +0 -5
- package/contracts/LiquidityMining/libraries/WeekMath.sol +1 -1
- package/contracts/core/BulkSeller/BulkSeller.sol +0 -15
- package/contracts/core/BulkSeller/BulkSellerFactory.sol +7 -6
- package/contracts/core/Market/MarketMathCore.sol +52 -11
- package/contracts/core/Market/PendleMarket.sol +35 -22
- package/contracts/core/Market/PendleMarketFactory.sol +67 -35
- package/contracts/core/StandardizedYield/SYBase.sol +26 -3
- package/contracts/core/StandardizedYield/SYBaseWithRewards.sol +3 -1
- package/contracts/core/StandardizedYield/implementations/Convex/PendleCurveFraxUsdcSY.sol +102 -0
- package/contracts/core/StandardizedYield/implementations/Convex/PendleCurveUsdd3CrvSY.sol +160 -0
- package/contracts/core/StandardizedYield/implementations/Convex/README.md +29 -0
- package/contracts/core/StandardizedYield/implementations/Convex/base/Curve3CrvPoolHelper.sol +215 -0
- package/contracts/core/StandardizedYield/implementations/Convex/base/CurveFraxUsdcPoolHelper.sol +46 -26
- package/contracts/core/StandardizedYield/implementations/Convex/base/CurveUsdd3CrvPoolHelper.sol +152 -0
- package/contracts/core/StandardizedYield/implementations/Convex/{ConvexCurveLP → base}/PendleConvexLPSY.sol +0 -0
- package/contracts/core/StandardizedYield/implementations/PendleLooksStakingSY.sol +128 -0
- package/contracts/core/YieldContracts/PendlePrincipalToken.sol +3 -3
- package/contracts/core/YieldContracts/PendleYieldContractFactory.sol +30 -12
- package/contracts/core/YieldContracts/PendleYieldToken.sol +79 -22
- package/contracts/core/erc20/PendleERC20.sol +4 -7
- package/contracts/core/libraries/BaseSplitCodeFactory.sol +1 -1
- package/contracts/core/libraries/BoringOwnableUpgradeable.sol +1 -1
- package/contracts/core/libraries/Errors.sol +12 -2
- package/contracts/interfaces/ConvexCurve/IBooster.sol +1 -1
- package/contracts/interfaces/Curve/ICrvPool.sol +3 -4
- package/contracts/interfaces/Curve/ITriCrvPool.sol +41 -0
- package/contracts/interfaces/IERC4626.sol +1 -1
- package/contracts/interfaces/ILooksFeeSharing.sol +5 -0
- package/contracts/interfaces/ILooksStaking.sol +13 -0
- package/contracts/interfaces/IPActionAddRemoveLiq.sol +4 -4
- package/contracts/interfaces/IPActionMintRedeem.sol +8 -8
- package/contracts/interfaces/IPActionSwapYT.sol +2 -2
- package/contracts/interfaces/IPBulkSeller.sol +0 -4
- package/contracts/interfaces/IPMarket.sol +20 -4
- package/contracts/interfaces/IPMarketFactory.sol +15 -5
- package/contracts/interfaces/IPMsgSendEndpoint.sol +1 -1
- package/contracts/interfaces/IPYieldContractFactory.sol +2 -2
- package/contracts/interfaces/IPYieldToken.sol +2 -0
- package/contracts/interfaces/IStandardizedYield.sol +15 -10
- package/contracts/offchain-helpers/BulkSellerOffchain.sol +17 -8
- package/contracts/offchain-helpers/MarketMathStatic.sol +35 -96
- package/contracts/offchain-helpers/RouterStatic.sol +49 -9
- package/contracts/router/ActionAddRemoveLiq.sol +102 -10
- package/contracts/router/ActionMintRedeem.sol +44 -4
- package/contracts/router/ActionSwapPT.sol +41 -11
- package/contracts/router/ActionSwapPTYT.sol +32 -7
- package/contracts/router/ActionSwapYT.sol +49 -33
- package/contracts/router/PendleRouter.sol +3 -11
- package/contracts/router/base/MarketApproxLib.sol +61 -21
- package/deployments/43113-core.json +19 -14
- package/deployments/43113-markets/WETH-FEB-2ND.json +10 -0
- package/deployments/43113-testenv.json +1 -2
- package/package.json +7 -7
- package/typechain-types/ActionAddRemoveLiq.ts +18 -18
- package/typechain-types/ActionMintRedeem.ts +30 -30
- package/typechain-types/ActionSwapPTYT.ts +5 -5
- package/typechain-types/ActionSwapYT.ts +5 -5
- package/typechain-types/BulkSeller.ts +0 -87
- package/typechain-types/BulkSellerOffchain.ts +74 -0
- package/typechain-types/IBooster.ts +9 -3
- package/typechain-types/ICrvPool.ts +4 -9
- package/typechain-types/IERC4626.ts +5 -5
- package/typechain-types/IPActionAddRemoveLiq.ts +13 -13
- package/typechain-types/IPActionMintRedeem.ts +30 -30
- package/typechain-types/IPActionSwapYT.ts +5 -5
- package/typechain-types/IPAllAction.ts +48 -48
- package/typechain-types/IPBulkSeller.ts +0 -68
- package/typechain-types/IPMarket.ts +26 -16
- package/typechain-types/IPMarketFactory.ts +70 -37
- package/typechain-types/IPMsgSendEndpoint.ts +1 -1
- package/typechain-types/IPYieldContractFactory.ts +11 -11
- package/typechain-types/IPYieldToken.ts +21 -0
- package/typechain-types/MarketMathStatic.ts +0 -67
- package/typechain-types/PendleConvexLPSY.ts +204 -0
- package/typechain-types/PendleMarket.ts +26 -16
- package/typechain-types/PendleMarketFactory.ts +316 -92
- package/typechain-types/PendleQiTokenSY.ts +204 -0
- package/typechain-types/PendleRouter.ts +3 -287
- package/typechain-types/PendleWstEthSY.ts +204 -0
- package/typechain-types/PendleYieldContractFactory.ts +63 -18
- package/typechain-types/PendleYieldToken.ts +42 -0
- package/typechain-types/RouterStatic.ts +65 -7
- package/typechain-types/SYBase.ts +204 -0
- package/typechain-types/SYBaseWithRewards.ts +204 -0
- package/typechain-types/VotingEscrowPendleSidechain.ts +8 -8
- package/typechain-types/VotingEscrowTokenBase.ts +0 -21
- package/typechain-types/factories/ActionAddRemoveLiq__factory.ts +10 -10
- package/typechain-types/factories/ActionCallback__factory.ts +1 -1
- package/typechain-types/factories/ActionMintRedeem__factory.ts +19 -19
- package/typechain-types/factories/ActionMisc__factory.ts +1 -1
- package/typechain-types/factories/ActionSwapPTYT__factory.ts +2 -2
- package/typechain-types/factories/ActionSwapPT__factory.ts +1 -1
- package/typechain-types/factories/ActionSwapYT__factory.ts +3 -3
- package/typechain-types/factories/AggregationRouterHelper__factory.ts +1 -1
- package/typechain-types/factories/BaseSplitCodeFactoryContract__factory.ts +1 -1
- package/typechain-types/factories/BoringOwnableUpgradeableData__factory.ts +1 -1
- package/typechain-types/factories/BulkSellerFactory__factory.ts +1 -1
- package/typechain-types/factories/BulkSellerOffchain__factory.ts +57 -1
- package/typechain-types/factories/BulkSeller__factory.ts +1 -52
- package/typechain-types/factories/Errors__factory.ts +104 -30
- package/typechain-types/factories/IBooster__factory.ts +1 -1
- package/typechain-types/factories/ICrvPool__factory.ts +14 -7
- package/typechain-types/factories/IERC4626__factory.ts +1 -1
- package/typechain-types/factories/IPActionAddRemoveLiq__factory.ts +8 -8
- package/typechain-types/factories/IPActionMintRedeem__factory.ts +18 -18
- package/typechain-types/factories/IPActionSwapYT__factory.ts +2 -2
- package/typechain-types/factories/IPAllAction__factory.ts +28 -28
- package/typechain-types/factories/IPBulkSeller__factory.ts +0 -38
- package/typechain-types/factories/IPMarketFactory__factory.ts +50 -19
- package/typechain-types/factories/IPMarket__factory.ts +17 -5
- package/typechain-types/factories/IPMsgSendEndpoint__factory.ts +1 -1
- package/typechain-types/factories/IPYieldContractFactory__factory.ts +7 -7
- package/typechain-types/factories/IPYieldToken__factory.ts +13 -0
- package/typechain-types/factories/MarketMathStatic__factory.ts +1 -45
- package/typechain-types/factories/OracleLib__factory.ts +1 -1
- package/typechain-types/factories/PendleConvexLPSY__factory.ts +141 -0
- package/typechain-types/factories/PendleCurveFraxUsdcSY__factory.ts +1 -1
- package/typechain-types/factories/PendleCurveUsdd3CrvSY__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/PendleFeeDistributorFactory__factory.ts +1 -1
- package/typechain-types/factories/PendleFeeDistributor__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/PendleLooksStakingSY__factory.ts +1 -1
- package/typechain-types/factories/PendleMarketFactory__factory.ts +220 -49
- package/typechain-types/factories/PendleMarket__factory.ts +18 -6
- package/typechain-types/factories/PendleMsgReceiveEndpointUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleMsgSendEndpointUpg__factory.ts +1 -1
- package/typechain-types/factories/PendlePrincipalToken__factory.ts +1 -1
- package/typechain-types/factories/PendleQiTokenHelper__factory.ts +1 -1
- package/typechain-types/factories/PendleQiTokenSY__factory.ts +142 -1
- package/typechain-types/factories/PendleRouter__factory.ts +1 -185
- package/typechain-types/factories/PendleVotingControllerUpg__factory.ts +1 -1
- package/typechain-types/factories/PendleWstEthSY__factory.ts +142 -1
- package/typechain-types/factories/PendleYieldContractFactory__factory.ts +82 -9
- package/typechain-types/factories/PendleYieldToken__factory.ts +38 -3
- package/typechain-types/factories/RouterStatic__factory.ts +79 -3
- package/typechain-types/factories/SYBaseWithRewards__factory.ts +141 -0
- package/typechain-types/factories/SYBase__factory.ts +141 -0
- package/typechain-types/factories/VotingEscrowPendleMainchain__factory.ts +1 -1
- package/typechain-types/factories/VotingEscrowPendleSidechain__factory.ts +15 -4
- package/typechain-types/factories/VotingEscrowTokenBase__factory.ts +0 -13
- package/typechain-types/hardhat.d.ts +0 -36
- package/typechain-types/index.ts +0 -6
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/ConvexCurveLP/PendleConvexLPSY.sol/PendleConvexLPSY.dbg.json +0 -4
- package/build/artifacts/contracts/offchain-helpers/ImplicitSwapfeeContract.sol/ImplicitSwapfeeContract.dbg.json +0 -4
- package/build/artifacts/contracts/offchain-helpers/ImplicitSwapfeeContract.sol/ImplicitSwapfeeContract.json +0 -182
- package/contracts/offchain-helpers/ImplicitSwapfeeContract.sol +0 -30
- package/deployments/43113-markets/QIWBTC-3RD-FEB.json +0 -11
- package/deployments/43113-markets/benqi-market-QI-AVAX-FEB-2ND.json +0 -9
- package/deployments/43113-markets/benqi-market-QI-USDC-FEB-2ND.json +0 -8
- package/deployments/43113-markets/benqi-market-QI-WETH-DEC-1ST.json +0 -9
- package/deployments/80001-core.json +0 -16
- package/deployments/80001-markets/benqi-market-QI-USDC-FEB-2ND.json +0 -8
- package/deployments/80001-markets/benqi-market-QI-WETH-DEC-1ST.json +0 -8
- package/deployments/80001-testenv.json +0 -22
|
@@ -7,6 +7,7 @@ import "../interfaces/IPActionSwapYT.sol";
|
|
|
7
7
|
import "../interfaces/IPMarket.sol";
|
|
8
8
|
import "../core/libraries/Errors.sol";
|
|
9
9
|
|
|
10
|
+
/// @dev All swap actions will revert if market is expired
|
|
10
11
|
contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
11
12
|
using Math for uint256;
|
|
12
13
|
using Math for int256;
|
|
@@ -21,14 +22,16 @@ contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
|
21
22
|
{}
|
|
22
23
|
|
|
23
24
|
/**
|
|
24
|
-
|
|
25
|
-
|
|
25
|
+
* @notice swap exact SY to YT with the help of flashswaps & YT tokenization / redemption
|
|
26
|
+
* @dev inner working of this function:
|
|
26
27
|
- `exactSyIn` SY is transferred to YT contract
|
|
27
|
-
- `market.swapExactPtForSy` is called, which will transfer SY directly to YT contract &
|
|
28
|
-
|
|
29
|
-
- in callback, all SY in YT contract is used to mint PT + YT, with PT used to pay back the
|
|
30
|
-
|
|
31
|
-
|
|
28
|
+
- `market.swapExactPtForSy` is called, which will transfer more SY directly to YT contract &
|
|
29
|
+
callback is invoked. Note that now we owe PT
|
|
30
|
+
- in callback, all SY in YT contract is used to mint PT + YT, with all PT used to pay back the
|
|
31
|
+
loan, and all YT transferred to the receiver
|
|
32
|
+
* @param exactSyIn will always consume this amount of SY for as much YT as possible
|
|
33
|
+
* @param guessYtOut approximation data for total YT output
|
|
34
|
+
* @dev this function works in conjunction with ActionCallback
|
|
32
35
|
*/
|
|
33
36
|
function swapExactSyForYt(
|
|
34
37
|
address receiver,
|
|
@@ -54,14 +57,15 @@ contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
|
54
57
|
}
|
|
55
58
|
|
|
56
59
|
/**
|
|
57
|
-
|
|
58
|
-
|
|
60
|
+
* @notice swap exact YT to SY with the help of flashswaps & YT tokenization / redemption
|
|
61
|
+
* @dev inner working of this function:
|
|
59
62
|
- `exactYtIn` YT is transferred to YT contract
|
|
60
|
-
- `market.swapSyForExactPt` is called, which will transfer PT directly to YT contract &
|
|
61
|
-
|
|
62
|
-
-
|
|
63
|
-
|
|
64
|
-
|
|
63
|
+
- `market.swapSyForExactPt` is called, which will transfer PT directly to YT contract &
|
|
64
|
+
callback is invoked. Note that now we owe SY.
|
|
65
|
+
- In callback, all PT + YT in YT contract is used to redeem SY. A portion of SY is used to
|
|
66
|
+
payback the loan, the rest is transferred to the `receiver`
|
|
67
|
+
* @param exactYtIn will consume exactly this much YT for as much SY as possible
|
|
68
|
+
* @dev this function works in conjunction with ActionCallback
|
|
65
69
|
*/
|
|
66
70
|
function swapExactYtForSy(
|
|
67
71
|
address receiver,
|
|
@@ -79,13 +83,14 @@ contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
|
79
83
|
}
|
|
80
84
|
|
|
81
85
|
/**
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
- `market.swapExactPtForSy` is called, which will transfer SY directly to YT contract &
|
|
85
|
-
|
|
86
|
-
-
|
|
87
|
-
|
|
88
|
-
|
|
86
|
+
* @notice swap SY to exact YT with the help of flashswaps & YT tokenization / redemption
|
|
87
|
+
* @dev inner working of this function:
|
|
88
|
+
- `market.swapExactPtForSy` is called, which will transfer SY directly to YT contract &
|
|
89
|
+
callback is invoked. Note that now we owe PT
|
|
90
|
+
- In callback, we will pull in more SY as needed from caller & mint all SY to PT + YT. PT is
|
|
91
|
+
then used to payback the loan, while YT is transferred to `receiver`
|
|
92
|
+
* @param exactYtOut will output exactly this amount of YT, no approximation is used
|
|
93
|
+
* @dev this function works in conjunction with ActionCallback
|
|
89
94
|
*/
|
|
90
95
|
function swapSyForExactYt(
|
|
91
96
|
address receiver,
|
|
@@ -109,14 +114,15 @@ contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
|
109
114
|
}
|
|
110
115
|
|
|
111
116
|
/**
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
-
|
|
115
|
-
- `
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
117
|
+
* @notice swap YT to exact SY with the help of flashswaps & YT tokenization / redemption
|
|
118
|
+
* @dev inner working of this function:
|
|
119
|
+
- Approximates `netYtIn` using the data from `guessYtIn`
|
|
120
|
+
- Pulls `netYtIn` amount of YT from caller
|
|
121
|
+
- `market.swapSyForExactPt` is called, which will transfer PT directly to YT contract &
|
|
122
|
+
callback is invoked. Note that now we owe SY
|
|
123
|
+
- In callback, we will redeem all PT + YT to get SY. A portion of it is used to payback the
|
|
124
|
+
loan. The rest is transferred to `receiver`
|
|
125
|
+
* @dev this function works in conjunction with ActionCallback
|
|
120
126
|
*/
|
|
121
127
|
function swapYtForExactSy(
|
|
122
128
|
address receiver,
|
|
@@ -125,7 +131,7 @@ contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
|
125
131
|
uint256 maxYtIn,
|
|
126
132
|
ApproxParams memory guessYtIn
|
|
127
133
|
) external returns (uint256 netYtIn, uint256 netSyFee) {
|
|
128
|
-
MarketState memory state = IPMarket(market).readState();
|
|
134
|
+
MarketState memory state = IPMarket(market).readState(address(this));
|
|
129
135
|
(, , IPYieldToken YT) = IPMarket(market).readTokens();
|
|
130
136
|
|
|
131
137
|
(netYtIn, , ) = state.approxSwapYtForExactSy(
|
|
@@ -148,6 +154,11 @@ contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
|
148
154
|
emit SwapYtAndSy(msg.sender, market, receiver, netYtIn.neg(), exactSyOut.Int());
|
|
149
155
|
}
|
|
150
156
|
|
|
157
|
+
/**
|
|
158
|
+
* @notice swaps any token to YT
|
|
159
|
+
* @dev this function swaps token for SY-mintable token first through Kyberswap, then mints SY
|
|
160
|
+
* from such, finally swaps SY to YT (see `swapSyForExactYt()`)
|
|
161
|
+
*/
|
|
151
162
|
function swapExactTokenForYt(
|
|
152
163
|
address receiver,
|
|
153
164
|
address market,
|
|
@@ -171,13 +182,18 @@ contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
|
171
182
|
emit SwapYtAndToken(
|
|
172
183
|
msg.sender,
|
|
173
184
|
market,
|
|
174
|
-
receiver,
|
|
175
185
|
input.tokenIn,
|
|
186
|
+
receiver,
|
|
176
187
|
netYtOut.Int(),
|
|
177
188
|
input.netTokenIn.neg()
|
|
178
189
|
);
|
|
179
190
|
}
|
|
180
191
|
|
|
192
|
+
/**
|
|
193
|
+
* @notice swaps YT to a given token
|
|
194
|
+
* @dev the function first swaps YT to SY (see `swapExactYtForSy()`), then redeems SY,
|
|
195
|
+
* finally swaps resulting tokens to desired output token using Kyberswap
|
|
196
|
+
*/
|
|
181
197
|
function swapExactYtForToken(
|
|
182
198
|
address receiver,
|
|
183
199
|
address market,
|
|
@@ -204,8 +220,8 @@ contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
|
204
220
|
emit SwapYtAndToken(
|
|
205
221
|
msg.sender,
|
|
206
222
|
market,
|
|
207
|
-
receiver,
|
|
208
223
|
output.tokenOut,
|
|
224
|
+
receiver,
|
|
209
225
|
netYtIn.neg(),
|
|
210
226
|
netTokenOut.Int()
|
|
211
227
|
);
|
|
@@ -219,7 +235,7 @@ contract ActionSwapYT is IPActionSwapYT, ActionBaseMintRedeem, CallbackHelper {
|
|
|
219
235
|
uint256 minYtOut,
|
|
220
236
|
ApproxParams memory guessYtOut
|
|
221
237
|
) internal returns (uint256 netYtOut, uint256 netSyFee) {
|
|
222
|
-
MarketState memory state = IPMarket(market).readState();
|
|
238
|
+
MarketState memory state = IPMarket(market).readState(address(this));
|
|
223
239
|
|
|
224
240
|
(netYtOut, ) = state.approxSwapExactSyForYt(
|
|
225
241
|
YT.newIndex(),
|
|
@@ -5,7 +5,6 @@ import "@openzeppelin/contracts/proxy/utils/UUPSUpgradeable.sol";
|
|
|
5
5
|
import "@openzeppelin/contracts/proxy/Proxy.sol";
|
|
6
6
|
import "../interfaces/IPAllAction.sol";
|
|
7
7
|
import "../interfaces/IPMarketSwapCallback.sol";
|
|
8
|
-
import "../core/libraries/BoringOwnableUpgradeable.sol";
|
|
9
8
|
import "../core/libraries/Errors.sol";
|
|
10
9
|
|
|
11
10
|
/// @dev this contract will be deployed behind an ERC1967 proxy
|
|
@@ -13,7 +12,7 @@ import "../core/libraries/Errors.sol";
|
|
|
13
12
|
/// corresponding implementation contracts
|
|
14
13
|
|
|
15
14
|
// solhint-disable no-empty-blocks
|
|
16
|
-
contract PendleRouter is Proxy
|
|
15
|
+
contract PendleRouter is Proxy {
|
|
17
16
|
address public immutable ACTION_MINT_REDEEM;
|
|
18
17
|
address public immutable ACTION_ADD_REMOVE_LIQ;
|
|
19
18
|
address public immutable ACTION_SWAP_PT;
|
|
@@ -30,7 +29,7 @@ contract PendleRouter is Proxy, Initializable, UUPSUpgradeable, BoringOwnableUpg
|
|
|
30
29
|
address _ACTION_SWAP_PTYT,
|
|
31
30
|
address _ACTION_CALLBACK,
|
|
32
31
|
address _ACTION_MISC
|
|
33
|
-
)
|
|
32
|
+
) {
|
|
34
33
|
ACTION_MINT_REDEEM = _ACTION_MINT_REDEEM;
|
|
35
34
|
ACTION_ADD_REMOVE_LIQ = _ACTION_ADD_REMOVE_LIQ;
|
|
36
35
|
ACTION_SWAP_PT = _ACTION_SWAP_PT;
|
|
@@ -40,12 +39,7 @@ contract PendleRouter is Proxy, Initializable, UUPSUpgradeable, BoringOwnableUpg
|
|
|
40
39
|
ACTION_MISC = _ACTION_MISC;
|
|
41
40
|
}
|
|
42
41
|
|
|
43
|
-
receive() external payable virtual override {
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
function initialize() external initializer {
|
|
47
|
-
__BoringOwnable_init();
|
|
48
|
-
}
|
|
42
|
+
receive() external payable virtual override {}
|
|
49
43
|
|
|
50
44
|
function getRouterImplementation(bytes4 sig) public view returns (address) {
|
|
51
45
|
if (
|
|
@@ -103,8 +97,6 @@ contract PendleRouter is Proxy, Initializable, UUPSUpgradeable, BoringOwnableUpg
|
|
|
103
97
|
revert Errors.RouterInvalidAction(sig);
|
|
104
98
|
}
|
|
105
99
|
|
|
106
|
-
function _authorizeUpgrade(address newImplementation) internal override onlyOwner {}
|
|
107
|
-
|
|
108
100
|
function _implementation() internal view override returns (address) {
|
|
109
101
|
return getRouterImplementation(msg.sig);
|
|
110
102
|
}
|
|
@@ -24,7 +24,8 @@ struct ApproxParams {
|
|
|
24
24
|
|
|
25
25
|
/// for guessOffchain, this is to provide a shortcut to guessing. The offchain SDK can precalculate the exact result
|
|
26
26
|
/// before the tx is sent. When the tx reaches the contract, the guessOffchain will be checked first, and if it satisfies the
|
|
27
|
-
/// approximation, it will be used (and save all the guessing).
|
|
27
|
+
/// approximation, it will be used (and save all the guessing). It's expected that this shortcut will be used in most cases
|
|
28
|
+
/// except in cases that there is a trade in the same market right before the tx
|
|
28
29
|
}
|
|
29
30
|
|
|
30
31
|
library MarketApproxPtInLib {
|
|
@@ -84,7 +85,7 @@ library MarketApproxPtInLib {
|
|
|
84
85
|
continue;
|
|
85
86
|
}
|
|
86
87
|
|
|
87
|
-
(uint256 netSyOut, uint256 netSyFee) = calcSyOut(a.market, comp, a.index, guess);
|
|
88
|
+
(uint256 netSyOut, uint256 netSyFee, ) = calcSyOut(a.market, comp, a.index, guess);
|
|
88
89
|
|
|
89
90
|
if (netSyOut >= a.minSyOut) {
|
|
90
91
|
p.guessMax = guess;
|
|
@@ -146,7 +147,7 @@ library MarketApproxPtInLib {
|
|
|
146
147
|
continue;
|
|
147
148
|
}
|
|
148
149
|
|
|
149
|
-
(uint256 netSyOut, uint256 netSyFee) = calcSyOut(a.market, comp, a.index, guess);
|
|
150
|
+
(uint256 netSyOut, uint256 netSyFee, ) = calcSyOut(a.market, comp, a.index, guess);
|
|
150
151
|
|
|
151
152
|
uint256 maxPtPayable = a.index.syToAsset(netSyOut + a.exactSyIn);
|
|
152
153
|
|
|
@@ -155,7 +156,7 @@ library MarketApproxPtInLib {
|
|
|
155
156
|
bool isAnswerAccepted = Math.isASmallerApproxB(guess, maxPtPayable, p.eps);
|
|
156
157
|
if (isAnswerAccepted) return (guess, netSyFee);
|
|
157
158
|
} else {
|
|
158
|
-
p.guessMax = guess;
|
|
159
|
+
p.guessMax = guess - 1;
|
|
159
160
|
}
|
|
160
161
|
}
|
|
161
162
|
revert Errors.ApproxFail();
|
|
@@ -211,14 +212,18 @@ library MarketApproxPtInLib {
|
|
|
211
212
|
continue;
|
|
212
213
|
}
|
|
213
214
|
|
|
214
|
-
(uint256 netSyOut, uint256 netSyFee) = calcSyOut(
|
|
215
|
+
(uint256 netSyOut, uint256 netSyFee, uint256 netSyToReserve) = calcSyOut(
|
|
216
|
+
a.market,
|
|
217
|
+
comp,
|
|
218
|
+
a.index,
|
|
219
|
+
guess
|
|
220
|
+
);
|
|
215
221
|
|
|
216
222
|
uint256 syNumerator;
|
|
217
223
|
uint256 ptNumerator;
|
|
218
224
|
{
|
|
219
225
|
uint256 newTotalPt = a.market.totalPt.Uint() + guess;
|
|
220
|
-
uint256
|
|
221
|
-
uint256 newTotalSy = (a.market.totalSy.Uint() - netSyOut - netSyFee);
|
|
226
|
+
uint256 newTotalSy = (a.market.totalSy.Uint() - netSyOut - netSyToReserve);
|
|
222
227
|
|
|
223
228
|
// it is desired that
|
|
224
229
|
// netSyOut / newTotalSy = netPtRemaining / newTotalPt
|
|
@@ -226,7 +231,7 @@ library MarketApproxPtInLib {
|
|
|
226
231
|
// netSyOut * newTotalPt = netPtRemaining * newTotalSy
|
|
227
232
|
|
|
228
233
|
syNumerator = netSyOut * newTotalPt;
|
|
229
|
-
ptNumerator =
|
|
234
|
+
ptNumerator = (a.totalPtIn - guess) * newTotalSy;
|
|
230
235
|
}
|
|
231
236
|
|
|
232
237
|
if (Math.isAApproxB(syNumerator, ptNumerator, p.eps)) {
|
|
@@ -292,7 +297,7 @@ library MarketApproxPtInLib {
|
|
|
292
297
|
continue;
|
|
293
298
|
}
|
|
294
299
|
|
|
295
|
-
(uint256 netSyOut, uint256 netSyFee) = calcSyOut(a.market, comp, a.index, guess);
|
|
300
|
+
(uint256 netSyOut, uint256 netSyFee, ) = calcSyOut(a.market, comp, a.index, guess);
|
|
296
301
|
|
|
297
302
|
uint256 netAssetOut = a.index.syToAsset(netSyOut);
|
|
298
303
|
|
|
@@ -316,10 +321,23 @@ library MarketApproxPtInLib {
|
|
|
316
321
|
MarketPreCompute memory comp,
|
|
317
322
|
PYIndex index,
|
|
318
323
|
uint256 netPtIn
|
|
319
|
-
)
|
|
320
|
-
|
|
324
|
+
)
|
|
325
|
+
internal
|
|
326
|
+
pure
|
|
327
|
+
returns (
|
|
328
|
+
uint256 netSyOut,
|
|
329
|
+
uint256 netSyFee,
|
|
330
|
+
uint256 netSyToReserve
|
|
331
|
+
)
|
|
332
|
+
{
|
|
333
|
+
(int256 _netSyOut, int256 _netSyFee, int256 _netSyToReserve) = market.calcTrade(
|
|
334
|
+
comp,
|
|
335
|
+
index,
|
|
336
|
+
netPtIn.neg()
|
|
337
|
+
);
|
|
321
338
|
netSyOut = _netSyOut.Uint();
|
|
322
339
|
netSyFee = _netSyFee.Uint();
|
|
340
|
+
netSyToReserve = _netSyToReserve.Uint();
|
|
323
341
|
}
|
|
324
342
|
|
|
325
343
|
function newApproxParamsPtIn(
|
|
@@ -447,7 +465,7 @@ library MarketApproxPtOutLib {
|
|
|
447
465
|
for (uint256 iter = 0; iter < p.maxIteration; ++iter) {
|
|
448
466
|
uint256 guess = nextGuess(p, iter);
|
|
449
467
|
|
|
450
|
-
(uint256 netSyIn, uint256 netSyFee) = calcSyIn(a.market, comp, a.index, guess);
|
|
468
|
+
(uint256 netSyIn, uint256 netSyFee, ) = calcSyIn(a.market, comp, a.index, guess);
|
|
451
469
|
|
|
452
470
|
if (netSyIn <= a.exactSyIn) {
|
|
453
471
|
p.guessMin = guess;
|
|
@@ -502,7 +520,7 @@ library MarketApproxPtOutLib {
|
|
|
502
520
|
for (uint256 iter = 0; iter < p.maxIteration; ++iter) {
|
|
503
521
|
uint256 guess = nextGuess(p, iter);
|
|
504
522
|
|
|
505
|
-
(uint256 netSyOwed, uint256 netSyFee) = calcSyIn(a.market, comp, a.index, guess);
|
|
523
|
+
(uint256 netSyOwed, uint256 netSyFee, ) = calcSyIn(a.market, comp, a.index, guess);
|
|
506
524
|
|
|
507
525
|
uint256 netAssetToRepay = a.index.syToAssetUp(netSyOwed);
|
|
508
526
|
uint256 netSyOut = a.index.assetToSy(guess - netAssetToRepay);
|
|
@@ -562,7 +580,12 @@ library MarketApproxPtOutLib {
|
|
|
562
580
|
for (uint256 iter = 0; iter < p.maxIteration; ++iter) {
|
|
563
581
|
uint256 guess = nextGuess(p, iter);
|
|
564
582
|
|
|
565
|
-
(uint256 netSyIn, uint256 netSyFee) = calcSyIn(
|
|
583
|
+
(uint256 netSyIn, uint256 netSyFee, uint256 netSyToReserve) = calcSyIn(
|
|
584
|
+
a.market,
|
|
585
|
+
comp,
|
|
586
|
+
a.index,
|
|
587
|
+
guess
|
|
588
|
+
);
|
|
566
589
|
|
|
567
590
|
if (netSyIn > a.totalSyIn) {
|
|
568
591
|
p.guessMax = guess - 1;
|
|
@@ -573,9 +596,8 @@ library MarketApproxPtOutLib {
|
|
|
573
596
|
uint256 ptNumerator;
|
|
574
597
|
|
|
575
598
|
{
|
|
576
|
-
uint256 netSyRemaining = a.totalSyIn - netSyIn;
|
|
577
599
|
uint256 newTotalPt = a.market.totalPt.Uint() - guess;
|
|
578
|
-
uint256 netTotalSy = a.market.totalSy.Uint() + netSyIn -
|
|
600
|
+
uint256 netTotalSy = a.market.totalSy.Uint() + netSyIn - netSyToReserve;
|
|
579
601
|
|
|
580
602
|
// it is desired that
|
|
581
603
|
// netPtFromSwap / newTotalPt = netSyRemaining / netTotalSy
|
|
@@ -583,7 +605,7 @@ library MarketApproxPtOutLib {
|
|
|
583
605
|
// netPtFromSwap * netTotalSy = netSyRemaining * newTotalPt
|
|
584
606
|
|
|
585
607
|
ptNumerator = guess * netTotalSy;
|
|
586
|
-
syNumerator =
|
|
608
|
+
syNumerator = (a.totalSyIn - netSyIn) * newTotalPt;
|
|
587
609
|
}
|
|
588
610
|
|
|
589
611
|
if (Math.isAApproxB(ptNumerator, syNumerator, p.eps)) {
|
|
@@ -650,7 +672,7 @@ library MarketApproxPtOutLib {
|
|
|
650
672
|
for (uint256 iter = 0; iter < p.maxIteration; ++iter) {
|
|
651
673
|
uint256 guess = nextGuess(p, iter);
|
|
652
674
|
|
|
653
|
-
(uint256 netSyOwed, uint256 netSyFee) = calcSyIn(a.market, comp, a.index, guess);
|
|
675
|
+
(uint256 netSyOwed, uint256 netSyFee, ) = calcSyIn(a.market, comp, a.index, guess);
|
|
654
676
|
|
|
655
677
|
if (netSyOwed <= a.maxSyPayable) {
|
|
656
678
|
p.guessMin = guess;
|
|
@@ -671,11 +693,24 @@ library MarketApproxPtOutLib {
|
|
|
671
693
|
MarketPreCompute memory comp,
|
|
672
694
|
PYIndex index,
|
|
673
695
|
uint256 netPtOut
|
|
674
|
-
)
|
|
675
|
-
|
|
696
|
+
)
|
|
697
|
+
internal
|
|
698
|
+
pure
|
|
699
|
+
returns (
|
|
700
|
+
uint256 netSyIn,
|
|
701
|
+
uint256 netSyFee,
|
|
702
|
+
uint256 netSyToReserve
|
|
703
|
+
)
|
|
704
|
+
{
|
|
705
|
+
(int256 _netSyIn, int256 _netSyFee, int256 _netSyToReserve) = market.calcTrade(
|
|
706
|
+
comp,
|
|
707
|
+
index,
|
|
708
|
+
netPtOut.Int()
|
|
709
|
+
);
|
|
676
710
|
|
|
677
711
|
netSyIn = _netSyIn.abs();
|
|
678
712
|
netSyFee = _netSyFee.Uint();
|
|
713
|
+
netSyToReserve = _netSyToReserve.Uint();
|
|
679
714
|
}
|
|
680
715
|
|
|
681
716
|
function newApproxParamsPtOut(
|
|
@@ -690,7 +725,12 @@ library MarketApproxPtOutLib {
|
|
|
690
725
|
res.guessMax = Math.min(_approx.guessMax, maxGuessMax);
|
|
691
726
|
|
|
692
727
|
if (res.guessMin > res.guessMax)
|
|
693
|
-
revert Errors.ApproxBinarySearchInputInvalid(
|
|
728
|
+
revert Errors.ApproxBinarySearchInputInvalid(
|
|
729
|
+
_approx.guessMin,
|
|
730
|
+
_approx.guessMax,
|
|
731
|
+
minGuessMin,
|
|
732
|
+
maxGuessMax
|
|
733
|
+
);
|
|
694
734
|
|
|
695
735
|
res.guessOffchain = _approx.guessOffchain;
|
|
696
736
|
res.maxIteration = _approx.maxIteration;
|
|
@@ -1,17 +1,22 @@
|
|
|
1
1
|
{
|
|
2
2
|
"deployer": "0x1FcCC097db89A86Bfc474A1028F93958295b1Fb7",
|
|
3
|
-
"network":
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
"
|
|
3
|
+
"network": {
|
|
4
|
+
"chainId": 43113,
|
|
5
|
+
"treasury": "0x243b7CFD29AcAF9cDe98C1958902FAA3B1F095D5",
|
|
6
|
+
"governance": "0x1FcCC097db89A86Bfc474A1028F93958295b1Fb7",
|
|
7
|
+
"pendle": "0x808507121b80c02388fad14726482e061b8da827",
|
|
8
|
+
"lzEndpoint": "0x93f54D755A063cE7bB9e6Ac47Eccc8e33411d706",
|
|
9
|
+
"wrappedNative": "0xe43a7aD7C09d8fAE3ADe7361f0b847b23adD5094"
|
|
10
|
+
},
|
|
11
|
+
"splitter": "0x4B3B9f8f65E1c3fde4073874c2C93a1760F11035",
|
|
12
|
+
"PENDLE": "0x808507121b80c02388fad14726482e061b8da827",
|
|
13
|
+
"yieldContractFactory": "0xD3DC187247539380C3AAbFdb2D09c341910fFE83",
|
|
14
|
+
"marketFactory": "0x74D8b7eC36C0ff4157bD359B6D3Ab82a5d741B8E",
|
|
15
|
+
"bulkSellerFactory": "0x640bDc3daF9cFDb33CC67e46180A4E6c0495D0f4",
|
|
16
|
+
"router": "0x5334471de92CDBeB4245d3a3B1aF93b4DfDa8cC9",
|
|
17
|
+
"routerStatic": "0xd1dCaC6f75361A7C734863BC17B126EcB873192C",
|
|
18
|
+
"vePendle": "0x2d7e1Ab594E218eBd473bBE3aF57fAD5541F10f9",
|
|
19
|
+
"senderEndpoint": "0x33D7a94070A697E5CAe134A409ef42cfDba4F3b1",
|
|
20
|
+
"votingController": "0xdc8D6a5Db65287af491199244459e5C57d62f3f8",
|
|
21
|
+
"gaugeController": "0xd7D67E0b7DcF4665222809868512cAf6ac99C736"
|
|
17
22
|
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "SY Benqi WETH",
|
|
3
|
+
"SY": "0x5C90c945C0f7Ad4D8C3d1746185262bB9499eCF0",
|
|
4
|
+
"YT": "0xe85DFab309ED388d75E4C3665a77C73C6C0BA630",
|
|
5
|
+
"PT": "0x27DaeA7A12A9499F8065631756FEE5A9ACbd105a",
|
|
6
|
+
"market": "0x096206b71CA3610724F780B9af6c2D47938A345C",
|
|
7
|
+
"expiry": 1675382400,
|
|
8
|
+
"scalarRoot": "62000000000000000000",
|
|
9
|
+
"initAnchor": "1012600000000000000"
|
|
10
|
+
}
|
|
@@ -10,8 +10,7 @@
|
|
|
10
10
|
"WETH": "0x1e2e40697603CA5b5ffc102c9D7A3310EA3f2Aa3",
|
|
11
11
|
"qiUSDC": "0xEE3a174F1478198fBc669132B1e2cc13B5686F94",
|
|
12
12
|
"qiWETH": "0xE5710EC5e4CeB255fb14d2c2BFC93E64d0c30A2c",
|
|
13
|
-
"qiAVAX": "0xf9aEd3b927dce44C6d53B334Cb759f4D230D9b9c"
|
|
14
|
-
"qiWBTC": "0xb847E93A481E50E6C289ff9559A8405aD225210B"
|
|
13
|
+
"qiAVAX": "0xf9aEd3b927dce44C6d53B334Cb759f4D230D9b9c"
|
|
15
14
|
},
|
|
16
15
|
"benqi": {
|
|
17
16
|
"comptroller": "0x4Af3e9CA6f86E655C01f03C13519BcAF867286EE",
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@pendle/core-v2",
|
|
3
3
|
"description": "Core smart contracts of Pendle Protocol.",
|
|
4
4
|
"license": "BUSL-1.1",
|
|
5
|
-
"version": "0.
|
|
5
|
+
"version": "0.17.0-daily",
|
|
6
6
|
"homepage": "https://pendle.finance",
|
|
7
7
|
"keywords": [
|
|
8
8
|
"pendle",
|
|
@@ -25,16 +25,16 @@
|
|
|
25
25
|
"devDependencies": {
|
|
26
26
|
"@typechain/ethers-v5": "^9.0.0",
|
|
27
27
|
"@typechain/hardhat": "^4.0.0",
|
|
28
|
-
"hardhat": "^2.12.
|
|
28
|
+
"hardhat": "^2.12.2",
|
|
29
29
|
"hardhat-contract-sizer": "^2.6.1",
|
|
30
30
|
"hardhat-storage-layout-diff": "^0.0.4",
|
|
31
31
|
"prettier": "^2.7.1",
|
|
32
|
-
"prettier-plugin-solidity": "^1.0.0-
|
|
32
|
+
"prettier-plugin-solidity": "^1.0.0-rc.1",
|
|
33
33
|
"solc": "^0.8.17",
|
|
34
34
|
"solhint": "^3.3.7",
|
|
35
35
|
"ts-node": "^10.9.1",
|
|
36
|
-
"typechain": "^8.1.
|
|
37
|
-
"typescript": "^4.
|
|
36
|
+
"typechain": "^8.1.1",
|
|
37
|
+
"typescript": "^4.9.3"
|
|
38
38
|
},
|
|
39
39
|
"scripts": {
|
|
40
40
|
"compile": "yarn hardhat compile",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
},
|
|
45
45
|
"packageManager": "yarn@3.2.2",
|
|
46
46
|
"dependencies": {
|
|
47
|
-
"@openzeppelin/contracts": "
|
|
48
|
-
"@openzeppelin/contracts-upgradeable": "
|
|
47
|
+
"@openzeppelin/contracts": "4.7.3",
|
|
48
|
+
"@openzeppelin/contracts-upgradeable": "4.7.3"
|
|
49
49
|
}
|
|
50
50
|
}
|
|
@@ -208,7 +208,7 @@ export interface ActionAddRemoveLiqInterface extends utils.Interface {
|
|
|
208
208
|
"AddLiquiditySingleSy(address,address,address,uint256,uint256)": EventFragment;
|
|
209
209
|
"AddLiquiditySingleToken(address,address,address,address,uint256,uint256)": EventFragment;
|
|
210
210
|
"RemoveLiquidityDualSyAndPt(address,address,address,uint256,uint256,uint256)": EventFragment;
|
|
211
|
-
"RemoveLiquidityDualTokenAndPt(address,address,address,uint256,uint256,
|
|
211
|
+
"RemoveLiquidityDualTokenAndPt(address,address,address,address,uint256,uint256,uint256)": EventFragment;
|
|
212
212
|
"RemoveLiquiditySinglePt(address,address,address,uint256,uint256)": EventFragment;
|
|
213
213
|
"RemoveLiquiditySingleSy(address,address,address,uint256,uint256)": EventFragment;
|
|
214
214
|
"RemoveLiquiditySingleToken(address,address,address,address,uint256,uint256)": EventFragment;
|
|
@@ -248,8 +248,8 @@ export type AddLiquidityDualTokenAndPtEvent = TypedEvent<
|
|
|
248
248
|
{
|
|
249
249
|
caller: string;
|
|
250
250
|
market: string;
|
|
251
|
-
receiver: string;
|
|
252
251
|
tokenIn: string;
|
|
252
|
+
receiver: string;
|
|
253
253
|
netTokenUsed: BigNumber;
|
|
254
254
|
netPtUsed: BigNumber;
|
|
255
255
|
netLpOut: BigNumber;
|
|
@@ -318,14 +318,14 @@ export type RemoveLiquidityDualSyAndPtEventFilter =
|
|
|
318
318
|
TypedEventFilter<RemoveLiquidityDualSyAndPtEvent>;
|
|
319
319
|
|
|
320
320
|
export type RemoveLiquidityDualTokenAndPtEvent = TypedEvent<
|
|
321
|
-
[string, string, string,
|
|
321
|
+
[string, string, string, string, BigNumber, BigNumber, BigNumber],
|
|
322
322
|
{
|
|
323
323
|
caller: string;
|
|
324
324
|
market: string;
|
|
325
|
+
tokenOut: string;
|
|
325
326
|
receiver: string;
|
|
326
327
|
netLpToRemove: BigNumber;
|
|
327
328
|
netPtOut: BigNumber;
|
|
328
|
-
tokenOut: string;
|
|
329
329
|
netTokenOut: BigNumber;
|
|
330
330
|
}
|
|
331
331
|
>;
|
|
@@ -474,7 +474,7 @@ export interface ActionAddRemoveLiq extends BaseContract {
|
|
|
474
474
|
market: string,
|
|
475
475
|
netLpToRemove: BigNumberish,
|
|
476
476
|
minPtOut: BigNumberish,
|
|
477
|
-
|
|
477
|
+
guessPtReceivedFromSy: ApproxParamsStruct,
|
|
478
478
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
479
479
|
): Promise<ContractTransaction>;
|
|
480
480
|
|
|
@@ -565,7 +565,7 @@ export interface ActionAddRemoveLiq extends BaseContract {
|
|
|
565
565
|
market: string,
|
|
566
566
|
netLpToRemove: BigNumberish,
|
|
567
567
|
minPtOut: BigNumberish,
|
|
568
|
-
|
|
568
|
+
guessPtReceivedFromSy: ApproxParamsStruct,
|
|
569
569
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
570
570
|
): Promise<ContractTransaction>;
|
|
571
571
|
|
|
@@ -678,7 +678,7 @@ export interface ActionAddRemoveLiq extends BaseContract {
|
|
|
678
678
|
market: string,
|
|
679
679
|
netLpToRemove: BigNumberish,
|
|
680
680
|
minPtOut: BigNumberish,
|
|
681
|
-
|
|
681
|
+
guessPtReceivedFromSy: ApproxParamsStruct,
|
|
682
682
|
overrides?: CallOverrides
|
|
683
683
|
): Promise<
|
|
684
684
|
[BigNumber, BigNumber] & { netPtOut: BigNumber; netSyFee: BigNumber }
|
|
@@ -726,8 +726,8 @@ export interface ActionAddRemoveLiq extends BaseContract {
|
|
|
726
726
|
"AddLiquidityDualTokenAndPt(address,address,address,address,uint256,uint256,uint256)"(
|
|
727
727
|
caller?: string | null,
|
|
728
728
|
market?: string | null,
|
|
729
|
-
|
|
730
|
-
|
|
729
|
+
tokenIn?: string | null,
|
|
730
|
+
receiver?: null,
|
|
731
731
|
netTokenUsed?: null,
|
|
732
732
|
netPtUsed?: null,
|
|
733
733
|
netLpOut?: null
|
|
@@ -735,8 +735,8 @@ export interface ActionAddRemoveLiq extends BaseContract {
|
|
|
735
735
|
AddLiquidityDualTokenAndPt(
|
|
736
736
|
caller?: string | null,
|
|
737
737
|
market?: string | null,
|
|
738
|
-
|
|
739
|
-
|
|
738
|
+
tokenIn?: string | null,
|
|
739
|
+
receiver?: null,
|
|
740
740
|
netTokenUsed?: null,
|
|
741
741
|
netPtUsed?: null,
|
|
742
742
|
netLpOut?: null
|
|
@@ -806,22 +806,22 @@ export interface ActionAddRemoveLiq extends BaseContract {
|
|
|
806
806
|
netSyOut?: null
|
|
807
807
|
): RemoveLiquidityDualSyAndPtEventFilter;
|
|
808
808
|
|
|
809
|
-
"RemoveLiquidityDualTokenAndPt(address,address,address,uint256,uint256,
|
|
809
|
+
"RemoveLiquidityDualTokenAndPt(address,address,address,address,uint256,uint256,uint256)"(
|
|
810
810
|
caller?: string | null,
|
|
811
811
|
market?: string | null,
|
|
812
|
-
|
|
812
|
+
tokenOut?: string | null,
|
|
813
|
+
receiver?: null,
|
|
813
814
|
netLpToRemove?: null,
|
|
814
815
|
netPtOut?: null,
|
|
815
|
-
tokenOut?: null,
|
|
816
816
|
netTokenOut?: null
|
|
817
817
|
): RemoveLiquidityDualTokenAndPtEventFilter;
|
|
818
818
|
RemoveLiquidityDualTokenAndPt(
|
|
819
819
|
caller?: string | null,
|
|
820
820
|
market?: string | null,
|
|
821
|
-
|
|
821
|
+
tokenOut?: string | null,
|
|
822
|
+
receiver?: null,
|
|
822
823
|
netLpToRemove?: null,
|
|
823
824
|
netPtOut?: null,
|
|
824
|
-
tokenOut?: null,
|
|
825
825
|
netTokenOut?: null
|
|
826
826
|
): RemoveLiquidityDualTokenAndPtEventFilter;
|
|
827
827
|
|
|
@@ -944,7 +944,7 @@ export interface ActionAddRemoveLiq extends BaseContract {
|
|
|
944
944
|
market: string,
|
|
945
945
|
netLpToRemove: BigNumberish,
|
|
946
946
|
minPtOut: BigNumberish,
|
|
947
|
-
|
|
947
|
+
guessPtReceivedFromSy: ApproxParamsStruct,
|
|
948
948
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
949
949
|
): Promise<BigNumber>;
|
|
950
950
|
|
|
@@ -1036,7 +1036,7 @@ export interface ActionAddRemoveLiq extends BaseContract {
|
|
|
1036
1036
|
market: string,
|
|
1037
1037
|
netLpToRemove: BigNumberish,
|
|
1038
1038
|
minPtOut: BigNumberish,
|
|
1039
|
-
|
|
1039
|
+
guessPtReceivedFromSy: ApproxParamsStruct,
|
|
1040
1040
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
1041
1041
|
): Promise<PopulatedTransaction>;
|
|
1042
1042
|
|