Giter Club home page Giter Club logo

pyc8's Introduction

PyC8 SDK

PyPI PyPI - Python Version PyPI - Format PyPI - Wheel PyPI - Downloads

Python SDK for the Macrometa Global Data Mesh.


๐Ÿ Supported Python Versions

This SDK supports the following Python implementations:

  • Python 3.4 - 3.10

โš™๏ธ Installation

Install from PyPi using pip, a package manager for Python.

pip install pyC8

๐Ÿ” Authentication

Currently, pyC8 supports API Key, JWT token, username and password authentication. Preferred method needs to be passed during client creation. We highly recommend that you use API key or JWT token.

You can create you test Macrometa account with this link.

After that you can check out our getting started code examples.

๐Ÿงฐ Development environment

To enable development environment position ourselves to project's root and run:

pip install -r requirements/dev.txt

๐Ÿงช Testing

End-to-end tests can be found in tests/. Before first run create .env file in tests/. In .env file add variables:

  • FEDERATION_URL="<your federation url>"
  • FABRIC="<selected fabric>"
  • API_KEY="<your api key>"

.env file is in .gitignore.

To run tests position yourself in the project's root while your virtual environment is active and run:

python -m pytest

Since we have end-to-end test we use VCR package to record our response so tests can be faster in next iteration. Example:

pytest --record-mode=once test_redis.py

Cassettes folder will be created with '.yaml'. Each test will have its own file.

๐Ÿ“ Enable pre-commit hooks

You will need to install pre-commit hooks Using homebrew:

brew install pre-commit

Using conda (via conda-forge):

conda install -c conda-forge pre-commit

To check installation run:

pre-commit --version

If installation was successful you will see version number. You can find the Pre-commit configuration in .pre-commit-config.yaml. Install the git hook scripts:

pre-commit install

Run against all files:

pre-commit run --all-files

If setup was successful pre-commit will run on every commit. Every time you clone a project that uses pre-commit, running pre-commit install should be the first thing you do.

๐Ÿ‘จโ€๐Ÿ’ป Build

To build package we need to position ourselves to project's root and run:

 $ python setup.py build

๐Ÿช› Upgrade

pip install --upgrade pyC8

๐Ÿ“— Examples

You can find code examples in our getting started collection.

๐Ÿ†˜ Macrometa Support

If you have any trouble or need help while using SDK please contact [email protected].

โš–๏ธ License

This library is distributed under the Apache License 2.0 license found in the License.

๐Ÿ“œ Code of Conduct

This project and everyone participating in it is governed by the Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to [email protected].

pyc8's People

Contributors

darighost avatar davidlubomirov avatar dependabot[bot] avatar diana-macrometa avatar dlozina-macrometa avatar durgagokina avatar edgargarciamacrometa avatar georgikiriloff avatar hp-kulkarni avatar kartikeya-macrometa avatar koshy-thomas avatar pnarode avatar pnarodemacrometa avatar poorvamacrometa avatar ricardo-macrometa avatar shahpratikr avatar sulommacrometa avatar vipulmacrometa avatar warchiefx avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.