rpytest vs pytest: faster pytest runs without changing your tests
rpytest is a Rust-daemon-backed drop-in for pytest. The daemon keeps the Python interpreter warm between runs so you stop paying startup cost on every invocation.
$ pip install rpytest rpytest is a Rust-backed drop-in for
pytest. Same API, faster hot paths.
Install: pip install rpytest.
Faster warm runs (warm interpreter + pre-loaded conftest).
rpytest vs pytest: the facts
Faster warm runs (warm interpreter + pre-loaded conftest).
Cold interpreter + import overhead on every run.
Same pytest API — fixtures, markers, plugins, parametrize.
Native pytest.
Same test discovery and config.
Native.
Zero code changes: `pip install rpytest` and prefix `rpytest` instead of `pytest`.
Native pytest.
MIT licensed, prebuilt wheels, Python 3.9+.
MIT licensed.
When to use rpytest
- You have a pytest suite of 100+ tests and CI is the bottleneck.
- You want a 2-10× win with zero code changes.
When NOT to use rpytest
- You have <50 tests and CI is fast enough.
Frequently asked questions
Will rpytest run my existing pytest tests unmodified?
Yes. rpytest uses pytest under the hood; the daemon only manages interpreter warm-up. All fixtures, markers, plugins, and parametrize work as normal.
Is rpytest a fork of pytest?
No — it is a wrapper that invokes pytest inside a warm Python interpreter. You keep upstream pytest compatibility.