/blackstone

Smart contracts and high level API powering the Network

Primary LanguageTypeScriptOtherNOASSERTION

/$$       /$$                     /$$                   /$$
| $$      | $$                    | $$                  | $$
| $$$$$$$ | $$  /$$$$$$   /$$$$$$$| $$   /$$  /$$$$$$$ /$$$$$$    /$$$$$$  /$$$$$$$   /$$$$$$
| $$__  $$| $$ |____  $$ /$$_____/| $$  /$$/ /$$_____/|_  $$_/   /$$__  $$| $$__  $$ /$$__  $$
| $$  \ $$| $$  /$$$$$$$| $$      | $$$$$$/ |  $$$$$$   | $$    | $$  \ $$| $$  \ $$| $$$$$$$$
| $$  | $$| $$ /$$__  $$| $$      | $$_  $$  \____  $$  | $$ /$$| $$  | $$| $$  | $$| $$_____/
| $$$$$$$/| $$|  $$$$$$$|  $$$$$$$| $$ \  $$ /$$$$$$$/  |  $$$$/|  $$$$$$/| $$  | $$|  $$$$$$$
|_______/ |__/ \_______/ \_______/|__/  \__/|_______/    \___/   \______/ |__/  |__/ \_______/
The Blackstone codebase is a collection of smart contracts which together form the basis for the Agreements Network.

It is named after Sir William Blackstone, an English jurist, judge, and politician of the eighteenth century.

This collection includes a full-feature business process execution engine in Solidity, with Typescript bindings. It also include an object management suite utilized by the Agreements Network.

Preliminary Note

While the code in this repository is geared towards its use in the Agreements Network, the lower-level functions and smart contracts are highly reusable and suited to build any blockchain-based ecosystem application. If you would like to learn more about the interfaces used in this system please visit the documentation site for the network.

To ask questions or to learn more feel free to join the Agreements Network mailing list to ask questions or to join the community.

Prerequisites

  • make
  • docker
  • yarn
yarn add global ts-node
yarn add global typescript

Getting Started

Install all dependencies.

yarn install

Run a single-node Burrow chain.

make docker_run_chain

Launch the tests, deploying the suite beforehand.

yarn test

Compilation

If you update the Solidity contracts, you must re-compile the framework to get up-to-date bindings.

yarn build

This will also compile the Typescript, saving build artifacts to ./dist. There are separate scripts listed in package.json.

Alternatively, we also support compilation, linking and deployment via the legacy deploy tooling.

make build_contracts

Upgrades

cd ./src
burrow deploy --chain=localhost:10997 --address=${ADDRESS} --bin-path ./bin ../upgrades/${UPGRADE}.yaml