Skip to content

Commit 7d1cb4b

Browse files
committed
Addressed the remaining FIXME comments
1 parent 56356c4 commit 7d1cb4b

File tree

4 files changed

+22
-17
lines changed

4 files changed

+22
-17
lines changed

contracts/src/instances/ezeth-linea/EzETHLineaBase.sol

-5
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,9 @@ import { IXRenzoDeposit } from "../../interfaces/IXRenzoDeposit.sol";
66
import { HyperdriveBase } from "../../internal/HyperdriveBase.sol";
77
import { EzETHLineaConversions } from "./EzETHLineaConversions.sol";
88

9-
// FIXME: Update the Natspec comment.
10-
//
119
/// @author DELV
1210
/// @title EzETHLineaBase
1311
/// @notice The base contract for the EzETHLinea Hyperdrive implementation.
14-
/// @dev This Hyperdrive implementation is designed to work with standard
15-
/// EzETHLinea vaults. Non-standard implementations may not work correctly
16-
/// and should be carefully checked.
1712
/// @custom:disclaimer The language used in this code is for coding convenience
1813
/// only, and is not intended to, and does not, have any
1914
/// particular legal or regulatory significance.

contracts/src/instances/ezeth-linea/EzETHLineaConversions.sol

+10-9
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,18 @@ pragma solidity 0.8.22;
44
import { IXRenzoDeposit } from "../../interfaces/IXRenzoDeposit.sol";
55
import { FixedPointMath } from "../../libraries/FixedPointMath.sol";
66

7-
// FIXME: Add a @dev section explaining the oracle.
8-
//
97
/// @author DELV
108
/// @title EzETHLineaConversions
119
/// @notice The conversion logic for the EzETH integration on Linea.
10+
/// @dev This conversion library pulls the vault share price from the Renzo
11+
/// oracle on linea. It's possible for this oracle to have downtime or
12+
/// to be deprecated entirely. Our approach to this problem is to always
13+
/// use the latest price data (regardless of how current it is) since
14+
/// reverting will compromise the protocol's liveness and will prevent
15+
/// users from closing their existing positions. These pools should be
16+
/// monitored to ensure that the underlying oracle continues to be
17+
/// maintained, and the pool should be paused if the oracle has significant
18+
/// downtime or is deprecated.
1219
/// @custom:disclaimer The language used in this code is for coding convenience
1320
/// only, and is not intended to, and does not, have any
1421
/// particular legal or regulatory significance.
@@ -50,13 +57,7 @@ library EzETHLineaConversions {
5057
function getLastMintPrice(
5158
IXRenzoDeposit _xRenzoDeposit
5259
) internal view returns (uint256) {
53-
// FIXME: What are the historical values for this oracle? Does it ever
54-
// go down?
55-
//
56-
// FIXME: Is this acceptable? Do we need to do anything with the timestamp?
57-
//
58-
// FIXME: Regardless of what we do with the timestamp, we need to make a
59-
// note of what we're doing.
60+
// NOTE: We
6061
(uint256 lastPrice, ) = _xRenzoDeposit.getMintRate();
6162
return lastPrice;
6263
}

contracts/src/instances/ezeth-linea/EzETHLineaHyperdrive.sol

+12-2
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ import { IHyperdriveAdminController } from "../../interfaces/IHyperdriveAdminCon
77
import { IXRenzoDeposit } from "../../interfaces/IXRenzoDeposit.sol";
88
import { EzETHLineaBase } from "./EzETHLineaBase.sol";
99

10-
// FIXME: Add an @dev comment documenting this yield source.
11-
//
1210
/// ______ __ _________ _____
1311
/// ___ / / /____ ___________________________ /_________(_)__ ______
1412
/// __ /_/ /__ / / /__ __ \ _ \_ ___/ __ /__ ___/_ /__ | / / _ \
@@ -52,6 +50,18 @@ import { EzETHLineaBase } from "./EzETHLineaBase.sol";
5250
/// @author DELV
5351
/// @title EzETHLineaHyperdrive
5452
/// @notice A Hyperdrive instance that uses a EzETHLinea vault as the yield source.
53+
/// @dev This instance supports the Renzo protocol on Linea. The vault shares token
54+
/// is the rebasing LRT token xezETH. There are a few special things about
55+
/// this integration:
56+
///
57+
/// - The base token address is the ETH constant.
58+
/// - The vault shares token address is the xezETH address.
59+
/// - The vault share price is provided by an oracle.
60+
/// - Interest accrues sporadically when the oracle is updated.
61+
/// - Base deposits aren't supported since there is a deposit fee for
62+
/// minting xezETH.
63+
/// - Base withdrawals aren't supported since there isn't an instantaneous
64+
/// way to withdraw from xezETH.
5565
/// @custom:disclaimer The language used in this code is for coding convenience
5666
/// only, and is not intended to, and does not, have any
5767
/// particular legal or regulatory significance.

test/instances/ezeth-linea/EzETHLineaTest.t.sol

-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@ contract EzETHLineaHyperdriveTest is InstanceTest {
5555
vaultSharesTokenWhaleAccounts: vaultSharesTokenWhaleAccounts,
5656
baseToken: IERC20(ETH),
5757
vaultSharesToken: EZETH,
58-
// FIXME
5958
shareTolerance: 0,
6059
minimumShareReserves: 1e15,
6160
minimumTransactionAmount: 1e15,

0 commit comments

Comments
 (0)