Skip to main content

pytypehintstore

Rows of one validated dataclass, in memory, shadowed by a JSON file you can open and edit. The class is the database.

The file is named for the class and the fingerprint of its compiled schema, so if the file opens, every row in it is valid against this exact schema. Change the contract and it is a new database; the old file stays beside it, whole and readable.

from dataclasses import dataclass
from typing import Annotated
from pytypehint import Max, Min
from pytypehintstore import store_of

@dataclass
class Task:
    title: Annotated[str, Min(1), Max(80)]
    done: bool = False

tasks = store_of(Task, "data")              # data/Task.<fingerprint>.json
row_id = tasks.add(Task(title="Buy milk"))  # 1
tasks.get(row_id)                           # Task(title='Buy milk', done=False)
tasks.close()

The full documentation is at https://offerrall.github.io/pytypehintstore/.

Documentation

  • Overview: how the store works and a full walk-through of its operations.
  • The guarantee: every row a store opens was rebuilt through your schema.
  • The identity: the file name, and why any change to the class is a new database.
  • The file: the JSON on disk, editing it by hand, and every load error.
  • Writing: debounced, atomic dumps, rotated copies and close().
  • The lock: one process per store, and how orphaned lockfiles are taken over.
  • API: store_of, its methods and its exceptions.
  • Limits: what the store does not do, stated plainly.

Metadata

Release files for pytypehintstore 1.0.3

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

Source distribution (sdist)

Source distribution for pytypehintstore 1.0.3
File Size Uploaded
pytypehintstore-1.0.3.tar.gz 104.9 kB Details

Built distribution (wheel)

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

Total release size: 118.7 kB

Release files / pytypehintstore-1.0.3.tar.gz

Download URL pytypehintstore-1.0.3.tar.gz
Size 104.9 kB
Tags Source
SHA-256 checksum
How to use checksums
66b618c8dc64ddc6e1b17741ae786b64e47184ea301e6a77f5cf9212b6d13d4d
BLAKE2b-256 checksum
How to use checksums
45bbd528214b4d723083213b3b23958fb4324ace7b3b5f3e0a227eeeeca815e2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Sep 29, 2026.

Transparency log

Release files / pytypehintstore-1.0.3-py3-none-any.whl

Download URL pytypehintstore-1.0.3-py3-none-any.whl
Size 13.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
695e5e999006949f83828329833735d01446fc99601cc80a6f3a2b8bfcc9cf55
BLAKE2b-256 checksum
How to use checksums
613f0c703ef40fdf899ba8b9ec1def7c961091c35e02421f2e5619442c1441a6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.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 Sep 29, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

1.0.3 This release

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.0.4

2 release files

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