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.4

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

Built distributions (wheels)

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

Total release size: 16.5 MB

Release files / transports-0.12.4.tar.gz

Download URL transports-0.12.4.tar.gz
Size 2.1 MB
Tags Source
SHA-256 checksum
How to use checksums
e3b5821a01669959307a07375856389ef48f59885ca487afeecb18688f86cf67
BLAKE2b-256 checksum
How to use checksums
d3769a33298ccf6874ff8cce90dfad500c53e786370e7b6f279194d3c803d474
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

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

Download URL transports-0.12.4-cp314-cp314-pyemscripten_2026_0_wasm32.whl
Size 2.5 MB
Tags CPython 3.14 PyEmscripten 2026.0+ WebAssembly
SHA-256 checksum
How to use checksums
41fc015d8718b8fc6c87553d6d957d628c50888ad1ce96562b52b580ded2a666
BLAKE2b-256 checksum
How to use checksums
987ce11815ff3c14d535e49ad48013e2dcf6ec53027c5e6cb28c702e49ab63ae
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

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

Download URL transports-0.12.4-cp311-abi3-win_amd64.whl
Size 2.9 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
4e0646698812bd94128ca1d1831955aef9fc22ae7eb388b1c87f9931b246a6d5
BLAKE2b-256 checksum
How to use checksums
f77f6d0a90fbe418bd97f656dbcd348e98ffa08e46b6160cdbefa61c34d5a776
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

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

Download URL transports-0.12.4-cp311-abi3-manylinux_2_28_x86_64.whl
Size 3.1 MB
Tags CPython 3.11 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
82fdfc928a9532b3684de99b5c3ace6f32b8a655edcb89022b7ba6a73105327e
BLAKE2b-256 checksum
How to use checksums
ab32495b263720d749dad42410206723ce086593422d03366d50a4083226bf8f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

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

Download URL transports-0.12.4-cp311-abi3-manylinux_2_28_aarch64.whl
Size 3.0 MB
Tags CPython 3.11 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
5397937ba45be632590334a1b85c8a069b7e953e85eadeea5798c02d9e4cc4cd
BLAKE2b-256 checksum
How to use checksums
61c292a01a505fc30ced3bf2fb19c44b0c18053e2e3fd45a4d7ecd4733df676a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

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

Download URL transports-0.12.4-cp311-abi3-macosx_11_0_arm64.whl
Size 2.9 MB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
35d9c9d59122add2e1f622fd1c383c5dab92f440a7c8e3cc792320fecfe1e052
BLAKE2b-256 checksum
How to use checksums
20e9b0c0f00beb71c0255fffa0dfd222ab6e7b469c1d4e4e2d5285d240277058
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Security for transports 0.12.4

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