Code Monkey home page Code Monkey logo

ciri's Introduction

Ciri

Build Status Gitter

What is Ciri?

Ciri is an ongoing Ethereum implementation written in Ruby. Ciri aims to become a researcher-friendly Ethereum implementation and a blockchain toolbox for all developers to modify or build their own private/public chains more conveniently in Ruby.

The goals of Ciri:

  • Be a researcher-friendly Ethereum implementation, which means Ciri needs to be intelligible and easy to be modified.
  • Be a blockchain toolbox, provide components and low-level API for developers to build their own private or public chain.
  • In general, we want Ciri to build a bridge to bring rubyist into Ethereum world!

Where will this project go?

Ciri has already passed the Ethereum tests suite and the Ethereum 1.0 POW Chain is almost implemented. However, we still need to implement several components(DevP2P, KeyStore, CLI ...) to support running a fully functionally Ethereum node on the mainnet.

At the same time, we are keeping an eye on Ethereum 2.0 specs: the shasper(sharding + casper) implementation, and pursuing to implement the lastest updated shasper specs.

Ciri project wants more contributors and we highly welcome anyone to join in. If you are interested in Ciri project, please refer to How to learn Ethereum and contribute to Ciri and Issues.

Read projects and milestones for current development status.

See our Roadmap on Wiki.

Usage

Ciri is still under active development and the master branch is really recommended.

Add this line to your Gemfile:

gem 'ciri', github: 'ciri-ethereum/ciri'

See examples and spec to learn how to use.

Development

Ciri depends on rocksdb, secp256k1 and snappy.

It's a recommendation to setup with docker because it will help to save lots of time.

Setup with docker

Use docker command to pull image:

docker pull ciriethereum/ciri

Or you can use our prepared rake tasks if you're not familiar with docker:

clone repo and submodules

git clone --recursive https://github.com/ciri-ethereum/ciri.git
cd ciri

make sure we have installed docker, ruby and rake

# make sure we have installed docker, ruby and rake
docker -v
gem install rake

Pull docker image

# pull Ciri docker image
rake docker:pull

Run tests in docker

# run tests
rake docker:spec

# run specific component related tests (for example: p2p network component)
rake docker:spec[p2p]

Other usages

# open a shell for developing
rake docker:shell

# build Ciri docker image from current source (it will take a few minutes)
rake docker:build

# type 'rake -T' see other supported tasks 
rake -T

Manually Setup

clone repo and submodules

git clone --recursive https://github.com/ciri-ethereum/ciri.git

Install dependencies

On a mac you can install rocksdb and snappy with homebrew

brew install rocksdb snappy

Build and install secp256k1

cd ciri && rake install:secp256k1

For linux users, remember to check Dockerfile instructions for hint.

then run:

bundle install

run tests:

# run all tests
RUBY_THREAD_VM_STACK_SIZE=52428800 bundle exec rake spec

# run specific component related tests (for example: p2p network component)
bundle exec rake spec[p2p]

Why Ruby?

Because Ruby has built-in block support!

Seriously,

Ruby is a scripting language which makes it easy to write prototype or research code (like the official python Ethereum implementation intended).

According to the several performance research projects in Ruby community (JIT, JRuby, TruffleRuby), we are highly looking forward to seeing improvement of this language performance in the future.

Due to Ruby, we could expect to achieve both research-friendly and high-performance in our implementation.

Contributors

See Contributors

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.