Skip to main content

statepatch

Immer-style ops over a plain JSON tree.

observable(initial) wraps one value: .value reads it, every mutation applies to the tree and emits the matching op (replace / add / remove) to subscribers. Observables compose: an observable stored inside another mounts its op stream at that path.

from statepatch import observable

state = observable({"runs": []})
state.subscribe(print)

run = observable({"runId": "r1", "queue": []})
state["runs"].append(run)          # add op at ["runs", 0]
run["queue"].append({"id": "q1"})  # forwarded as add at ["runs", 0, "queue", 0]
state["runs"].pop(0)               # remove op; run is detached and reusable

Metadata

Release files for statepatch 0.1.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 statepatch 0.1.0
File Size Uploaded
statepatch-0.1.0.tar.gz 6.8 kB Details

Built distribution (wheel)

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

Total release size: 12.3 kB

Release files / statepatch-0.1.0.tar.gz

Download URL statepatch-0.1.0.tar.gz
Size 6.8 kB
Tags Source
SHA-256 checksum
How to use checksums
a65cc0b535e9d126f35a005075e2c6388cb98c44665ac3ec478a90a06dfa582a
BLAKE2b-256 checksum
How to use checksums
de887b18532c28d21b1d15be23343efd616cbcb70d9da1eafd26e13344a51fbd
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 Aug 21, 2026.

Transparency log

Release files / statepatch-0.1.0-py3-none-any.whl

Download URL statepatch-0.1.0-py3-none-any.whl
Size 5.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b908e84a66655062e3bba75c581f95521d23761ccaabb4a673ee72ff81bc48b9
BLAKE2b-256 checksum
How to use checksums
6fa44a3a39066777c460151d0a85a63337ec8cd5988716425eab718f7f0e97c3
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 Aug 21, 2026.

Transparency log

Release history Release notifications | RSS feed

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.1

2 release files

This release

0.1.0 This release

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