Pre/Post Expiry Exits
Unwind LP, BT, and CT positions to a single token or FW in one transaction, with different strategies pre- and post-expiry.
Last updated
Unwind LP, BT, and CT positions to a single token or FW in one transaction, with different strategies pre- and post-expiry.
Key references: IPActionMiscV3.exitPreExpToToken/Fw, exitPostExpToToken/Fw.
Goal: Unwind LP/BT/CT positions to a single token or FW.
Pre-expiry: Router first matches BT with CT for redemption (cheaper than swapping), then swaps any remaining unmatched BT or CT to FW via the AMM. Finally redeems FW to desired token.
Post-expiry: BT is sent to the CT contract. CT.redeemBC() burns only BT (not CT). FW returned at current bcIndex rate. Post-expiry yield accrual goes to treasury, not the redeemer.
Implementation note: exitPostExpToFw has a parameter named netFwOut that should be netBtIn (naming bug in implementation, no functional impact).
Views
Market: isExpired(), readTokens(), observe(...).
Lending: getUserPosition if exiting borrow-adjacent strategies.
Events
Router: ExitPreExpToToken, ExitPreExpToFw, ExitPostExpToToken, ExitPostExpToFw.
Market: Burn, subsequent Swap if executed.
CT: Burn (for BC redemption step).
Last updated