Skip to main content
transports logo, concentric circles with a line connecting them with points

Build Status codecov License PyPI

transports moves typed models across any wire as incremental patches.

A model is defined once as a pydantic model, stdlib dataclass, or msgspec struct. A Python process hosts it and mutates it normally, and transports sends only the patch needed to update a remote mirror. The same Rust core drives Python (PyO3) and JavaScript (wasm), so both sides share the same Value type, diff, patch application, and codecs.

import transports
from pydantic import BaseModel

class Device(BaseModel):
    name: str
    on: bool = False

session = transports.Session()
lamp = Device(name="lamp")
model_id = session.host(lamp)

lamp.on = True
print(session.drain())
# [(1, {'rev': 1, 'ops': [{'Set': {'path': [{'Key': 'on'}], 'value': {'Bool': True}}}]})]

Install

pip install transports
pip install "transports[connections]"   # WebSocket server/client adapters
pip install "transports[sse]"           # Server-Sent Events adapter
pip install "transports[jupyter]"       # Jupyter comm adapter

Documentation

Tutorial

Quickstart builds one hosted model and mirrors it with the in-process server/client protocol.

How-to guides

Model bridges covers pydantic, dataclasses, msgspec, schemas, and plain JavaScript objects. Connections covers WebSocket, SSE, Jupyter comm, and anywidget adapters. Codecs covers JSON, MessagePack, and custom codecs. Multi-tenancy and sharing covers tenant isolation, shared models, and merge strategies. Pyodide covers building and loading transports in a browser.

Reference

API reference lists the Python API. Wire protocol reference describes Value, patch operations, protocol messages, codecs, and model ids. Benchmark results reports recorded server fan-out latency, completion time, and resource use.

Explanation

Concepts explains why transports uses incremental patches, server-owned revisions, a shared Rust core, and transport-agnostic adapters.

Metadata

Release files for transports 0.12.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 transports 0.12.0
File Size Uploaded Provenance Actions
transports-0.12.0.tar.gz 2.0 MB Without provenance Details for transports-0.12.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for transports 0.12.0
File Actions
transports-0.12.0-cp314-cp314-pyemscripten_2026_0_wasm32.whl CPython 3.14 CPython 3.14 PyEmscripten 2026.0+ WebAssembly Details for transports-0.12.0-cp314-cp314-pyemscripten_2026_0_wasm32.whl
transports-0.12.0-cp311-abi3-win_amd64.whl CPython 3.11 abi3 Windows x86-64 Details for transports-0.12.0-cp311-abi3-win_amd64.whl
transports-0.12.0-cp311-abi3-manylinux_2_28_x86_64.whl CPython 3.11 abi3 Linux glibc 2.28+ x86-64 Details for transports-0.12.0-cp311-abi3-manylinux_2_28_x86_64.whl
transports-0.12.0-cp311-abi3-manylinux_2_28_aarch64.whl CPython 3.11 abi3 Linux glibc 2.28+ ARM64 Details for transports-0.12.0-cp311-abi3-manylinux_2_28_aarch64.whl
transports-0.12.0-cp311-abi3-macosx_11_0_arm64.whl CPython 3.11 abi3 macOS 11.0+ ARM64 Details for transports-0.12.0-cp311-abi3-macosx_11_0_arm64.whl

Total release size: 15.7 MB

Release files / transports-0.12.0.tar.gz

Download URL transports-0.12.0.tar.gz
Size 2.0 MB
Tags Source
SHA-256 checksum
How to use checksums
91263f8f501ff620cc81dd4bf18b5dd6da4c9e708fea568bd5a340e1f5f9b983
BLAKE2b-256 checksum
How to use checksums
6372e207ecf013b4319b94677f1a1d0f2f008a0fd6b6be4269c7fb322af2a723
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Release files / transports-0.12.0-cp314-cp314-pyemscripten_2026_0_wasm32.whl

Download URL transports-0.12.0-cp314-cp314-pyemscripten_2026_0_wasm32.whl
Size 2.4 MB
Tags CPython 3.14 PyEmscripten 2026.0+ WebAssembly
SHA-256 checksum
How to use checksums
d7e8ecdd0e9ae3464020520377b023e1af2fdb72ea9e7f044601fcc2f3e2b011
BLAKE2b-256 checksum
How to use checksums
8b09f7709dcfbd2be2389b4d43714e795b7501bfa604657ea98eafaac3d78894
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Release files / transports-0.12.0-cp311-abi3-win_amd64.whl

Download URL transports-0.12.0-cp311-abi3-win_amd64.whl
Size 2.8 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
330a1bc1ef09502665e8a3e1f6e24a4874ce95818e96f0e0feb4401e85e3bfc0
BLAKE2b-256 checksum
How to use checksums
6b5144ddb9a96f29435631387e608c55ca908c5c1c604f8ca1fa64818a1e8ee8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Release files / transports-0.12.0-cp311-abi3-manylinux_2_28_x86_64.whl

Download URL transports-0.12.0-cp311-abi3-manylinux_2_28_x86_64.whl
Size 2.9 MB
Tags CPython 3.11 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
db3ff0a7368e12073e0532ec6d5f3c78cb3faedf4f78dddd68ba27c0c65ddb8c
BLAKE2b-256 checksum
How to use checksums
7f17fc1baa5093d501f3ccca0e771a895e2a9ec6063a8c605c7fc39cf5e80acd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Release files / transports-0.12.0-cp311-abi3-manylinux_2_28_aarch64.whl

Download URL transports-0.12.0-cp311-abi3-manylinux_2_28_aarch64.whl
Size 2.8 MB
Tags CPython 3.11 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
0111e073e7262c9a88d8c27e7490e756cddf38b6fb380b0fae23a77b7e597d06
BLAKE2b-256 checksum
How to use checksums
3eb4893c87db6de22bd4dae796281a5f8bfd8517be74cf67639439f34d02fa5f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Release files / transports-0.12.0-cp311-abi3-macosx_11_0_arm64.whl

Download URL transports-0.12.0-cp311-abi3-macosx_11_0_arm64.whl
Size 2.8 MB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
29bfcd9c5699d57e31c3e9bffe53265f34b6cff3c9d67dc6dc92e4fcc48518b9
BLAKE2b-256 checksum
How to use checksums
ae78b9d6417fc01540c8c47fed5aaa74aa743bde2018c5e4f4cd6c1ffe3e86de
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.15

Security for transports 0.12.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.

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