Run conflicting Python dependencies in one process — with vendored isolation.
Reyk lets you vendor Python dependencies into your project and isolate them by design, without changing how you write imports. We leverage Python's import system internals to achieve transparent dependency isolation.
- Zero Configuration: Enable isolation with a single function call
- Dependency Isolation: Avoid conflicts by shipping libraries with your package
- Version Flexibility: Run multiple versions of the same library in one process
- Transparent Imports: Keep your public imports unchanged (
import requestsstill works) - Lightweight: Minimal overhead with a tiny import hook
You can install Reyk from PyPI:
uv add reykEnable isolation from your package's __init__.py:
from reyk.isolator import isolate_package
isolate_package()Then, vendor your dependencies with Reyk's CLI:
uvx reyk-cli add requests==2.25.1That's it! Inside your_package, import requests resolves to your_package.libs.requests. Outside your_package, import requests continues to resolve to the global installation.
For detailed documentation, examples, and API reference, visit the documentation site at https://reyk.dev.
- Multi-threaded applications are not supported.