Skip to content

Setheum: zk-SNARKs Enabled Blockchain for Interoperable Smart Contracts, Off-Chain Compute and Storage Cloud. Ready for hacking ๐Ÿš€

Notifications You must be signed in to change notification settings

openweb3-foundation/Setheum1

ย 
ย 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

ุจูุณู’ู…ู ุงู„ู„ูŽู‘ู‡ู ุงู„ุฑูŽู‘ุญู’ู…ูŽู†ู ุงู„ุฑูŽู‘ุญููŠู…

Setheum - Powering Scalable Web3 Solutions

  • Secure
  • Decentralized
  • Scalable
  • Confdential
  • Ethical
  • Interoperable

Setheum's Blockchain Network node Implementation in Rust, ready for hacking ๐Ÿš€

Setheum version Substrate version License

Twitter URL Telegram Medium

Introduction

SETHEUM means Salam Ethereum, it also means The house of gifts from the name Seth/Sheeth meaning gift in hebrew and the name of the Prophet Sheeth/Seth,

it also stands for Secure, Evergreen, Truthful, Heterogeneous, Economically Unbiased Market.

Setheum is a secure, confidential and interoperable decentralised internet cloud compute and storage blockchain network with EVM and WASM smart contracts, web3 and web 2 Support. The intent of the Setheum Network is to improve upon Web3 and solve the blockchain trilemma with a mixture of approaches and a recipe formed from what we have seen and considered to be some of the best solutions in the field, improving on scalability, security, mass adoption, diversity, and ethics while preserving decentralisation and democratisation. Setheum intends to be the most scalable blockchain network in the world while providing confidentiality for smart contracts, Cloud Computing and Storage Infrastructure for Web3 based Internet Solutions and Interoperability with both Web2 and other Web3 Networks. The Setheum DAGESTAN architecture powers the network to be the most scalable network in the world; it enables near instant finality, high throughput, high scalability and interoperability for the Setheum Network.

Setheum, founded November 2019, achieves a high level of equilibrium in the trilemma by leveraging a Directed Acyclic Graph(DAG) to build the blockchain consensus making it a Blockchain via DAG, achieve instant finality, high throughput and very fast blocktime while preserving network security and having a fairly decentralised network, Setheumโ€™s consensus system leans towards achieving high scalability and high security with an ethical, decent and equitably high level of decentralisation.

Setheum is EVM(Ethereum Virtual Machine) compatible for smart contracts to thrive on its super fast blockchain, the entire chain is upgradable and forkless enabling forkless upgrades as Setheum is built with the Substrate framework using the Rust programming language. Ethical DeFi Suite powers the Ethical DeFi revolution on Setheum, being on the fastest public blockchain network in the world and leveraging all the benefits that come with being on Setheum, making it a DeFi optimised blockchain especially exceptional for DeFi applications and solutions.

Ethical DeFi Suite is the DeFi powerhouse of the Setheum Network, providing all kinds of top notch DeFi protocols including a cutting-edge AMM DEX, modules, Decentralised Liquid Staking for Setheum SE and ethical zero-interest halal stablecoins that gives us the properties of both Fiat and Crypto with SlickUSD (USSD) and the Setter (SETR) using an Ethical Collateralized Debt Position (ECDP) mechanism that is over-Collateralized and multi-Collateralised and stable without compromising decentralisation or economic stability, offering zero-interest loans of stable cryptocurrencies that has scalable value and trust, setheum provides just that, backed by crypto assets with efficient zero-interest loans.

Getting Started

This project contains some configuration files to help get started ๐Ÿ› ๏ธ

Initialisation

Clone this repository:

git clone --recursive https://github.com/Setheum-Labs/Setheum

Install Rust:

curl https://sh.rustup.rs -sSf | sh

If, after installation, running rustc --version in the console fails, refer to it to repair.

You can install developer tools on Ubuntu 20.04 with:

