skir-sqlalchemy
Super lightweight bridge between Skir serializers and SQLAlchemy JSON columns.
Install
pip install skir-sqlalchemy
DenseJson
DenseJson(serializer) stores values of type T in a SQLAlchemy JSON column using Skir's dense JSON format.
serializer:skir_client.Serializer[T]keep_unrecognized_values: forwarded toserializer.from_json(...)
Example
from sqlalchemy.orm import DeclarativeBase, Mapped, mapped_column
from skir_alchemy import DenseJson
from geometry_skir import Point
class Base(DeclarativeBase):
pass
class GeometryRow(Base):
__tablename__ = "geometry"
id: Mapped[int] = mapped_column(primary_key=True)
point: Mapped[Point | None] = mapped_column(DenseJson(Point.serializer))
Metadata
Release files for skir-sqlalchemy 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| skir_sqlalchemy-0.1.1.tar.gz | 4.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| skir_sqlalchemy-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 8.6 kB
Release files / skir_sqlalchemy-0.1.1.tar.gz
| Download URL | skir_sqlalchemy-0.1.1.tar.gz |
|---|---|
| Size | 4.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
67f1c81ea488e665c8b7a7bc01256de71679fd0c0b231485fe53403ec11c7290
|
|
BLAKE2b-256 checksum How to use checksums |
fe2153dd5d881f56a5e03046e41c3b0a22763b8c04e1bafdba640f9e57a0255d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.9.25
|
Release files / skir_sqlalchemy-0.1.1-py3-none-any.whl
| Download URL | skir_sqlalchemy-0.1.1-py3-none-any.whl |
|---|---|
| Size | 4.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e87c99854ac594bf69fa5fd1b024cb7eb801f0bcc6dfcf33b9a61bfe0c90293f
|
|
BLAKE2b-256 checksum How to use checksums |
8c65c4e9865d923ef8579ba26e9972cce0cd488226d0e1f2e17ebeec5522000c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.9.25
|