Skip to content

Commit

Permalink
Run log to withdraw 1k from new OUSD Morpho Gauntlet Strategies (#2340)
Browse files Browse the repository at this point in the history
* Run log to withdraw 1k from new OUSD Morpho Gauntlet Strategies

* Changed the withdrawal amount to 1k
  • Loading branch information
naddison36 authored Jan 6, 2025
1 parent a0d98cc commit 08bc1cd
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions brownie/runlogs/2025_01_strategist.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# -------------------------------------
# Jan 6, 2025 - Withdraw 1k from new OUSD Morpho Gauntlet Strategies
# -------------------------------------
from world import *

def main():
with TemporaryForkForReallocations() as txs:
# Before
txs.append(vault_core.rebase(std))
txs.append(vault_value_checker.takeSnapshot(std))

# Remove 1k USDC from Morpho Gauntlet Strategy
txs.append(
vault_admin.withdrawFromStrategy(
MORPHO_GAUNTLET_PRIME_USDC_STRAT,
[usdc],
[1000 * 10**6],
{'from': STRATEGIST}
)
)

# Remove 1k USDT from Morpho Gauntlet Strategy
txs.append(
vault_admin.withdrawFromStrategy(
MORPHO_GAUNTLET_PRIME_USDT_STRAT,
[usdt],
[1000 * 10**6],
{'from': STRATEGIST}
)
)

# After
vault_change = vault_core.totalValue() - vault_value_checker.snapshots(STRATEGIST)[0]
supply_change = ousd.totalSupply() - vault_value_checker.snapshots(STRATEGIST)[1]
profit = vault_change - supply_change
txs.append(vault_value_checker.checkDelta(profit, (1 * 10**18), vault_change, (1 * 10**18), std))
print("-----")
print("Profit", "{:.6f}".format(profit / 10**18), profit)
print("OUSD supply change", "{:.6f}".format(supply_change / 10**18), supply_change)
print("Vault Change", "{:.6f}".format(vault_change / 10**18), vault_change)
print("-----")

0 comments on commit 08bc1cd

Please sign in to comment.