Skip to content

[ARM] Deploy 044 USDC ARM Morpho Vault V2 market on mainnet - #334

Closed
clement-ux wants to merge 3 commits into
mainfrom
clement/deploy-044-usdc-morpho-market
Closed

[ARM] Deploy 044 USDC ARM Morpho Vault V2 market on mainnet#334
clement-ux wants to merge 3 commits into
mainfrom
clement/deploy-044-usdc-morpho-market

Conversation

@clement-ux

Copy link
Copy Markdown
Collaborator

Description

Add a Morpho Vault V2 market wrapper for the USDC ARM targeting the Wintermute USDC Prime vault. The target currently routes USDC through a direct, loss-aware MorphoMarketV1AdapterV2; it is not a wrapper around MetaMorpho V1 or V1.1.

Morpho Vault V2 returns zero from all ERC-4626 max functions. MorphoVaultV2Market therefore exposes the wrapper's full economic position through maxWithdraw and maxRedeem so the ARM can account for and manage the position. These values are not liquidity guarantees: downstream liquidity, gates, caps, or pauses can still make a withdrawal revert.

The wrapper documents the target's accounting assumptions, including the incompatibility with a future MorphoVaultV1Adapter over MetaMorpho V1.1 and the need to monitor adapter changes while the ARM market is active.

No mainnet deployment transaction has been broadcast yet.

Deployment

Script script/deploy/mainnet/044_DeployUSDCMorphoMarketScript.s.sol

The script:

  • deploys a Proxy and MorphoVaultV2Market implementation;
  • initializes the wrapper with the mainnet 5/8 multisig as owner, the 2/8 multisig as harvester, and the Morpho Merkle distributor;
  • simulates registration with the USDC ARM on forks;
  • does not activate the market or deposit USDC into Vault V2.

Configuration

Param Value Note
arm 0x9E3A7026E5767F2d7Ff5e83b0ed011005f45a170 USDC ARM
market 0x5dc53a23AdC9f2Bed98de6F59F7F309a7c71FF2B Wintermute USDC Prime Vault V2
asset 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48 USDC
wrapper owner 0xbe2AB3d3d8F6a32b96414ebbd865dBD276d3d899 Mainnet 5/8 multisig
harvester 0x4FF1b9D9ba8558F5EAfCec096318eA0d8b541971 Mainnet 2/8 multisig
merkleDistributor 0x3Ef3D8bA38EBe18DB133cEc108f4D14CE00Dd9Ae Morpho rewards distributor

The target Vault V2 currently has one adapter, 0x6189aF51677419D81F334837075f7A1aE7c50db9, which holds direct USDC supply positions in three Morpho Blue markets backed by WBTC, cbBTC, and wstETH collateral at 86% LLTV. All four Vault V2 gates and both Vault V2 fees are currently disabled.

Governance

No GovernorSix proposal is required. The mainnet 5/8 multisig directly owns the USDC ARM and will perform the market registration after deployment.

Required post-deployment actions (5/8 multisig)

  1. Register the deployed proxy with USDC_ARM.addMarkets([MORPHO_MARKET_USDC_ARM]).
  2. Keep the market inactive until the Vault V2 cap headroom and downstream-liquidity requirements have been resolved and rechecked.

The script intentionally does not call setActiveMarket.

Operational constraints

  • At approximately mainnet block 25,738,828, the Vault V2 had about 20.494 million USDC of total assets and 20.478 million USDC allocated under its 100% relative adapter cap, leaving only about 15,962 USDC of one-transaction headroom. The USDC ARM held about 82,164 idle USDC with a zero buffer, so activation under that configuration is expected to revert.
  • maxWithdraw and maxRedeem expose the full economic position, not a revert-free liquidity bound. Operators must verify downstream liquidity before relying on immediate withdrawal.
  • The target is currently loss-aware, but adapter composition is mutable. Operators must monitor adapter additions and deactivate the ARM market before any MetaMorpho V1.1-backed adapter becomes effective.

Tests

  • forge fmt --check — passed.
  • git diff --check — passed.
  • forge build — passed.
  • forge test --match-contract Fork_PaxosARM_Smoke_Test --match-test 'test_morphoMarket.*' -vvv — 2/2 tests passed.

@clement-ux clement-ux added Deployment Deploys smart contracts to the network. Deployment script Deployment script for smart contract. labels Aug 12, 2026
@clement-ux clement-ux self-assigned this Aug 12, 2026
@clement-ux clement-ux removed the Deployment Deploys smart contracts to the network. label Aug 12, 2026

@naddison36 naddison36 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ARM now uses convertToAssets on the lending market to calculate the economic value in totalAssets.

The ARM uses maxWithdraw to get the redeemable amount which can be lower when the market is highly utilized in allocate, claimRedeem and getReserves.
The lending market's maxRedeem is used in allocate.

So we want the wrapper's max functions to be the redeemable and not economic values.

@clement-ux

clement-ux commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator Author

Closing this PR for now because Morpho Vault V2 cannot be safely integrated through our generic ERC-4626 market wrapper. Vault V2 deliberately returns zero from maxWithdraw and maxRedeem, while the ARM relies on those functions for claimable liquidity, reserves, and market reallocation. Leaving them unchanged would make the position economically visible through convertToAssets but operationally unavailable to the ARM. Computing meaningful limits is not generic: it depends on the vault current liquidity adapter, its configured downstream markets, available Morpho liquidity, gates, and mutable curator configuration. A vault-specific implementation would therefore be complex and brittle. We will use a Morpho Vault V1 instead for now, since it exposes usable ERC-4626 withdrawal limits directly.

@clement-ux clement-ux closed this Aug 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Deployment script Deployment script for smart contract.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants