Skip to main content

Rizzbase Python SDK

Python 3.10+ SDK for the local Rizzbase engine. Install the engine separately first; the SDK never downloads or installs it automatically.

Install

Install the engine using the Linux/macOS or Windows PowerShell installer, or a verified release binary, following the engine installation guide. Then install the Python package from PyPI:

python -m pip install rizzbase

The engine must be on PATH or configured through RIZZBASE_BINARY. The constructor's binary_path option takes precedence over both.

Quick start

from getpass import getpass

from rizzbase import Rizzbase

db = Rizzbase("./my-project.rizz", getpass("Project passphrase: "))

# First run only; create() refuses to overwrite an existing Project.
db.create("My project")
# On later runs, use db.open() instead.

lobby = db.create_lobby("general")
db.create_yap(lobby["id"], "welcome", {"message": "hello"})
welcome = db.get_yap(lobby["id"], "welcome")
yaps = (
    db.query(lobby["id"])
    .where("message", "==", "hello")
    .limit(10)
    .execute()
)
page = db.query(lobby["id"]).limit(10).execute_page()
# Pass page["nextCursor"] to .cursor(next_cursor) for the next page.

For SDK binary selection and compatibility requirements, see the engine installation guide and Node.js SDK guide.

The synchronous API includes project creation/open, backup export/import, lobby and Yap CRUD, and query filtering/ordering. Failures raise RizzbaseError with a stable code and safe message. The SDK supports engine versions >=1.1.0 <2.0.0 and project format 1; it checks compatibility once per resolved binary path.

Rizzbase(..., retry={...}) optionally configures max_attempts (default 3), base_delay_ms (75), max_delay_ms (1000), total_budget_ms (2000), and lock_wait_ms (1000); time budgets must be less than timeout_s. Only read-only calls retry ENGINE_TIMEOUT with full-jitter exponential backoff. The retry budget begins after the first timeout and includes subsequent calls and delays. Writes are never replayed after a timeout; they wait for an existing writer only up to lock_wait_ms. db.doctor() returns non-destructive diagnostics and performs full decrypt/validation using the instance passphrase. RizzbaseError.context carries structured lock owner details for PROJECT_BUSY when available. Cross-instance and cross-process behavior is described in the concurrency contract.

Passphrase rotation

There is no passphrase recovery or in-place key change. If you know the current passphrase, rotate by exporting a plaintext JSON backup and importing it into a new encrypted Project with a new passphrase:

from getpass import getpass
from rizzbase import Rizzbase

source = Rizzbase("./project.rizz", getpass("Current passphrase: "))
source.export("./project-rotation.json")

destination = Rizzbase("./project-rotated.rizz", getpass("New passphrase: "))
destination.import_backup("./project-rotation.json")
destination.open()  # Verify the new Project before switching applications.

Stop writes during migration, protect the backup because it contains decrypted Project data, and keep the source until the imported Project has been verified. Export and import do not overwrite existing files. See the security guide for the complete rotation and cleanup guidance.

db.create_yaps(lobby_id, [{"id": "...", "data": ...}, ...]) atomically creates 1–1000 Yaps in one engine process; duplicate IDs or an existing ID reject the full batch. For pagination, db.query_yap_page(lobby_id, options) returns {"yaps": [...], "nextCursor": "..."}. Pass cursor in the next options or use .after(cursor).execute_page() on the query builder. Cursors are bound to the project, Lobby, and filter/order options, not page size. Pagination is not a snapshot: restart after project writes.

See the SDK overview, conformance fixtures, and runnable Node examples. Protocol, query, security, and limit details are also covered in the Node.js SDK guide.

Metadata

Release files for rizzbase 1.2.0

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

Source distribution (sdist)

Source distribution for rizzbase 1.2.0
File Size Uploaded Provenance Actions
rizzbase-1.2.0.tar.gz 14.6 kB Without provenance Details for rizzbase-1.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for rizzbase 1.2.0
File Interpreter ABI Platform Actions
rizzbase-1.2.0-py3-none-any.whl Python 3 none any Details for rizzbase-1.2.0-py3-none-any.whl

Total release size: 25.4 kB

Release files / rizzbase-1.2.0.tar.gz

Download URL rizzbase-1.2.0.tar.gz
Size 14.6 kB
Tags Source
SHA-256 checksum
How to use checksums
fbbc5e9aafb56a690eaf6fa23a58c93eeef041c23b8454780e8fd2502f482a0a
BLAKE2b-256 checksum
How to use checksums
6b550a4f13eb843e00d2fcc87a267ae89c25987931052bf0740aa507c55107d7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / rizzbase-1.2.0-py3-none-any.whl

Download URL rizzbase-1.2.0-py3-none-any.whl
Size 10.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
922e12b7ce861d7668c03de58748f547c10e8c9b267b35ffb4e2dcda3cb4ec35
BLAKE2b-256 checksum
How to use checksums
6702385ab8f5f0aeb2b40d8aa5787835c5e9a34ecb85c38eb583b993e376db65
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Security for rizzbase 1.2.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.

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.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.2.0 This release

2 release files No provenance

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