updated: 2025-06-09T16:33:33.417798218+00:00[Etc/UTC]
README
ry
A growing collection of Python shims around Rust crates — fast, async-first, and ergonomic.
DOCS: ryo3.dev (WIP)
API: ryo3.dev/api
⚠️ This is a work in progress — feedback and PRs are welcome.
Highlights
-
Async-first HTTP client Built on
reqwest
, with afetch
-like API. Supports streaming, zero-copy IO via the buffer protocol, timeouts, retries, and native JSON parsing viajiter
. -
Async file I/O Built on
tokio
, with anAsyncFile
API similar toaiofiles
andanyio
’s async-file api. Supports buffered reads/writes, truncation, streaming reads, andanyio
compatibility. -
(de)compression (de)compression tools for
zstd
,brotli
,gzip
, andbzip2
. -
Datetime utilities via
jiff
Fast, accurate, timezone-aware datetime parsing and formatting, withdatetime
interop and much more -
Miscellaneous bindings Includes crates like
globset
,walkdir
,sqlformat
,unindent
,xxhash
, and more. -
Designed for ergonomics Async where it matters. Simple where possible. Python-native behavior with minimal friction.
-
Type Annotated Type annotations for all public APIs, with
mypy
support.
Install
pip install ry
uv add ry
# check install
python -m ry
Quickstart
Check out the examples directory for some quickstart examples.
What?
ry
– the python packageryo3-*
– the rust crates that are used byry
and possibly your ownpyo3
-based python package
Who?
- jessekrubin [email protected]
- possibly you!?
FAQ
(aka: questions that I have been asking myself)
- Q: Why?
- A: I (jesse) needed several hashing functions for python and then kept adding things as I needed them
- Q: Does this have anything to do with the (excellent) package manager
rye
?- A: short answer: no. long answer: no, it does not.
- Q: Why is the repo split into
ry
andryo3
?- A:
ry
is the python package,ryo3
is a rust crate setup to let you “register” functions you may want if you were writing your own pyo3-python bindings library; maybe someday theryo3::libs
module will be split up into separate packages
- A:
Crate bindings
- wrapped crates:
std
- many stdlib types and apisbytes
dirs
glob
heck
http
jiter
reqwest
shlex
size
sqlformat
tokio
(fs
andprocess
)unindent
url
uuid
which
- compression:
brotli
bzip2
flate2
zstd
- hashing:
fnv
xxhash
- burnt-sushi:
globset
(formerly globsters)jiff
regex
(WIP ~ very incomplete)same-file
walkdir
DEV
just
is used to run tasks- Do not use the phrase
blazing fast
or any emojis in any PRs or issues or docs - type annotations are required
ruff
used for formatting and linting
SEE ALSO
- utiles (web-map tile utils): https://github.com/jessekrubin/utiles