# blocking.Runtime.new

- **Module:** blocking.Runtime
- **Package:** libtmux
- **Language:** Rust
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-rs/blob/8a648c0894dfffc9303583f753b6c8ae01f2fe76/crates/libtmux/src/blocking.rs#L57
- **Page:** https://libtmux.org/reference/rs/blocking-runtime-new/

```
blocking.Runtime.new() -> Result<Self, Error>
```

Build a single-threaded runtime.

Single-threaded is the right default here. The work is waiting on
subprocesses, so extra threads buy nothing and would make a script's
behavior depend on how many cores it happened to run on.

# Errors

Returns an error when the operating system refuses the resources a
runtime needs.
