Skip to main content

verirun

Deterministic task runner and content-addressed build store with cryptographic Merkle manifests.

You describe a batch of shell tasks once as JSON data. verirun validates the graph before executing a single command, runs each task inside a cleaned sandbox, stores every input, output, and output stream by its SHA-256 content digest, and seals the run with a canonical RFC 8785 manifest and Merkle root.

Tutorial · Docs · Architecture · Invariants · Releases

CI on main crates.io version PyPI version docs.rs MSRV 1.88 MIT or Apache-2.0 license

A two-part view with live task graph and content-addressed store telemetry above and real verirun CLI calls below, showing a cold run with pinning, a four-worker warm cached run, a manifest diff, and a one-byte disk corruption caught by verirun verify with exit code 2

Every terminal line above comes from real invocations of the verirun release binary against a live content-addressed store.

Why verirun

Build scripts and pipeline steps usually leave behind mutable folders, ambient environment leaks, and unverified caches. When an artifact changes weeks later, nothing proves whether an input drifted, a cache entry rotted on disk, or worker scheduling changed the order of writes. verirun turns every batch run into an immutable, re-verifiable cryptographic record.

  • Upfront graph validation. Missing dependencies, cycles, duplicate task IDs, colliding output paths, reserved environment keys (PATH, HOME, TMPDIR), and unsafe relative paths are rejected with exit code 3 before any subprocess spawns.
  • Hermetic task sandboxes. Each task executes in a fresh working folder with a scrubbed environment holding only its declared variables plus fixed deterministic defaults. Worker count (--jobs) and host folder paths never enter any digest.
  • Process-tree containment. Tasks exceeding timeout_ms are terminated along with every child in their Unix process group or Windows Job Object, and surviving background group members are cleaned up when the task finishes.
  • Race-free, crash-safe content store. Outputs are collected component by component relative to open directory handles so symlinks and reparse points are refused without TOCTOU races. Blobs land via temporary write, fsync, atomic rename, and directory sync, and remain read-only on disk in bounded 64 KiB streaming chunks.
  • Verified by-exec caching. When a task's executable, arguments, environment, and input digests match a prior success, verirun verifies every referenced blob and recorded byte length before reusing the cached record without spawning the program.
  • End-to-end tamper conviction. verirun verify re-parses the canonical manifest, checks the Merkle root, and streams every referenced artifact and log through SHA-256, exiting with code 2 on the first corrupted byte or mismatched size.

Four domain-separated SHA-256 stages from verirun/blob/v1 through verirun/manifest/v1 showing how a 1-byte disk flip in loud.txt causes verirun verify to exit with code 2

How it works

JSON run specs, host input bindings, worker limits, and pins enter the verirun pipeline across upfront DAG validation, hermetic sandboxes, process-tree cleanup, handle-relative collection, crash-safe sharded CAS, and verified caching, producing Merkle manifests and verify, show, diff, and gc workflows

Crate Kind External runtime deps Role
verirun-core library none (std only) Strict JSON parser, RFC 8785 canonical encoder, domain-framed digests, DAG validator, and manifest builder and differ.
verirun-platform library libc (Unix), windows-sys (Win) Sole OS FFI seam for process groups and Job Objects, no-follow handle-relative path traversal, and rename_replace atomic replacement.
verirun-store library sha2 Crash-safe sharded content-addressed store, hermetic subprocess runner, parallel scheduler, by-exec cache, and garbage collector.
verirun-cli library and binary (verirun) clap, serde_json Command line interface (run, verify, show, diff, pin, unpin, gc) with total --json parity and documented exit codes.

Quickstart

Install the verirun binary from PyPI, from crates.io, with cargo-binstall, or from the prebuilt Linux, macOS, and Windows archives on GitHub Releases.

pip install verirun
# or run directly without installing
uvx verirun --version
# or install from crates.io
cargo install verirun-cli
import verirun

result = verirun.run("pipeline.json", cas="./cas", work="./work", pin_manifest=True, check=True)
verirun.verify(result.manifest, cas="./cas")

Save a two-task run description as pipeline.json. Inside its sandbox, each task reads declared inputs under inputs/ and writes declared outputs under outputs/.

