runez
Friendly misc/utils/convenience library
What it is and what it does
runez is a lightweight utility library that wraps common system operations—running subprocesses, reading and writing files, managing directories—with a consistent interface for error handling and logging. It eliminates boilerplate by providing sensible defaults: operations abort on failure by default with clear error messages, but can be set to return False instead via fatal=False. The library includes a dryrun mode to preview operations without executing them, and a CaptureOutput context manager to intercept output from any code section.
The package is pure Python with no external dependencies, making it trivial to add to any project. It supports current Python versions (3.10 through 3.14) and has been actively maintained since 2018. Most operations follow a consistent signature pattern, so once you learn the conventions for fatal, logger, and dryrun parameters, you can predict how any function will behave.
Use it for:
- Build scripts and CLI tools that need to run external commands and fail fast with readable errors.
- Test suites that need to capture and verify logging output or subprocess output from tested code.
- Automation scripts that benefit from dryrun mode to preview file operations before committing them.
- Utilities that perform file I/O (read, write, copy, delete) with consistent error handling across operations.
- Logging setup in small projects where a full logging framework feels like overkill.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
A zero-dependency utility library providing common file operations, subprocess execution, logging setup, and output capture with consistent error handling and dryrun support.
Yes. runez is a low-risk, actively maintained utility with zero dependencies, permissive licensing, and a clear design philosophy. Install it if you write scripts or tools that repeatedly wrap subprocess calls, file operations, or logging setup—it will reduce boilerplate and standardize error handling. Not necessary for projects that already use a heavier framework or that have minimal I/O needs.
Install
runez on PyPI
pip
pip install runezuv
uv add runezpoetry
poetry add runezInstalling runez
Before you install
Low friction: pure Python, no runtime dependencies, distributed as a wheel. Actively maintained with recent commits; last release 101 days ago.
License in practice
MIT license permits unrestricted use, modification, and distribution in proprietary and open-source projects alike.
Quickstart
pip install runez
import runez
output = runez.run("ls", "foo")
runez.copy("foo", "bar")
runez.write("foo", "content\n")
Requires Python 3.10 or later.
Verify before relying
- Whether the library's error messages and logging output meet your project's standards for verbosity and format.
- Performance characteristics when handling very large files or many concurrent operations.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 101 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 1,556,370/month — #3,768 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: runez-5.9.1-py3-none-any.whl
Tags
More Libraries packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
pluggyPluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
python-dateutilProvides parsing, arithmetic, and recurrence…
permissive · top 100 on PyPI
sixSix provides utility functions to write Python…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
subprocrunnerWraps Python's subprocess module to simplify…
permissive · top 15,000 on PyPI
EasyProcessEasyProcess wraps Python's subprocess module to…
permissive · top 5,000 on PyPI
scripttestscripttest runs command-line applications in…
permissive · top 15,000 on PyPI
cw-rpaProvides utility modules for building Robotic…
unclear · top 5,000 on PyPI
bashProvides a Python wrapper for running bash…
copyleft · top 15,000 on PyPI
subprocess-teeA drop-in replacement for subprocess.run that…
permissive · top 5,000 on PyPI
logfuryLogfury adds automatic method-call tracing to…
permissive · top 15,000 on PyPI
subprocess.runProvides a simplified interface to run shell…
permissive · top 15,000 on PyPI
logzio-python-handlerA Python logging handler that sends logs in…
permissive · top 5,000 on PyPI
logistrologistro wraps Python's standard logging module…
permissive · top 5,000 on PyPI