0.18.14 • Published 1 year ago

@yield-protocol/vault-v2 v0.18.14

Weekly downloads
-
License
GPL-3.0-or-later
Repository
github
Last release
1 year ago

Yield Protocol Vault v2

The Yield Protocol Vault v2 is a Collateralized Debt Engine for zero-coupon bonds, loosely integrated with YieldSpace Automated Market Makers, as described by Dan Robinson and Allan Niemerg.

Smart Contracts

A longer description of the smart contracts can be found in the Yield v2 reference.

Oracles

Oracles return spot prices, borrowing rates and lending rates for the assets in the protocol.

Join

Joins store assets, such as ERC20 or ERC721 tokens.

FYToken

FYTokens are ERC20 tokens that are redeemable at maturity for their underlying asset, at an amount that starts at 1 and increases with the lending rate (chi).

Cauldron

The Cauldron is responsible for the accounting in the Yield Protocol. Vaults are created to contain borrowing positions of one collateral asset type against one fyToken series. The debt in a given vault increases with the borrowing rate (rate) after maturity of the associated fyToken series.

When the value of the collateral in a vault falls below the value of the borrowed fyToken, the vault can be liquidated.

Ladle

The Ladle is the gateway for all Cauldron integrations, and all asset movements in and out of the Joins (except fyToken redemptions). To implement certain features the Ladle integrates with YieldSpace Pools.

Ladle recipe cookbook.

Wand

The Wand bundles function calls into governance actions.

Witch

The Witch is the liquidation engine for the Yield Protocol Vault v2.

Warning

This code is provided as-is, with no guarantees of any kind.

Pre Requisites

Before running any command, make sure to install dependencies:

$ yarn

Lint Solidity

Lint the Solidity code:

$ yarn lint:sol

Lint TypeScript

Lint the TypeScript code:

$ yarn lint:ts

Coverage

Generate the code coverage report:

$ yarn coverage

Test

Be sure to have an .env file located at packages/foundry with the value MAINNET_RPC=<your rpc url> to be used for forked tests.

Compile and test the smart contracts with Foundry:

$ cd packages/foundry
$ forge test

Additional tests can be run with Hardhat using npm or yarn:

$ cd packages/hardhat
$ npm run hardhat:test

Bug Bounty

Yield is offering bounties for bugs disclosed to us at security@yield.is. The bounty reward is up to $500,000, depending on severity. Please include full details of the vulnerability and steps/code to reproduce. We ask that you permit us time to review and remediate any findings before public disclosure.

License

All files in this repository are released under the GPLv3 license.

0.18.14

1 year ago

0.18.13

1 year ago

0.18.12

1 year ago

0.18.0-rc.4

2 years ago

0.18.6-rc.1

2 years ago

0.18.6-rc.0

2 years ago

0.17.0-rc5

2 years ago

0.17.0-rc4

2 years ago

0.17.0-rc7

2 years ago

0.17.0-rc1

2 years ago

0.17.0

2 years ago

0.17.0-rc2

2 years ago

0.18.10-rc.0

1 year ago

0.18.10-rc.1

1 year ago

0.15.1-ether-rc1

2 years ago

0.15.1-ether-rc2

2 years ago

0.18.0-rc3

2 years ago

0.18.0-rc1

2 years ago

0.18.0-rc2

2 years ago

0.18.9

1 year ago

0.18.1

2 years ago

0.18.2

2 years ago

0.18.3

2 years ago

0.18.4

2 years ago

0.18.5

2 years ago

0.18.6

1 year ago

0.18.8

1 year ago

0.18.7-rc.0

1 year ago

0.18.7-rc.1

1 year ago

0.18.7-rc.2

1 year ago

0.18.7-rc.3

1 year ago

0.18.7-rc.4

1 year ago

0.18.7-rc.5

1 year ago

0.18.0

2 years ago

0.17.0-rc14

2 years ago

0.17.0-rc13

2 years ago

0.17.0-rc12

2 years ago

0.17.0-rc11

2 years ago

0.17.0-rc18

2 years ago

0.17.0-rc9

2 years ago

0.17.0-rc17

2 years ago

0.17.0-rc8

2 years ago

0.17.0-rc16

2 years ago

0.17.0-rc15

2 years ago

0.17.0-rc10

2 years ago

0.18.11

1 year ago

0.18.10

1 year ago

0.16.1-rc1

2 years ago

0.16.1-rc0

2 years ago

0.15.1

2 years ago

0.17.1-rc3

2 years ago

0.17.1-rc4

2 years ago

0.17.1-rc1

2 years ago

0.17.1-rc2

2 years ago

0.17.1-rc0

2 years ago

0.16.3

2 years ago

0.16.4

2 years ago

0.16.5

2 years ago

0.16.6

2 years ago

0.16.0

2 years ago

0.16.2

2 years ago

0.18.2-rc.0

2 years ago

0.16.6-rcBRUNO

2 years ago

0.13.0

2 years ago

0.13.1

2 years ago

0.15.0

2 years ago

0.14.1-rc1

2 years ago

0.15.0-rc1

2 years ago

0.15.0-rc0

2 years ago

0.15.0-rc3

2 years ago

0.15.0-rc2

2 years ago

0.15.0-rc5

2 years ago

0.15.0-rc4

2 years ago

0.15.0-rc6

2 years ago

0.12.0

3 years ago

0.12.1

3 years ago

0.14.0

2 years ago

0.12.2

2 years ago

0.14.1

2 years ago

0.12.3

2 years ago

0.11.0-rc8

3 years ago

0.11.0-rc6

3 years ago

0.11.0-rc7

3 years ago

0.11.0-rc4

3 years ago

0.11.0-rc5

3 years ago

0.11.0-rc2

3 years ago

0.11.0-rc3

3 years ago

0.11.0-rc1

3 years ago

0.11.0-rc0

3 years ago

0.10.0-rc6

3 years ago

0.10.0-rc5

3 years ago

0.10.0-rc4

3 years ago

0.10.0-rc3

3 years ago

0.10.0-rc2

3 years ago

0.10.0-rc1

3 years ago

0.10.0-rc0

3 years ago

0.9.0-rc3

3 years ago

0.9.0-rc2

3 years ago

0.9.0-rc0

3 years ago

0.8.0-rc1

3 years ago

0.8.0-rc0

3 years ago

0.7.0-rc1

3 years ago

0.7.0-rc0

3 years ago

0.6.0-rc0

3 years ago

0.5.0-rc5

3 years ago

0.5.0-rc4

3 years ago

0.5.0-rc3

3 years ago

0.5.0-rc2

3 years ago

0.5.0-rc1

3 years ago

0.4.1

3 years ago

0.4.0

3 years ago

0.4.0-rc1

3 years ago

0.4.0-rc0

3 years ago

0.3.2

3 years ago

0.3.1

3 years ago

0.3.0

3 years ago

0.2.1

3 years ago

0.2.0

3 years ago

0.0.4

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago