Skip to main content

Python Library for development of Rialtic Insight Engines

Project description

Rialtic Engine Development Library (Python)

This repository contains common modules for developing Rialtic Insight Engines with Python.

API Documentation (Sphinx)

The code in this repository is documented using sphinx and autodoc. This documentation can be generated locally. autodoc will generate basic documentation automatically from code, and docstrings in the code can be used to add additional information to the generated documentation.

Documentation Practices

Docstring Format

We use sphinx.ext.napoleon, which allows us to use a simpler, more concise format for docstrings (popularized by NumPy and Google projects). See the NumPy documentation for an overview of how to use this style of docstrings.

NOTE: One main way that our docs differ from the standard described in the NumPy docs is with regard to the Returns section. We do not need to specify return type in our docs—we have the sphinx_autodoc_typehints extension, which automatically reads return type from type annotations in code.

Docstring Guidelines

Any docstrings written will eventually need to be edited or rewritten. With this in mind, it is valuable for our docstrings to be concise and minimal, providing only necessary information, to reduce the work required to maintain these docs.

For simple methods and functions, the generated function signature docs may even be sufficient. In these cases a docstring can consist of only a single line summary.

If you find yourself writing a very long complex docstring, consider whether the object being documented could use a refactor, or needs to be simplified in some way.

Generating HTML Documentation Locally

The generated documentation will be hosted somewhere accessible on the web, but can also be generated locally in several formats including HTML and PDF. Follow the instructions below to generate HTML documentation locally:

  1. $ git clone git@github.com:rialtic-community/rialtic-engine-lib-py.git
    $ cd rialtic-engine-lib-py/docs
    $ make html
    
  2. Open the following file in a browser

    rialtic-engine-lib-py/docs/_build/html/index.html
    

Engine Data SDK

Publishing to Nexus repository

This is likely to change quite a bit before it stabilizes, so we are keeping only one set of instructions as a source of truth.

For a step by step, please, refer to the instructions in the README.md in branch release-makefile in the schema repository.

schema repository

In addition to the environment variables that have to be defined (as explained in the link above), for this repository, we also have to define:

export APIKEY=...
export RIALTIC_REF_DB=demodb
export RIALTIC_DATA_ENV=local

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rialtic-engine-lib-py-1.13.36.tar.gz (56.0 kB view hashes)

Uploaded Source

Built Distribution

rialtic_engine_lib_py-1.13.36-py3-none-any.whl (74.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page