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

Built distributions (wheels)

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

Total release size: 16.0 MB

Release files / transports-0.12.3.tar.gz

Download URL transports-0.12.3.tar.gz
Size 2.0 MB
Tags Source
SHA-256 checksum
How to use checksums
259b5493f48b2ef828512e6ecd7f272b9ad77ab3226e2f6b7cd9597e435b8bea
BLAKE2b-256 checksum
How to use checksums
7694598b848c132439aa5d5672380f910fc47d24e466b170c16595c6fe63c0e8
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.3-cp314-cp314-pyemscripten_2026_0_wasm32.whl

Download URL transports-0.12.3-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
4a8e3497d9e0d4115fc5e82374c9efff8f7ceb67bd2bcd5fa36d810c5b07a3db
BLAKE2b-256 checksum
How to use checksums
7cbb0037928f559e57b6a261dc53eedde178e58d74afcc2c7158b16d7bbe7483
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.3-cp311-abi3-win_amd64.whl

Download URL transports-0.12.3-cp311-abi3-win_amd64.whl
Size 2.8 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
0bda5bfad279c97f9d8a2c506015ed5d78d3305681283f83afd375dc35189e02
BLAKE2b-256 checksum
How to use checksums
d6e1f5664bdd4ca775ed3610e92d4a671cb9529702db8e3d65c1b0557d2e2187
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.3-cp311-abi3-manylinux_2_28_x86_64.whl

Download URL transports-0.12.3-cp311-abi3-manylinux_2_28_x86_64.whl
Size 3.0 MB
Tags CPython 3.11 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
332a6267268bbb9c48ec9f146fe72cddac13a2776df69fba8e8592dd01b7e08d
BLAKE2b-256 checksum
How to use checksums
599e03f7266586ca23e83494599e0f772b12c1039977df89fe450f06f300ca80
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.3-cp311-abi3-manylinux_2_28_aarch64.whl

Download URL transports-0.12.3-cp311-abi3-manylinux_2_28_aarch64.whl
Size 2.9 MB
Tags CPython 3.11 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
6b5048c38e71739d5cfb9343cee811765a1a969e7cda3f92894cd4c7da575952
BLAKE2b-256 checksum
How to use checksums
7b8ff965a30bd48ffc9cb0b00d8a16fcac48299206062e7b378d772ab865f77d
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.3-cp311-abi3-macosx_11_0_arm64.whl

Download URL transports-0.12.3-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
344b60b18d9b51a2681002b1396ffd695cb223991cbace27676d4fe81c3a46c3
BLAKE2b-256 checksum
How to use checksums
60ac38338da85ee8c967d451c883417b0600d1037df34db33c10d334d7c06310
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.3

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