Skip to content

perun-network/perun-polkadot-backend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation


Perun

Perun Polkadot: Backend

License: Apache 2.0 CI status

This project implements a Substrate backend for our go-perun framework. It enables go-perun applications to create state-channels on Polkadot by connecting to the Perun Pallet.

Project structure

  • channel/ channel interface implementations
  • wallet/ wallet interface implementations
    • sr25519/ Schnorrkel-Ristretto Ed25519 wallet
  • pkg/ 3rd-party helpers
  • client/ helper functions for setting up a go-perun client
  • wallet/sr25519/test/accounts.json config for testing

Development Setup

If you want to locally develop with this project:

  1. Clone the repo:
git clone https://github.com/perun-network/perun-polkadot-backend
cd perun-polkadot-backend
  1. Start a local Substrate node with the Perun Pallet installed. See the polkadot node repository for more details.
docker run --rm -p 9944:9944 ghcr.io/perun-network/polkadot-test-node:0.4.0
  1. Run the tests. This step needs a working Go distribution, see go.mod for the required version.
go test -p 1 ./...

The tests take a while but should eventually finish successfully. The long testing time results from the block-time of the node. The -p 1 flag is important, since the tests otherwise are started in parallel and mess up the account nonce.

Demo

We prepared a demo CLI node to play around with payment channels on substrate chains.
Highly recommended you to check it out 👍

Funding

The development of this project is supported by the Web3 Foundation through the Grants Program.
The development of the go-perun library is supported by the German Ministry of Education and Science (BMBF) through a Startup Secure grant.

Security Disclaimer

This software is still under development. The authors take no responsibility for any loss of digital assets or other damage caused by the use of it.

Copyright

Copyright 2022 PolyCrypt GmbH.
Use of the source code is governed by the Apache 2.0 license that can be found in the LICENSE file.

About

Enables Perun Channels for Polkadot Chains.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages