A framework to connect other cryptocurrencies to the Waves platform.
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs Adds .nojekyll file to docs folder Mar 8, 2018
test-env Adds master version of waves-gateway-package Mar 3, 2018
tests Fixes problem that the Waves fee is converted with the AssetIntegerCo… Apr 15, 2018
waves_gateway Adds option (waves_chain_id) to overwrite chain_id parameter on pywav… Apr 22, 2018
web
.angular-cli.json
.gitignore Adds enhanced documentation generation with Sphinx Mar 8, 2018
.prettierrc Adds master version of waves-gateway-package Mar 3, 2018
.pylintrc Adds master version of waves-gateway-package Mar 3, 2018
CHANGELOG.md Updates changelog for release v1.0.3 Apr 22, 2018
LICENSE
MANIFEST.in Final adjustments to prepare publishing the package to PyPi Mar 8, 2018
README.rst
karma.conf.js Adds master version of waves-gateway-package Mar 3, 2018
package-lock.json Updates bootstrap to stable. Fixes problem that copying the coinAddre… Apr 17, 2018
package.json Release v1.0.3 Apr 22, 2018
proxy-conf.json
setup.py Release v1.0.3 Apr 22, 2018
tsconfig.json
tslint.json Adds master version of waves-gateway-package Mar 3, 2018

README.rst

Waves-Gateway-Framework

A framework to connect other cryptocurrencies to the Waves platform. Requires Python 3.5 or newer.

For detailed usage instructions please refer to the source code documentation that may be exported by using the commands described below. The framework exports a class Gateway. This class has to instantiated. Once done, the Gateway can be started by calling the run method on the resulting instance.

The constructor of the Gateway class requires instances of certain interfaces. Those interfaces define the required functionality that a concrete Gateway implementation has to provide. You may also take a look at an example implementation that realizes a Waves-Gateway for Litecoin: https://github.com/jansenmarc/WavesGatewayLTCExample.

How to install

pip install waves-gateway

Required packages for development

python3.5 -m pip install coverage mypy pylint Sphinx

Lint

The PyLint package is required for linting. Install it like this: pip install pylint.

python3.5 setup.py lint

MyPy

The MyPy package performs static type analysis to prevent errors.

python3.5 setup.py mypy

Unittest

python3.5 setup.py test

The convention is to write Unittests for every class in a separate file starting with test_ This is the default prefix of the python Unittest module.

Coverage

python3.5 setup.py coverage

Documentation Generation

Creates a folder docs with the generated HTML documentation.

pip install . -U
python3.5 setup.py docs

Doctest

Doctests are not used in this project. Write Unittests instead.

yapf

This project uses yapf (https://github.com/google/yapf) as a formatting tool So, please format your code before commiting by running this:

python3.5 -m yapf -r waves_gateway --style pep8 --style {COLUMN_LIMIT:120} -i

The pipeline will fail if the code is not properly formatted.

Distribution

First, run npm run build:prod to update the assets. After that, run python3.5 setup.py sdist to create an installable tar archive.

Publish to test.pypi.org:

twine upload --repository-url https://test.pypi.org/legacy/ dist/*

Regular publish:

twine upload dist/*

Recommendations