Skip to main content

Python client for HERO

Reason this release was yanked:

Yanked; use 0.15.1

Project description

HERO Python SDK

This is the Python SDK for HERO.

Installation

The HERO team recommends using uv to install and manage project dependencies.

Using uv

uv add https://github.nrel.gov/Hero/hero/archive/refs/tags/v0.14.0.zip

Using pip

pip install git+https://github.nrel.gov/Hero/hero@v0.14.0#egg=hero

Development Installation and Release

First, clone this repo locally. Then install dependencies and pre-commit hooks:

uv sync
uv run pre-commit install

To run the tests:

./run_test.sh

To link the local HERO codebase into a consuming project for feature development:

  • Checkout the target branch in this repo
  • In your consuming project, run uv add --editable THE-PATH-TO-THE-NEWLY-CLONED-HERO-REPO

Releasing a New Version

Once development is complete on a given feature/bugfix/etc, pleaes do the following to tag a new release.

  • Update the version in pyproject.toml.
  • Update the version in the Installation section(s) in the README.md (this file).
  • Add and commit the changes made in the above two steps.
  • Perform a non fast-forward the working branch into main
    • git checkout main
    • git merge --no-ff THE-BRANCH-NAME-YOU-ARE-MERGING.
  • Tag the main branch with the new version via git tag THE-NEW-VERSION-NUMBER
  • Push with tags git push && git push --tags

Usage

You need to have the following environment variables defined.

export HERO_ENV=["dev", "stage", "prod"]
export HERO_PROJECT="aeroportal-app"
export HERO_CLIENT_ID="*******************************"
export HERO_CLIENT_SECRET="*******************************"

Examples

Please check out the HERO examples.

Additionally, the tests in the test directory of this repo may also prove useful for basic usage examples.

SWR 26-024

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

hero_sdk-0.14.0.tar.gz (81.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hero_sdk-0.14.0-py3-none-any.whl (44.6 kB view details)

Uploaded Python 3

File details

Details for the file hero_sdk-0.14.0.tar.gz.

File metadata

  • Download URL: hero_sdk-0.14.0.tar.gz
  • Upload date:
  • Size: 81.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.5

File hashes

Hashes for hero_sdk-0.14.0.tar.gz
Algorithm Hash digest
SHA256 e081faa75f4aeb6b8fd6bda84a0146bf636b374c6dbb4e4dfe3c27288fa1e1ba
MD5 af21fa3d3fe3669bdf80f941fd85e872
BLAKE2b-256 9a5863459ac71da283ca1f00fa68a8a17f1ec8e2a6eafe2827552e1a9cf214af

See more details on using hashes here.

File details

Details for the file hero_sdk-0.14.0-py3-none-any.whl.

File metadata

  • Download URL: hero_sdk-0.14.0-py3-none-any.whl
  • Upload date:
  • Size: 44.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.5

File hashes

Hashes for hero_sdk-0.14.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c59f907664334a852c2e893ec4ce31126bbf4578c8cb95a7eeb07b6e0d46e42f
MD5 8414667da1717a662f8290b6b8573dee
BLAKE2b-256 c9f06f8de2af230bd5d788093537bafd91de1cea43527a604fed9b00fb6a4dc1

See more details on using hashes here.

Supported by

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