Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion contracts/ResilientOracle.sol
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,10 @@ contract ResilientOracle is PausableUpgradeable, AccessControlledV8, ResilientOr

/**
* @notice Updates the capped main oracle snapshot.
* @dev This function should always be called before calling getPrice
* @dev This function should always be called before calling getPrice.
* A successful return does NOT guarantee the snapshot was advanced — CAPO-style
* main oracles no-op `updateSnapshot()` while within `snapshotInterval`, or when
* `snapshotInterval == 0`.
* @param asset asset address
*/
function updateAssetPrice(address asset) external {
Expand Down
4 changes: 4 additions & 0 deletions contracts/oracles/OneJumpOracle.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ import { IERC20Metadata } from "@openzeppelin/contracts/token/ERC20/extensions/I
*/
contract OneJumpOracle is CorrelatedTokenOracle {
/// @notice Address of the intermediate oracle
/// @dev MUST return the price of `CORRELATED_TOKEN` denominated in `UNDERLYING_TOKEN`
/// (scaled to `36 - underlyingDecimals`), NOT a USD-denominated price. A USD feed
/// would inflate `getUnderlyingAmount()`; with `snapshotInterval == 0` (CAPO cap
/// disabled) the inflated value would reach `ResilientOracle` unbounded.
OracleInterface public immutable INTERMEDIATE_ORACLE;

/// @notice Constructor for the implementation contract.
Expand Down
24 changes: 1 addition & 23 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4131,29 +4131,7 @@ __metadata:
languageName: node
linkType: hard

"@venusprotocol/oracle@npm:^2.7.0":
version: 2.14.0
resolution: "@venusprotocol/oracle@npm:2.14.0"
dependencies:
"@chainlink/contracts": ^0.5.1
"@defi-wonderland/smock": 2.4.0
"@nomicfoundation/hardhat-network-helpers": ^1.0.8
"@openzeppelin/contracts": ^4.6.0
"@openzeppelin/contracts-upgradeable": ^4.7.3
"@venusprotocol/governance-contracts": ^2.13.0
"@venusprotocol/solidity-utilities": ^2.0.0
"@venusprotocol/venus-protocol": ^9.7.0
ethers: ^5.6.8
hardhat: 2.22.18
hardhat-deploy: ^0.12.4
module-alias: ^2.2.2
patch-package: ^8.0.0
solidity-docgen: ^0.6.0-beta.29
checksum: e10a6b303cb2d41f158fdae300d030f9fb506e0d389414a7b94fdada89bd322ad3e452a8b929a8e42602dd93e380916bbc86c9ba58fdf5178d38fbbb71edadb8
languageName: node
linkType: hard

"@venusprotocol/oracle@workspace:.":
"@venusprotocol/oracle@^2.7.0, @venusprotocol/oracle@workspace:.":
version: 0.0.0-use.local
resolution: "@venusprotocol/oracle@workspace:."
dependencies:
Expand Down
Loading