{
  "tasks": [
    {
      "task_id": "greet",
      "executable": "sh",
      "args": ["-c", "printf 'hello from verirun\n' > outputs/greeting.txt"],
      "env": {},
      "inputs": [],
      "outputs": ["greeting.txt"],
      "depends_on": []
    },
    {
      "task_id": "shout",
      "executable": "sh",
      "args": ["-c", "tr a-z A-Z < inputs/greeting.txt > outputs/loud.txt"],
      "env": {},
      "inputs": ["greeting.txt"],
      "outputs": ["loud.txt"],
      "depends_on": ["greet"]
    }
  ]
}

Run the graph, pin its manifest against garbage collection, inspect its records, and re-verify every stored object on disk.

verirun run --cas ./cas --work ./work --pin pipeline.json
verirun show --cas ./cas c1cd0a900765094f08534d5edb4676a24770c225ca53848de7173a44b2e0815c
verirun verify --cas ./cas c1cd0a900765094f08534d5edb4676a24770c225ca53848de7173a44b2e0815c
seed: 0
verified c1cd0a900765094f08534d5edb4676a24770c225ca53848de7173a44b2e0815c

Command summary and exit codes

Subcommand Purpose Exit codes
verirun run Validate a spec, execute or reuse cached tasks, and emit the manifest digest (--input, --jobs, --pin, --json). 0 all succeeded or cached, 1 task failed or timed out, 3 invalid spec or store setup
verirun verify Re-parse a manifest, check its Merkle root, and re-hash every referenced blob and byte length. 0 intact, 2 missing or corrupted data
verirun show Verify a manifest first, then print its Merkle root, task statuses, execution digests, and artifact digests. 0 shown, 2 verification failed
verirun diff Verify two manifests first, then list tasks whose status, exit code, execution digest, streams, or artifacts differ. 0 identical, 1 differences found, 2 verification failed
verirun pin / unpin Verify and pin a manifest against garbage collection, or remove an existing pin. 0 updated, 2 verification failed (pin)
verirun gc Sweep unreachable objects and debris older than --grace-secs while preserving pinned manifests and live blobs. 0 completed, 2 corrupt pinned manifest

Benchmarks and verification

Run the full local gate (matching hosted Linux, macOS, Windows, and MSRV 1.88 continuous integration).

cargo fmt --all -- --check
cargo clippy --workspace --all-targets --all-features --locked -- -D warnings
PROPTEST_CASES=1000 cargo test --workspace --all-features --locked --no-fail-fast
RUSTDOCFLAGS="-D warnings" cargo doc --workspace --no-deps --locked
cargo bench --workspace --locked -- --test

Measured on 2026-11-24 on a hosted Linux runner from full runs of canonical_bench, cas_bench, and verify_bench.

Benchmark Workload Elapsed Throughput
canonical_bench RFC 8785 canonical encoding of a 193,835-byte document with 256 task-shaped entries (200 iterations) 0.112 s 331.4 MiB/s
cas_bench (4 MiB put) Hashing and storing 20 distinct 4 MiB blobs through the crash-safe put protocol 0.573 s 139.6 MiB/s
cas_bench (64 KiB put) Storing 500 distinct 64 KiB blobs including file sync, atomic rename, and directory sync 0.593 s 843.2 puts/s
verify_bench Streaming SHA-256 verified reads of a 4 MiB stored blob (50 iterations) 0.138 s 1446.1 MiB/s

Documentation

If you want to... Read
Walk a complete first run from JSON spec to diff and GC Step-by-step tutorial
Browse every document in the repository Documentation index
Understand the store layout, RFC 8785 rules, and OS sandboxing Architecture · Decisions
Check every formal invariant and its enforcing property or fault test Invariants and traceability matrix
Inspect crate-level APIs and examples verirun-core · verirun-platform · verirun-store · verirun-cli
Review the 50-round audit and 14-round perfection programmes Audit register · Perfection register · Security policy · Changelog

Contributing

CONTRIBUTING.md explains the two-stage milestone workflow, fault-oracle standards, forever format stability, and local verification gates.

Licence

verirun is dual licensed under the MIT licence and the Apache License 2.0. You may use it under either one.

Metadata

Release files for verirun 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for verirun 0.2.0
File Size Uploaded Provenance Actions
verirun-0.2.0.tar.gz 187.2 kB With provenance Details for verirun-0.2.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for verirun 0.2.0
File Actions
verirun-0.2.0-py3-none-win_amd64.whl Python 3 none Windows x86-64 Details for verirun-0.2.0-py3-none-win_amd64.whl
verirun-0.2.0-py3-none-manylinux_2_28_x86_64.whl Python 3 none Linux glibc 2.28+ x86-64 Details for verirun-0.2.0-py3-none-manylinux_2_28_x86_64.whl
verirun-0.2.0-py3-none-manylinux_2_28_aarch64.whl Python 3 none Linux glibc 2.28+ ARM64 Details for verirun-0.2.0-py3-none-manylinux_2_28_aarch64.whl
verirun-0.2.0-py3-none-macosx_11_0_arm64.whl Python 3 none macOS 11.0+ ARM64 Details for verirun-0.2.0-py3-none-macosx_11_0_arm64.whl
verirun-0.2.0-py3-none-macosx_10_12_x86_64.whl Python 3 none macOS 10.12+ x86-64 Details for verirun-0.2.0-py3-none-macosx_10_12_x86_64.whl

Total release size: 4.1 MB

Release files / verirun-0.2.0.tar.gz

Download URL verirun-0.2.0.tar.gz
Size 187.2 kB
Tags Source
SHA-256 checksum
How to use checksums
a3823d4db48477dcd57a35ef0f3d57ca43abbe7e20b6a8d1aa06851ebb5bac3c
BLAKE2b-256 checksum
How to use checksums
5a42349c3a2e0e7d35c331363464cc05f399b8d3df74861c5f8ad788ae99ad11
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

Release files / verirun-0.2.0-py3-none-win_amd64.whl

Download URL verirun-0.2.0-py3-none-win_amd64.whl
Size 757.0 kB
Tags Python 3 Windows x86-64
SHA-256 checksum
How to use checksums
64b483e7c6b9863f66824107e00fa0e0aa1bc29c6d12d0c54db65fff0016b778
BLAKE2b-256 checksum
How to use checksums
25bd30afff2a723e4c88243e971a94e818937fb7aa2cad6435435dd7079e2d15
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

Release files / verirun-0.2.0-py3-none-manylinux_2_28_x86_64.whl

Download URL verirun-0.2.0-py3-none-manylinux_2_28_x86_64.whl
Size 834.5 kB
Tags Linux glibc 2.28+ x86-64 Python 3
SHA-256 checksum
How to use checksums
a065037033188f6a3278864b5a203359439ef3e1fb5b14d8ab896fd5d748f24f
BLAKE2b-256 checksum
How to use checksums
386ba2a4797bd377f990467c7d84b3c7380639018512bf02b41101706b976589
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

Release files / verirun-0.2.0-py3-none-manylinux_2_28_aarch64.whl

Download URL verirun-0.2.0-py3-none-manylinux_2_28_aarch64.whl
Size 775.7 kB
Tags Linux glibc 2.28+ ARM64 Python 3
SHA-256 checksum
How to use checksums
b469313cd849ae696df27a654f5b335cd99b03afb23f0b99cbaec1c9d4bf6141
BLAKE2b-256 checksum
How to use checksums
b750e394be8c2f53c7162587d37370766bfe9c081a22a3a29600c42e1566519b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

Release files / verirun-0.2.0-py3-none-macosx_11_0_arm64.whl

Download URL verirun-0.2.0-py3-none-macosx_11_0_arm64.whl
Size 753.1 kB
Tags Python 3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
1115b3e7e01fd4139d1be4152122c85f4e5d03b05895caae2b6caff628e746ae
BLAKE2b-256 checksum
How to use checksums
d2ecd202c115962c71e6d978f94abebfe9644de9d1be6531ec156268f0c10300
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

Release files / verirun-0.2.0-py3-none-macosx_10_12_x86_64.whl

Download URL verirun-0.2.0-py3-none-macosx_10_12_x86_64.whl
Size 797.3 kB
Tags Python 3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
5d0a2e58988e6842ec993a700fd81930f2da088473a05a266646b40270612bd4
BLAKE2b-256 checksum
How to use checksums
8034e771856ea9b9c4b87d88c0f7984437339666bda95823b051b754b1552a22
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

Security for verirun 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 6 files in this release have been uploaded with provenance metadata.

Select from 6 files

Attestation for verirun-0.2.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.0 This release

6 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page