Installation¶
Basic Install¶
With Performance Backends¶
For production workloads, install the optional fast extras:
This adds:
| Backend | Language | Benefit |
|---|---|---|
| uvloop | C | 2-4x faster async event loop (Linux/macOS) |
| orjson | Rust | ~10x faster JSON for structured logging |
These are optional — pyresilience works perfectly with stdlib. The library auto-detects available backends at runtime.
from pyresilience import has_uvloop, has_orjson, install_uvloop
print(has_uvloop()) # True if uvloop is available
print(has_orjson()) # True if orjson is available
install_uvloop() # Installs uvloop as the default event loop policy
From Source¶
Requirements¶
- Python 3.9+ (tested on 3.9, 3.10, 3.11, 3.12, 3.13, 3.14)
- No runtime dependencies — pure Python stdlib
- Runs on Linux, macOS, and Windows