Clone this repository then update xud submodule
git submodule updateMake sure you have virtualenv command in your local system.
which virtualenvIf virtualenv is not installed in your system then install it by
pip install virtualenvCreate a python virtual environment. Specify -p with your local python 3 executable name (maybe python3, python3.6, python3.7, etc.)
virtualenv -p python3 --no-site-packages venvActive your installed virtual environment. You can deactive it by just typing deactive later.
venv/bin/activeInstall python dependencies
pip install -r requirements.txtCompile gRPC protocols
python -m grpc_tools.protoc -I ./xud/proto --python_out=. --grpc_python_out=. ./xud/proto/xudrpc.proto
python -m grpc_tools.protoc -I ./xud/proto --python_out=. ./xud/proto/annotations.proto
python -m grpc_tools.protoc -I ./xud/proto --python_out=. ./xud/proto/google/api/http.proto
python -m grpc_tools.protoc -I ./xud/proto --python_out=. ./xud/proto/google/protobuf/descriptor.protoRun this example. Notice you need to put xud tls.cert into this example directory.
python engine.pyYou can type help for more helps in the running example.