Skip to main content

SOL Python ORM Library

Installation

pip install sol-orm-lib

Example usage

from sol_orm_lib.models import *
from sol_orm_lib.sol_orm import SolORM

# Instantiate SolORM object
db = SolORM("https://db-api.sol.idener.es")

# Create an object 
mw = MeasuredWeather(
    rad_ar=27.2,
    temp_ar=39,
    wind_ar=12,
    timestamp=current_milli_time(),
)

# Add it to the DB
response = db.add_entity(mw)
print(response)

Local ORM

from sol_orm_lib.models import *
from sol_orm_lib.sol_local_orm import SolLocalORM

db = SolLocalORM(host="100.91.35.146", port=3306, db="bcm", user="bcm", password="bcm", debug=True)

ent = StorageStatusTAC(
    k=1,
    n=2,
    storageActual=3,
    storageActualKwh=4,
    storageInverterRealised=5,
    storageMax=6
)

db.add_entity(ent)
result = db.get_last_entity(StorageStatusTAC)
print(result)

Release process

To release a new version of the package, update the version number in the pyproject.toml file and publish a release with the same tag. The CI will build and publish the package to PyPI.

Metadata

Release files for sol-orm-lib 0.4.8

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for sol-orm-lib 0.4.8
File Size Uploaded Provenance
sol_orm_lib-0.4.8.tar.gz 9.4 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for sol-orm-lib 0.4.8
File Interpreter ABI Platform
sol_orm_lib-0.4.8-py3-none-any.whl Python 3 none any Details

Total release size: 19.5 kB

Release files / sol_orm_lib-0.4.8.tar.gz

Download URL sol_orm_lib-0.4.8.tar.gz
Size 9.4 kB
Tags Source
SHA-256 checksum
How to use checksums
fdb8a014bcc651e4ba20996e9ee6b941710f862f1a1b3f7622510cb7d05b22c7
BLAKE2b-256 checksum
How to use checksums
d1a4488deb28872d882b10933b8b3b8fab68f45ca1eb6deafc9da9ba2bd79f33
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.1 CPython/3.8.18 Linux/5.15.0-84-generic

Release files / sol_orm_lib-0.4.8-py3-none-any.whl

Download URL sol_orm_lib-0.4.8-py3-none-any.whl
Size 10.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a61a1c50a7cbb32e38dfd8fcf4a4eafea5cbfdfec2aee3a704e1dcae31b8df2b
BLAKE2b-256 checksum
How to use checksums
a4d834efde1d144bd95c8879bbbc98d29a5ac49f88ab9b3909e68377dd0d8c42
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.1 CPython/3.8.18 Linux/5.15.0-84-generic

Security for sol-orm-lib 0.4.8

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page