sudo apt install make clang pkg-config libssl-dev build-essential

You can install the latest Rust toolchain with:

make init

Make sure you have submodule.recurse set to true to configure submodule.

git config --global submodule.recurse true

Install required tools and install git hooks:

git submodule update --init --recursive

Start a development node

The make run command will launch a temporary node and its state will be discarded after you terminate the process.

make run

Run a persistent single-node chain

Use the following command to build the node without launching it:

make build

This command will start the single-node development chain with persistent state:

./target/release/setheum-node --dev

Purge the development chain's state:

./target/release/setheum-node purge-chain --dev

Start the development chain with detailed logging:

RUST_LOG=debug RUST_BACKTRACE=1 ./target/release/setheum-node -lruntime=debug --dev

Run tests

make test

Run benchmarks

Run runtime benchmark tests:

make bench

Run module benchmark tests:

cargo test -p module-poc --all-features

Run the module benchmarks and generate the weights file:

./target/release/setheum-node benchmark \
    --chain=dev \
    --steps=50 \
    --repeat=20 \
    --pallet=module_currencies \
    --extrinsic='*'  \
    --execution=wasm \
    --wasm-execution=compiled \
    --heap-pages=4096 \
    --output=./chassis/lib-serml/currencies/src/weights.rs

Run in debugger

make debug

Nodes

For Docs on running nodes, check ./docs/nodes.md

Embedded docs

Once the project has been built, the following command can be used to explore all parameters and subcommands:

./target/release/setheum-node -h

Release builds

To list all available release builds run:

git tag

To create a corresponding production build, first checkout the tag:

git checkout testnet-1

Then run this command to install appropriate compiler version and produce a binary.

make release

On-Chain upgrade builds

Build the wasm runtime with:

make wasm

Update

Update Cargo

make update

Update ORML

cd lib-orml && git checkout master && git pull
git add lib-orml
cargo update check-all

Update Predeploy-Contracts

cd chassis/lib-sesl/predeploy-contracts && git checkout master && git pull
git add predeploy-contracts
cargo update check-all

Generate Tokens & Predeploy Contracts - SetheumEVM (SEVM)

make generate-tokens

Note: All build commands with SKIP_WASM_BUILD are designed for local development purposes and hence have the SKIP_WASM_BUILD enabled to speed up build time and use --execution native to only run use native execution mode.

Bench Bot

Bench bot can take care of syncing branch with master and generating WeightInfos for module or runtime.

Generate Module weights

Generate Weights on Git with PR

Comment on a PR /bench runtime module <setheum_module_name> i.e.: serp_prices

Bench bot will do the benchmarking, generate weights.rs file push changes into your branch.

Generate Runtime Module Weights Locally
make benchmark

Fork setheum-chain

You can create a fork of a live chain (testnet / mainnet) for development purposes.

  1. Build binary and sync with target chain on localhost defaults. You will need to use unsafe rpc.
  2. Execute the Make command ensuring to specify chain name (testnet / mainnet).
make chain=testnet fork
  1. Now run a forked chain:
cd fork/data
./binary --chain fork.json --alice

LICENSES

The projects included in this repo have different licenses which can be found in their individual directories listed below, some use GPL3, some Apache-2.0 while some use the Business Source License 1.1 (BUSL-1.1).

Other than the listed above (which are all imported submodules), the remaining of the primary codebase in this repo, is under GPL3.

The License Types

For a look, check ./LICENSES

  1. Apache-2.0
  2. BUSL-1.1
  3. GPL3

TODO

Update licenses and restructure repo

About

Setheum: zk-SNARKs Enabled Blockchain for Interoperable Smart Contracts, Off-Chain Compute and Storage Cloud. Ready for hacking ๐Ÿš€

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 98.1%
  • Handlebars 0.8%
  • JavaScript 0.6%
  • Makefile 0.3%
  • Python 0.2%
  • Dockerfile 0.0%