Giter Site home page Giter Site logo

parallel-finance / parallel Goto Github PK

View Code? Open in Web Editor NEW
117.0 15.0 33.0 12.83 MB

A decentralized lending & staking protocol built on top of the Polkadot ecosystem.

Home Page: https://parallel.fi

License: GNU General Public License v3.0

Rust 97.40% Handlebars 0.16% Makefile 0.45% Shell 0.40% TypeScript 1.20% Solidity 0.39%
parachain cumulus lending staking polkadot substrate kusama

parallel's People

Contributors

0xrjman avatar alannotnerd avatar ashi20192020 avatar ayushmishra2005 avatar bingryan avatar c02fee avatar c0ding avatar c410-f3r avatar cronusyuan avatar dependabot[bot] avatar drbh avatar eteissonniere avatar gopherj avatar haiyizxx avatar hskang9 avatar kaichaosun avatar kennyykw avatar mclyk avatar palletd avatar rainfallssilent avatar rustaceanstayhigh avatar uncertainbadg3r avatar woshihahaha avatar yrong avatar yubo-ruan avatar yz89 avatar zhoujia6139 avatar zhulipai avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

parallel's Issues

Parachain is not able to fetch price

Description

image

Steps to Reproduce

Replace the example steps below with actual steps to reproduce the bug you're reporting.

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected vs. Actual Behavior

What did you expect to happen after you followed the steps you described in the last section? What
actually happened?

Environment

Describe the environment in which you encountered this bug. Use the list below as a starting point
and add additional information if you think it's relevant.

  • Operating system:
  • Template version/tag:
  • Rust version (run rustup show):

Logs, Errors or Screenshots

Please provide the text of any logs or errors that you experienced; if
applicable, provide screenshots to help illustrate the problem.

Additional Information

Please add any other details that you think may help us solve your problem.

Test coverage and refactor liquidate pallet

Potencial tasks:

  • test coverage for execute_liquidation
  • short liquidate function by extracting a few small functions
  • remove outer loop if possible
  • more liquidation workflow, like give general user chance to process liquidation
  • comments/rustdocs
  • benchmark (split to another issue if needed)
  • license

Benchmarking is failing due to `pallet-collective`

In the recent changes of master branch

pallet-collective = { git = 'https://github.com/paritytech/substrate.git', version = '3.0.0', branch = "rococo-v1", default-features = false }
, pallet-collective was added. But it was not added in runtime-benchmarks. Because of that, this command cargo build --release --features runtime-benchmarks is failing and I am getting below error.

      Compiling pallet-collective v3.0.0 (https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4)
  error[E0046]: not all trait items implemented, missing: `successful_origin`
     --> /Users/ayushkumarmishra/.cargo/git/checkouts/substrate-7e08433d4c370a21/2be8fcc/frame/collective/src/lib.rs:879:1
      |
  879 | / impl<
  880 | |     O: Into<Result<RawOrigin<AccountId, I>, O>> + From<RawOrigin<AccountId, I>>,
  881 | |     AccountId: Default,
  882 | |     I,
  ...   |
  895 | |     }
  896 | | }
      | |_^ missing `successful_origin` in implementation
      |
      = help: implement the missing item: `fn successful_origin() -> OuterOrigin { todo!() }`

Tasks overview to make code in node production ready

Tasks

Tasks to make the code production ready.

loans

  • test coverage for dispatchables
    • mint
    • redeem
    • redeem_all
    • borrow
    • repay_borrow
    • repay_borrow_all
    • transfer_token
    • collateral_asset
    • liquidate_borrow
  • refactor code, mainly storages and dispatchables
    • comments/rustdocs for all errors/events, dispatchables, storages
    • minimum storage usage, bounded execution/storage, short function
    • add traits for pallet to abstract the behaviour
    • move the main pallet implementation in lib.rs
    • extract to new pallets if storages/dispatchables can be separated
    • exchange_rate to use fixed point number, rational of precision
    • pub mod module change to pallet, put impl Pallet out of this module
  • xcm-token transfer
  • benchmark for dispatchables in this module
  • license

liquidate:

  • test coverage for execute_liquidation
  • short liquidate function by extracting a few small functions
  • remove outer loop if possible
  • randomly run offchain liquidation to give general user chance to process liquidation
  • comments
  • benchmark
  • license

ocw price feed:

  • research if api key is needed to get more quota or more stable service (rpc offchain_localStorageSet)
  • use StorageLock to make api call not exceed the threshold
  • bound the onchain data by limit the size of price set or the node can send price

staking

  • document the workflow with staking's dispatchables about validation or nomination
  • abstract the nomination workflow in parallel with traits given above docs
  • offchain nomination with a multisig account in relaychain
  • xcm nomination

Refactor code in loans pallet, mainly storages and dispatchables

Items needed to be refactored includes,

  • comments/rustdocs for all errors/events, dispatchables, storages
  • minimum storage usage, bounded execution/storage, short function
  • add traits for pallet to abstract the behaviour
  • move the main pallet implementation in lib.rs
  • extract to new pallets if storages/dispatchables can be separated
  • exchange_rate to use fixed point number, rational of precision
  • pub mod module change to pallet, put impl Pallet out of this module
  • license

currency_id abstration

heiko & parallel have different markets KSM versus DOT, but these two runtimes share the same pallets. We need to have an abstration layer on this so that we don't need to have two same pallets.

Deploy dev runtime to staging

After a PR merged, it should be automatically deploy the dev runtime to staging, so app users can try the new changes.

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.