Skip to main content

SDK for interacting with the Comotion APIs

Project description

comotion-sdk

comotion-sdk is the python SDK for interacting with the Comotion APIs. Initial support is limited to Dash, but may expand in future.

Documentation

Documentation for this module can be found here.

Contributing

In order to contribute to this project, fork this repo and submit a pull request to this project

In order to set up a local environment, pull this repo and install.

pipenv is used to manage dependencies on this project. in order to use it, ensure that pipenv is installed.

pip install --upgrade pip
pip install pipenv

And then enter the virtual environment for this project that will automatically ensure all dependencies are available

pipenv install -e .
pipenv shell

Adding modules

Ensure dependencies are also added to setup.py in the install_requires section. Then run

pipenv install -e .

Ensure you understand pipenv when [installing new libraries] (https://pipenv.pypa.io/en/latest/install/#installing-packages-for-your-project).

running tests

To run tests

pipenv install --deploy --dev
pipenv run test -v

Building docs

Run the following from the docs directly. Ensure to watch out for warnings. pipenv install --dev make html

Rerunning code generator

We use OpenApi generator to generate the python.

The requirements for this are a swagger file that can be gotten from WHERE?

The latest swagger file is stored in openapi_generator/comodash_api_swagger.json

Download latest jar of OpenAPI Generator

java -jar \
  ./openapi_generator/openapi-generator-cli.jar generate \
        -i ./openapi_generator/comodash_api_swagger.yaml\
        -g python \
        --package-name comodash_api_client_lowlevel \
        --additional-properties \
            generateSourceCodeOnly=True,library=urllib3 \
        -o ./src/

We have changed from asyncio to urllib3 to ensure simplicity in coding without requiring "await" and "async"

To generate an html of the api:

java -jar \
  ./openapi_generator/openapi-generator-cli.jar generate \
        -i ./openapi_generator/comodash_api_swagger.yaml\
        -g html \
        -o ./html/

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

comotion_sdk-0.0.29-py3-none-any.whl (102.6 kB view details)

Uploaded Python 3

File details

Details for the file comotion_sdk-0.0.29-py3-none-any.whl.

File metadata

File hashes

Hashes for comotion_sdk-0.0.29-py3-none-any.whl
Algorithm Hash digest
SHA256 d8ba0fbc9bfa45096cdb143c5dd7bbf7cca4d1627e6803d43150973717acb4e0
MD5 edda7b8f33ba17bc7cae357308eabdc0
BLAKE2b-256 b345917c8e5f86b72b6fdbe5c5377181fdff5116ba268ff784dd8cdb29b6a6c0

See more details on using hashes here.

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