Registry / utility / stable-eyre

stable-eyre

JSON →
library0.2.2rscratesunverified

Custom context for the eyre error-handling library that captures backtraces on stable Rust.

# Cargo.toml [dependencies] stable-eyre = "0.2.2"
INSTALL
IMPORT
SIG · STABLE-EYRE
S
stable-eyre
utilityrustv0.2.2
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Report
use stable_eyre::eyre::Report;

Creates an error report with a captured backtrace.

use stable_eyre::eyre::Report; use std::backtrace::Backtrace; fn main() -> Result<(), Report> { let backtrace = Backtrace::capture(); Err(Report::msg("error").context(backtrace)) }
Debug
Known issues
gotchaRequires the `backtrace` feature on stable Rust; otherwise backtraces are empty.
fix
Enable the `backtrace` feature in Cargo.toml: stable-eyre = { features = ["backtrace"] }
affects: >=0.2.0
Upgrade
Version history
0.2.2latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
stable-eyre — cargo add stable-eyre · libregistry