Skip to content

Conversation

@clement-ux
Copy link
Collaborator

@clement-ux clement-ux commented Dec 9, 2025

This pull request introduces significant refactoring and simplification across the vault contracts and related mocks, with a focus on consolidating interfaces, removing legacy features, and updating contract inheritance. The changes affect core vault logic, mock contracts, and strategy integration, aiming to streamline code and reduce complexity for future development.

Vault Interface and Contract Refactoring

  • The IVault interface was extensively cleaned up: many legacy events and functions (such as asset-specific strategy management, price provider access, swapper logic, and OETH-specific features) were removed or deprecated. New unified methods and events (like setDefaultStrategy, defaultStrategy, and withdrawal delay handling) were introduced to standardize vault behavior. [1] [2] [3] [4]
  • Vault mock contracts (MockVault, MockOETHVault, MockOETHVaultAdmin) now inherit from the updated VaultAdmin or OETHVault contracts instead of legacy core/admin contracts. This reflects the new inheritance structure and removes redundant or obsolete logic. [1] [2] [3]

Mocks and Test Contract Updates

  • Mock contracts were updated to match the new interfaces and inheritance. For example, MockNonRebasing now uses requestWithdrawal instead of redeem, and constructor arguments and asset logic were adjusted for compatibility. [1] [2] [3]
  • The MockEvilReentrantContract and MockRebornMinter were modified to use direct constructor injection for dependencies (like priceProvider) and to update asset approvals and minting logic according to new standards. [1] [2] [3] [4]

Strategy Contract Changes

  • The BridgedWOETHStrategy contract now receives the oracle address directly via its constructor, rather than fetching it from the vault. This change improves modularity and testability for strategies. [1] [2] [3]

Deprecation and Removal of Legacy Files

  • Legacy contracts such as OETHBaseVaultAdmin.sol were removed, and their responsibilities consolidated into new base contracts like OETHBaseVault.sol, further simplifying the contract hierarchy. [1] [2]

Documentation Update

  • The README was updated to reflect the new hot deploy configuration, changing references from vaultCore and vaultAdmin to the unified vault flag for contract source updates.

… improve clarity by removing deprecated functions and updating asset handling methods.
…itialization by using address(0) for backing asset.
…address, simplifying price retrieval and enhancing clarity
…nstructors for improved clarity and functionality
…y by removing unused variables and consolidating test cases
…et address, update test fixtures to use USDC instead of USDS, and simplify Dripper and VaultValueChecker tests by removing unused variables and consolidating logic.
// Start with drip duration disabled
dripDuration = 1;
// Start with drip duration: 7 days
dripDuration = 604800;

Choose a reason for hiding this comment

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

Probably never going to be used since no new vault is scheduled

Copy link
Collaborator

Choose a reason for hiding this comment

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

What do you mean by the vault is scheduled?
We are now using the dripDuration in all the Vaults

clement-ux and others added 6 commits January 12, 2026 15:01
* Refactor vault contracts to remove deprecated implementations and simplify admin structure

* Refactor vault contracts to unify admin structure and simplify deployment scripts

* move zapper to dedicated folder

* Refactor vault upgrade scripts to unify implementation names and simplify deployment actions

* Updated hot deploy with new Vault contracts

* Update Vault contract diagrams

* Add OSVault contract and update deployment script references

---------

Co-authored-by: Nicholas Addison <nick@addisonbrown.com.au>
naddison36
naddison36 previously approved these changes Jan 13, 2026
Copy link
Collaborator

@naddison36 naddison36 left a comment

Choose a reason for hiding this comment

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

Looks good

// Start with drip duration disabled
dripDuration = 1;
// Start with drip duration: 7 days
dripDuration = 604800;
Copy link
Collaborator

Choose a reason for hiding this comment

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

What do you mean by the vault is scheduled?
We are now using the dripDuration in all the Vaults

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants