All Projects → curvefi → Curve Contract

curvefi / Curve Contract

Licence: other
Vyper contracts used in Curve.fi exchange pools.

Programming Languages

python
139335 projects - #7 most used programming language

Labels

Projects that are alternatives of or similar to Curve Contract

Khipu
An enterprise blockchain platform based on Ethereum
Stars: ✭ 301 (-5.64%)
Mutual labels:  ethereum
Embark
Framework for serverless Decentralized Applications using Ethereum, IPFS and other platforms
Stars: ✭ 3,478 (+990.28%)
Mutual labels:  ethereum
Web3j Sample
web3j 样例程序
Stars: ✭ 317 (-0.63%)
Mutual labels:  ethereum
Edge React Gui
Edge Wallet React Native GUI for iOS and Android
Stars: ✭ 303 (-5.02%)
Mutual labels:  ethereum
Requestnetwork
A JavaScript library for interacting with the Request Network protocol
Stars: ✭ 311 (-2.51%)
Mutual labels:  ethereum
Nmr
The Numeraire Ethereum Smart Contract
Stars: ✭ 316 (-0.94%)
Mutual labels:  ethereum
Ethereum Lists
A repository for maintaining lists of things like malicious URLs, fake token addresses, and so forth. We love lists.
Stars: ✭ 300 (-5.96%)
Mutual labels:  ethereum
Love Ethereum
区块链学习
Stars: ✭ 323 (+1.25%)
Mutual labels:  ethereum
Squeezer
Squeezer Framework - Build serverless dApps
Stars: ✭ 3,242 (+916.3%)
Mutual labels:  ethereum
Zkproofs
Original iteration of ING zero-knowledge range proofs. This repo has been archived as a prior works knowledge base, for latest Bulletproofs implementation please go to ing-bank/zkrp.
Stars: ✭ 319 (+0%)
Mutual labels:  ethereum
Alpha
Follow the white rabbit 🐇
Stars: ✭ 304 (-4.7%)
Mutual labels:  ethereum
Ethersplay
EVM dissassembler
Stars: ✭ 304 (-4.7%)
Mutual labels:  ethereum
Populus
The Ethereum development framework with the most cute animal pictures
Stars: ✭ 315 (-1.25%)
Mutual labels:  ethereum
Kyberswap
Codebase for KyberSwap that helps users convert tokens instantly and directly from their own hardware wallets, metamask and so on. No setup, No deposit, no withdrawal needed. Try it out on https://kyberswap.com or join telegram for developers https://t.me/KyberDeveloper.
Stars: ✭ 301 (-5.64%)
Mutual labels:  ethereum
Ethvm
⚡️EthVM: Open Source Processing Engine and Block Explorer for Ethereum ⚡️
Stars: ✭ 319 (+0%)
Mutual labels:  ethereum
Bamboo
Bamboo see https://github.com/cornellblockchain/bamboo
Stars: ✭ 300 (-5.96%)
Mutual labels:  ethereum
Uniswap V1
🐍Uniswap V1 smart contracts
Stars: ✭ 313 (-1.88%)
Mutual labels:  ethereum
Awesome Coins
₿ A guide (for humans!) to cryto-currencies and their algos.
Stars: ✭ 3,469 (+987.46%)
Mutual labels:  ethereum
Go Livepeer
Official Go implementation of the Livepeer protocol
Stars: ✭ 317 (-0.63%)
Mutual labels:  ethereum
Contracts
[DEPRECATED] 0x smart contracts and tests.
Stars: ✭ 317 (-0.63%)
Mutual labels:  ethereum

curve-contract

Vyper contracts used in Curve exchange pools.

Overview

Curve is an exchange liquidity pool on Ethereum designed for extremely efficient stablecoin trading and low risk, supplemental fee income for liquidity providers, without an opportunity cost.

Curve allows users to trade between correlated cryptocurrencies with a bespoke low slippage, low fee algorithm. The liquidity pool is also supplied to lending protocol where it generates additional income for liquidity providers.

Testing and Development

Dependencies

Curve contracts are compiled using Vyper, however installation of the required Vyper versions is handled by Brownie.

Setup

To get started, first create and initialize a Python virtual environment. Next, clone the repo and install the developer dependencies:

git clone https://github.com/curvefi/curve-contract.git
cd curve-contract
pip install -r requirements.txt

Organization and Workflow

See the documentation within contracts and it's subdirectories for more detailed information on how to get started developing on Curve.

Running the Tests

The test suite contains common tests for all Curve pools, as well as unique per-pool tests. To run the entire suite:

brownie test

To run tests on a specific pool:

brownie test tests/ --pool <POOL NAME>

Valid pool names are the names of the subdirectories within contracts/pools. For templates, prepend template- to the subdirectory names within contracts/pool-templates. For example, the base template is template-base.

You can optionally include the --coverage flag to view a coverage report upon completion of the tests.

Deployment

To deploy a new pool:

  1. Ensure the pooldata.json for the pool you are deploying contains all the necessary fields.

  2. Edit the configuration settings within scripts/deploy.py.

  3. Test the deployment locally against a forked mainnet.

    brownie run deploy --network mainnet-fork -I
    

    When the script completes it will open a console. You should call the various getter methods on the deployed contracts to ensure the pool has been configured correctly.

  4. Deploy the pool to the mainnet.

    brownie run deploy --network mainnet
    

    Be sure to open a pull request that adds the deployment addresses to the pool README.md.

Audits and Security

Curve smart contracts have been audited by Trail of Bits. These audit reports are made available on the Curve website.

There is also an active bug bounty for issues which can lead to substantial loss of money, critical bugs such as a broken live-ness condition, or irreversible loss of funds.

License

(c) Curve.Fi, 2020 - All rights reserved.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].