rpytest
Run your pytest suite faster. Change nothing.
A Rust-powered, drop-in replacement for pytest that eliminates startup overhead while keeping your tests, fixtures, and plugins untouched.
Why rpytest?
pytest -> 2.91s (480 tests)
rpytest -> 1.55s (same 480 tests)
= 1.9x faster
rpytest uses a persistent Rust daemon to keep Python warm between runs. No more interpreter startup costs on every invocation.
Installation
pip install rpytest
That's it. The correct native binary for your platform (macOS or Linux, Intel or Apple Silicon) is bundled automatically.
Usage
rpytest mirrors pytest's CLI exactly. If you know pytest, you know rpytest.
# Run all tests
rpytest
# Run specific tests
rpytest tests/test_api.py::test_login
# Filter by keyword or marker
rpytest -k "auth" -m "not slow"
# Parallel execution — no pytest-xdist needed
rpytest -n auto
# Watch mode for TDD
rpytest --watch
Key Features
| Feature | pytest | rpytest |
|---|---|---|
| Startup time | ~200ms | <10ms |
| Memory usage | 35.8 MB | 6.2 MB |
| Parallel workers | pytest-xdist plugin | Built-in -n flag |
| Watch mode | pytest-watch plugin | Built-in --watch |
| Flakiness detection | flaky plugin | Built-in --reruns |
| Sharding | pytest-shard plugin | Built-in --shard |
- Full pytest compatibility — plugins, fixtures, conftest.py, pytest.ini all work unchanged
- Built-in parallelism —
rpytest -n 4orrpytest -n auto - Watch mode — file changes trigger automatic re-runs of affected tests
- Flakiness detection —
rpytest --reruns 3auto-retries failed tests - Session fixture reuse —
rpytest --reuse-fixturespersists expensive fixtures - CI sharding —
rpytest --shard 0 --total-shards 4
Requirements
- Python 3.9+
- pytest 7.0+
- macOS or Linux
How It Works
- First run: Spawns a background daemon that collects your test suite
- Subsequent runs: Rust CLI filters tests and dispatches to warm Python workers
- Results stream back in real-time
The daemon persists between runs, so TDD loops and CI retries skip all startup work.
Documentation
Full docs at docs.neullabs.com/rpytest
License
MIT
Metadata
Release files for rpytest 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| rpytest-0.1.2.tar.gz | 5.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| rpytest-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 12.4 kB
Release files / rpytest-0.1.2.tar.gz
| Download URL | rpytest-0.1.2.tar.gz |
|---|---|
| Size | 5.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
744de856d66b5e482c697ec44bb1b3a0a7394d2fe81d10ff4cbae8d0a3779d69
|
|
BLAKE2b-256 checksum How to use checksums |
2233912d609cd58be9bd7a336b01f0c0f06a10e07d2ccbc1c04c14a69efd89f1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.11 {"installer":{"name":"uv","version":"0.11.11","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / rpytest-0.1.2-py3-none-any.whl
| Download URL | rpytest-0.1.2-py3-none-any.whl |
|---|---|
| Size | 6.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
87ce986c541709706e86564755b36a65f392949362b5c3c6799f84216ad3356c
|
|
BLAKE2b-256 checksum How to use checksums |
1339a9a6286fb0a104099203778a23505644c63bf1fba0741976c6c80fc84b36
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.11 {"installer":{"name":"uv","version":"0.11.11","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|