urepo is a six-crate Cargo workspace with strict dependency layering enforced by tests in urepo-policies.
Workspace crates
| Crate |
Path |
Depends on |
Role |
urepo-sys |
crates/sys |
external OS/network/async crates |
Seam to the world (Sys, Real, deterministic sim::World, Overlay, atomic replace) |
urepo-core |
crates/core |
urepo-sys |
Every domain rule: config, graph, keys, store, scheduler, tools, stacks, releases, CI, checks, init |
urepo-ext |
crates/ext |
urepo-sys, urepo-core |
Built-in extensions (cargo, uv, js, docker, pulumi), the local extension runner, and the Docker Compose and GitHub drivers |
urepo-cli |
crates/cli |
urepo-sys, urepo-core, urepo-ext |
The urepo binary, clap parser, and text/JSON view rendering |
urepo-import |
crates/import |
urepo-sys, urepo-core, urepo-ext |
The urepo-import binary, which translates mise.toml files into urepo's configuration once |
urepo-policies |
crates/policies |
none of the above |
Crate layering, seam, and doc link checks |
Key invariants
- Only
urepo-sys reads a clock, opens a file, starts a process, opens a network socket, or draws randomness. Every other crate accepts &dyn Sys.
- Concurrent work inside
urepo-core polls futures together (futures::future::join_all / try_join_all) and never spawns tasks, so the deterministic simulator controls scheduling order.
- Every command in
urepo-core returns one Serialize view struct with pub v: u32 first and an Exits impl. Text output and --json both render that same value.
unsafe is forbidden workspace-wide (unsafe_code = "forbid"). Libraries return typed thiserror errors; only urepo-cli uses anyhow.
Enforced policies
| Policy file |
Test |
Enforces |
crates/policies/layers.toml |
layers |
Crate-to-crate dependency direction |
clippy.toml, tests/calls.rs, tests/implementations.rs |
calls, implementations, Clippy |
OS seam isolation and Sys/Child ownership |
crates/policies/tests/docs.rs, crates/cli/tests/suite/docs.rs |
docs |
Relative links, anchors, parseable TOML/JSON samples, and CLI help coverage |