Colorful errors
Author: Sk7Str1p3Created Apr 9, 2026Updated May 27, 2026
Labelsenhancement
Summary
Implement colored error and panic reports
Motivation
As a follow-up to #1634, which added colour to the CLI interface, we should implement something similar for errors and panics. I think this would make them easier to read and more user-friendly.
I came up with 3 options of implementing this:
1). Simply replace anyhow with color-eyre
- pros:
- easy to drop-in replace
anyhow
- easy to drop-in replace
- cons:
- bring some odd dependencies (e.g.
tracing,backtrace) - not that flexible, can be confusing if
.context()called many times
- bring some odd dependencies (e.g.
- Add
eyreand implement custom error report
- pros:
- easy to drop-in replace
anyhow - customisable
- easy to drop-in replace
- cons:
- reports are not so detailed, requires many extension traits to get detailed report
- can be confusing if error has many sources
- Use
miette
- pros:
- really comprehensive and beatiful error reports
- derive macros for error types
- cons:
- probably overkill
- 2MB built with
--release, really big crate
Source: o2sh/onefetch