From 80cf3927865f67f8bdd73f19b76529d160ed411c Mon Sep 17 00:00:00 2001 From: Norman Fomferra Date: Wed, 8 Jul 2026 06:58:14 +0200 Subject: [PATCH] preparing 0.3.3 release --- remotestate-py/CHANGES.md | 12 ++++++------ remotestate-py/pyproject.toml | 2 +- remotestate-py/src/remotestate/store.py | 10 +++++----- remotestate-ts/CHANGES.md | 2 +- remotestate-ts/package-lock.json | 4 ++-- remotestate-ts/package.json | 2 +- 6 files changed, 16 insertions(+), 16 deletions(-) diff --git a/remotestate-py/CHANGES.md b/remotestate-py/CHANGES.md index 10b56ec..d93d693 100644 --- a/remotestate-py/CHANGES.md +++ b/remotestate-py/CHANGES.md @@ -1,12 +1,12 @@ -## Version 0.3.3 (in development) +## Version 0.3.3 - Improved usability of the Python `Store` class: - - Introduced public protocol `StoreAt` now returned - from `Store.at` instead of internal `_StoreAt` type. - - Added `StoreAt.value` read-only property to access the value - of a node returned by `Store.at`. + - Introduced public protocol `StoreAt` now returned from `Store.at` instead + of internal `_StoreAt` type. + - Added `StoreAt.value` read-only property to access the value of a node + returned by `Store.at`. -- The Python `ServeResult` class now renders as a HTML table in notebooks. +- The Python `ServeResult` class now renders as an HTML table in notebooks. ## Version 0.3.2 diff --git a/remotestate-py/pyproject.toml b/remotestate-py/pyproject.toml index 27e5373..0de3c23 100644 --- a/remotestate-py/pyproject.toml +++ b/remotestate-py/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "remotestate" -version = "0.3.3.dev0" +version = "0.3.3" authors = [{name = "forman"}] description = "Python state, React UI." readme = "README.md" diff --git a/remotestate-py/src/remotestate/store.py b/remotestate-py/src/remotestate/store.py index 72dd09e..31b2231 100644 --- a/remotestate-py/src/remotestate/store.py +++ b/remotestate-py/src/remotestate/store.py @@ -34,10 +34,9 @@ def __init__( value is supported, including mappings, lists, and scalars. default_factory: Optional callable used by ``set()`` to create missing intermediate path values. It receives the - missing prefix path as a ``Path`` tuple, such as one - containing ``"user"`` or ``0`` segments. - If omitted, missing parents raise the same ``KeyError``, - ``IndexError``, or ``AttributeError`` as before. + missing prefix path as a ``Path`` tuple, such as ``("users", 3)``. + If omitted, a missing parent will raise either a ``KeyError``, + ``IndexError``, or ``AttributeError``. """ self._state = initial self._default_factory = default_factory @@ -195,8 +194,8 @@ def __repr__(self) -> str: ... class _StoreAt(StoreAt): """Path-building proxy implementation returned by ``Store.at``.""" - _path: Path _store: Store[Any] + _path: Path # Only these names are real attributes; all other attributes are path segments. # It prevents silently and accidentally created attributes. @@ -208,6 +207,7 @@ def __init__(self, store: Store[Any], path: Path = ()) -> None: @property def value(self) -> Any: + """The store's value at the current path location.""" return self._store.get(self._path) def __getattr__(self, name: str) -> _StoreAt: diff --git a/remotestate-ts/CHANGES.md b/remotestate-ts/CHANGES.md index 5abce40..02161b1 100644 --- a/remotestate-ts/CHANGES.md +++ b/remotestate-ts/CHANGES.md @@ -1,4 +1,4 @@ -## Version 0.3.3 (in development) +## Version 0.3.3 - Improved usability of the Python `Store` class. diff --git a/remotestate-ts/package-lock.json b/remotestate-ts/package-lock.json index 315ab50..7f71400 100644 --- a/remotestate-ts/package-lock.json +++ b/remotestate-ts/package-lock.json @@ -1,12 +1,12 @@ { "name": "remotestate", - "version": "0.3.2-dev.0", + "version": "0.3.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "remotestate", - "version": "0.3.2-dev.0", + "version": "0.3.3", "license": "MIT", "devDependencies": { "@eslint/js": "^9.0.0", diff --git a/remotestate-ts/package.json b/remotestate-ts/package.json index 5b6cd8e..1e94fb7 100644 --- a/remotestate-ts/package.json +++ b/remotestate-ts/package.json @@ -1,6 +1,6 @@ { "name": "remotestate", - "version": "0.3.2", + "version": "0.3.3", "description": "Python state, React UI.", "type": "module", "main": "./dist/remotestate.js",