Git Product home page Git Product logo

ethi's Introduction

ETHI

Common lisp wrapper around ethereum's JSON RPC API. Interact with the ethereum blockchain from your common lisp program!

API

The api is completely 1-to-1 with the one found here except that it follows the following convention:

  • it converts _ inside method names with /
  • it converts camel case method names with kebab-case.

So for example web3_clientVersion becomes web3/client-version.

If you have any doubts for a method name, just take a look at the exported symbols inside src/ethi.lisp. Or just paste in the REPL:

(let ((lst ()))
  (do-external-symbols (s (find-package 'ethi) lst)
    (push s lst))
  lst)

Running tests

To run the tests locally you will need to run a local private testnet.

  1. Install geth
  2. cd to the project's directory and start it with:
geth --rpc --nodiscover --maxpeers 0 --datadir "t/" init t/CustomGenesis.json
geth --nodiscover --maxpeers 0 --rpc --datadir t/client-data --networkid 555 --unlock "0,1" --password t/password.txt console
  • --rpc enables the rpc. Duh...
  • --nodiscover will make sure your node is not discoverable.
  • --maxpeers 0 will prevent the node from syncing.
  • init t/CustomGenesis.json will ensure you create a custom testing blockchain.
  • --unlock "0,1" will unlock the first two accounts
  • --password will use the password provided in the text file
  • console will open the console
  1. Run (asdf:test-system :ethi) inside your repl. I am assuming you cloned the project in a directory that asdf can see.

See the official instructions for further reading on how to setup a local private testnet.

ethi's People

Contributors

tsikov avatar browep avatar

Watchers

James Cloos 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.