Fluxum Python SDK
The asyncio-first Python client for the Fluxum realtime database (SPEC-011, T7.4). Zero runtime dependencies — the SDK carries its own minimal MessagePack codec and FluxBIN row reader.
pip install fluxum-sdk
import asyncio
from fluxum import Connection, TableSchema
async def main():
db = await Connection.connect(
"fluxum://127.0.0.1:15801",
token=b"my-token",
tables=[...], # from `fluxum generate --lang python`
)
await db.subscribe(["SELECT * FROM ChatMessage"])
await db.call_reducer("send_chat", [1, "hello"])
# TxUpdates land in db.cache; poll or read db.cache.rows("ChatMessage").
await db.close()
asyncio.run(main())
What you get
Connection— one asyncio session over FluxRPC/TCP: authenticate, subscribe (each query'sInitialDatapopulates a local row cache), call reducers, and receiveTxUpdatediffs on the same socket.- Transparent reconnect (SDK-047): on connection loss the client reconnects, re-authenticates, resubscribes every active query and reconciles its cache — the application keeps its handle across the outage.
- A per-table row cache keyed by primary key, with per-query ownership so
an
unsubscribedrops only the rows that query held (SDK-044). - Full type hints (
py.typed, SDK-062).
Typed bindings
Generate typed row classes and reducer wrappers from a running server's
schema (or a saved schema.json):
fluxum generate --lang python --schema http://127.0.0.1:15800 --out ./gen
This emits tables.py (a @dataclass row + decoder + cache hooks per
table), reducers.py (a typed async def per client-callable reducer),
__init__.py, and py.typed. Offline generation from a saved schema
produces byte-identical output (SPEC-011 acceptance 11).
Testing
The SDK is validated by the shared conformance corpus
(tests/conformance/)
— the same declarative
scenarios every Fluxum SDK runs against the same server build (TST-052). The
runner boots a fresh fluxum-server per scenario, so build it first:
cargo build -p fluxum-server
cd sdks/python && python -m pytest -q
Metadata
Release files for fluxum-sdk 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| fluxum_sdk-0.3.0.tar.gz | 22.5 kB | With provenance | Details for fluxum_sdk-0.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| fluxum_sdk-0.3.0-py3-none-any.whl | Python 3 | none | any | Details for fluxum_sdk-0.3.0-py3-none-any.whl |
Total release size: 41.7 kB
Release files / fluxum_sdk-0.3.0.tar.gz
| Download URL | fluxum_sdk-0.3.0.tar.gz |
|---|---|
| Size | 22.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ffabd1e2ef7855cd975f24cf58615f4236ce1ee70a52997171ac8a31bef04c53
|
|
BLAKE2b-256 checksum How to use checksums |
b82adabc740392fb6a573f119fd46d0dcbebc22473ae22b038c33d30a7993688
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 29, 2026.
Transparency logRelease files / fluxum_sdk-0.3.0-py3-none-any.whl
| Download URL | fluxum_sdk-0.3.0-py3-none-any.whl |
|---|---|
| Size | 19.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
71322c8ea98d515ed88c546cf88821088e6e7e2ef9d197ca0d68d1da36780625
|
|
BLAKE2b-256 checksum How to use checksums |
c418beb01c89f9534727f56bcf1829972936835cb659fa3494e83923aa2a3e52
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 29, 2026.
Transparency logSecurity for fluxum-sdk 0.3.0
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.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for fluxum_sdk-0.3.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 29, 2026.
Transparency logA 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.
To learn more about protecting yourself from malicious actors, visit our package security documentation.