- Install Go recommended version 1.10 and above and setup golang workingspace, specifically environment variables like GOPATH.
- Use dep to manage package dependencies and generate package dependency graphs.
- Download:
$ go get -d github.com/DOSNetwork/core/...
- Build:
$ make build
- Local Test workflow:
$ make build && cd testing && make deploy && make buildDockers && cd ../ && docker-compose up --scale dosnode=3
$ go fmt .
or use IDE plugins format source code before commit.$ make clean
to remove unnecessary changes before commit.- If it's necessary to update on-chain smart contracts, update
github.com/DOSNetwork/eth-contracts
instead of modifying locally cloned submodules,$ git submodule update --remote --merge
to checkout latest changes. - Golang bindings for the on-chain contract are generated using tool
abigen
. - For common errors like "cannot find package "xxx" in any of: ...": Try:
$ unset GOROOT
and/or$ dep ensure -update
. - Create a new branch to upload pull requests for contributions.
- Shamir secret sharing
- Pedersen DKG algorithm
- Paring library and threshold bls signature
- Layer-2 P2P network based on Kademlia DHT with NAT support
- On-chain verification contracts and Ethereum chain adaptor
- Jsonpath and xmlpath parser
- ...