A utility library for common Python tasks.
Project description
HyperNova SDK
A utility library for common Python tasks.
Installation
pip install hypernova-sdk
Quick Start
import hypernova_sdk
print(hypernova_sdk.__version__)
Display Utilities
Rich-powered logging and output helpers.
import hypernova_sdk
# Print helpers
hypernova_sdk.print_success("It worked!")
hypernova_sdk.print_warning("Watch out!")
hypernova_sdk.print_error("Something went wrong")
hypernova_sdk.print_info("Here's some info")
hypernova_sdk.print_header("Section Title")
# Tables
hypernova_sdk.print_table("Name", "Age", rows=[("Alice", "30"), ("Bob", "25")])
# Trees
hypernova_sdk.print_tree("Project", ("src", ["a.py", "b.py"]), "README.md")
# Progress bar
with hypernova_sdk.progress() as prog:
task = prog.add_task("Downloading...", total=100)
for i in range(100):
prog.update(task, advance=1)
# Spinner
with hypernova_sdk.status("Loading..."):
data = fetch_data()
# Timer
with hypernova_sdk.timer("Operation"):
do_work()
# Or use the logger directly
from hypernova_sdk import nova_log
nova_log.success("Done!")
Cache Utilities
Thread-safe caching utilities with optional TTL.
@ttl_cache(seconds=60) — Decorator
Cache function results with a time-to-live expiry.
import time
from hypernova_sdk import ttl_cache
@ttl_cache(seconds=30)
def fetch_data(url):
# Simulate slow I/O
time.sleep(2)
return {"data": "value"}
print(fetch_data("https://api.example.com")) # 2s delay
print(fetch_data("https://api.example.com")) # instant (cached)
@memoize — Decorator
Simple unbounded memoization (no expiry, lifetime of process).
from hypernova_sdk import memoize
@memoize
def expensive_computation(x, y):
return x ** y
print(expensive_computation(2, 10)) # computed
print(expensive_computation(2, 10)) # cached
TTLCache — Class
Manual key-value cache with TTL and LRU eviction.
from hypernova_sdk import TTLCache
cache = TTLCache(ttl=60, maxsize=256)
cache.set("user:1", {"name": "Alice", "role": "admin"})
print(cache.get("user:1")) # {'name': 'Alice', 'role': 'admin'}
cache.clear() # remove all entries
License
MIT License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file hypernova_sdk-1.0.0.tar.gz.
File metadata
- Download URL: hypernova_sdk-1.0.0.tar.gz
- Upload date:
- Size: 19.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a753ef008d184347a7daa51ef652773d8526e4ab090260a90d87a0be3a29a512
|
|
| MD5 |
8880064b32412c27c8520c51d6f8d4bd
|
|
| BLAKE2b-256 |
28eaacfb8e193b8281dfaadcf95e9e7b996ec9906873e5c3d224a4c193b36c98
|
Provenance
The following attestation bundles were made for hypernova_sdk-1.0.0.tar.gz:
Publisher:
publish.yml on risqiikhsani/novasdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
hypernova_sdk-1.0.0.tar.gz -
Subject digest:
a753ef008d184347a7daa51ef652773d8526e4ab090260a90d87a0be3a29a512 - Sigstore transparency entry: 1392573917
- Sigstore integration time:
-
Permalink:
risqiikhsani/novasdk@d330e73443ee500ceb83afb62a05ba00484f975b -
Branch / Tag:
refs/tags/1.0.0 - Owner: https://github.com/risqiikhsani
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d330e73443ee500ceb83afb62a05ba00484f975b -
Trigger Event:
release
-
Statement type:
File details
Details for the file hypernova_sdk-1.0.0-py3-none-any.whl.
File metadata
- Download URL: hypernova_sdk-1.0.0-py3-none-any.whl
- Upload date:
- Size: 7.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0bf4f707b7bd7a98e3022d68a8fff5328f9625d7fa5a8f737e494da0b7e39387
|
|
| MD5 |
ae74046aab2fe90e809242ff56193733
|
|
| BLAKE2b-256 |
4c5695b5d2245dd21c5cbd12fa953344cc75bd69ee7212e93078f4e8c1ec1edf
|
Provenance
The following attestation bundles were made for hypernova_sdk-1.0.0-py3-none-any.whl:
Publisher:
publish.yml on risqiikhsani/novasdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
hypernova_sdk-1.0.0-py3-none-any.whl -
Subject digest:
0bf4f707b7bd7a98e3022d68a8fff5328f9625d7fa5a8f737e494da0b7e39387 - Sigstore transparency entry: 1392573920
- Sigstore integration time:
-
Permalink:
risqiikhsani/novasdk@d330e73443ee500ceb83afb62a05ba00484f975b -
Branch / Tag:
refs/tags/1.0.0 - Owner: https://github.com/risqiikhsani
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d330e73443ee500ceb83afb62a05ba00484f975b -
Trigger Event:
release
-
Statement type: