Code Monkey home page Code Monkey logo

core's Introduction

Lint Tests Slither

Platypus Finance v1 Core

Core smart contracts of Platypus Finance.

Before getting started with this repo, please read:

Overview

Platypus has devised a whole new kind of StableSwap for enhanced capital efficiency, scalability and user experience in the Avalanche ecosystem.

Contracts

We detail a few of the core contracts for the Platypus Finance Protocol.

Core.sol

Handles most of the math: fees, slippage and haircut as defined in the yellow paper.

Pool.sol

Handles deposits, withdrawals and swaps with an open and extendable pool design.

Testing and Development

Local Development

Requires node@>=14

Install dependencies

yarn

Compile Contracts

yarn compile

Run tests

yarn test

Slither

Run

We use a mirror of slither to guarantee consistency and compatibility. It is located in this repository.

docker run --rm -it -v "$PWD":/src platypusfinance/eth-security-toolbox
# Inside container
cd /src
slither .

Slither may generate false positives that may break CI. To suppress these false positives :

docker run --rm -it -v "$PWD":/src platypusfinance/eth-security-toolbox
# Inside container
cd /src
slither . --triage
# An interactive prompt will be invoked for suppressing the warnings

A new slither.db.json will be created and should be commited.

Echidna fuzzer

To launch echidna fuzzer, first cd into the core directory.

rm -rf crytic-export/; yarn compile; docker run -it -v "$PWD":/src platypusfinance/eth-security-toolbox
# Inside container
solc-select 0.8.9; cd /src/; echidna-test . --contract IntegrationTest --config echidna.yaml

UML Diagram

Audits and Security

Read our bug bounty program details and SECURITY disclosure.

Licensing

The primary license for Platypus Finance Core v1 is the Business Source License 1.1 (BUSL-1.1), see LICENSE.

core's People

Contributors

mrbeavertail avatar royyyy33 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.