peggyjv / cellar-contracts Goto Github PK
View Code? Open in Web Editor NEWCellar Contracts for Sommelier
License: Apache License 2.0
Cellar Contracts for Sommelier
License: Apache License 2.0
Update the oracle infrastructure to allow a backup oracle to chainlink.
The gitbook is well made but could benefit from examples on how adaptors
are open-source innovations for the ERC4626
standard and projects that use it.
This issue is meant to help organize thoughts on what would be needed as examples. The gitbook is not connected to this repo, though it could be.
Similiar to how it is implemented here: https://github.com/Rari-Capital/vaults/blob/main/src/modules/VaultRouterModule.sol.
The router should never have a non-zero balance of any token.
This is a general issue for possible extra tests to add to DebtFTokenAdaptorV2.sol
, DebtFTokenAdaptorV1.sol
, CollateralFTokenAdaptorV2.sol
, and CollateralFTokenAdaptorV1.sol
.
These adaptors are complete, although there was some extra testing scope that was discussed between Crispy and me. These include:
testTakingOutLoanInUntrackedPositionV1
, testRepayingLoans
, testMultipleFraxlendPositions
, testLTV
, testRepayPartialDebt
, testLoanInUntrackedPosition
, testBlockExternalReceiver
.V1FToken
within v1 adaptors, respectively.This issue is tied to PR #112.
adaptorData
from strategists must follow guidelines as per Balancer documentation and other resources. This issue is meant to discuss and finalize guidelines on where to get particular params for preparing adaptorData
for Strategists using Balancer
. I have ideas for the way to generate the callData
and will post them over the next day or so.
See "Resources" at the bottom of this scope description for context.
Below are the primary transactions that a strategist is predicted to carry out:
join()
- joining a balancer pool and getting balancer pool tokens (bpts)exit()
- exiting a balancer pool via redeeming their bpt for their underlying assets and feesswap()
- includes singular and batch swaps where internal vault accounting is used.deposit()
- depositing their bpt into a gauge to gain additional liquidity mining rewards.withdraw()
- withdrawing their bpt from a gaugeclaim_rewards()
- claim rewards from the gauge that they have bpt in.All of these types of transactions could be carried out with separate functions, but instead, we are using the BalancerRelayer.sol
that allows chainedReferences
. This is particularly useful when strategists want to join
a balancer pool that requires some swapping to occur ahead of time.
ex.) If you need to do multiple swaps with DAI
then you can actually do that all in one tx and also have it join the respective pool, let’s say bb-a-usd
.
[Informational] Rewards can remain un-utilized is a won't fix.
Comment: This is a common issue around many staking contracts and fixing it would require more added complexity to staking/unstaking than benefit. In practice, we don't expect this to happen since during an active reward program there is always an incentive to deposit. If this ever were to occur, any un-utilized rewards could be covered by scheduling a new reward program in notifyRewardAmount
to re-distribute them.
[Informational] There is a loss of precision in rewardRate calculation is a won't fix.
Comment: potential loss of precision has been noted in the natspec, on line 571, since the time of implementation. Furthermore, this is a risk to administrators, not users, and administrators are more likely to be aware of the finer details of how the contract works. In practice, the reward amounts and epoch durations we have discussed would not be affected by loss of precision.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.