Skip to content

refactor: replace error strings in reporter with ExecutionError enum#159

Merged
branchseer merged 1 commit intomainfrom
refactor/reporter-error-enums
Feb 15, 2026
Merged

refactor: replace error strings in reporter with ExecutionError enum#159
branchseer merged 1 commit intomainfrom
refactor/reporter-error-enums

Conversation

@branchseer
Copy link
Copy Markdown
Member

Summary

  • Add typed ExecutionError enum (with thiserror) to replace the four hardcoded error format strings passed through LeafExecutionReporter::finish()
  • Combine cache lookup and cache update failures into a single Cache { kind, source } variant with a CacheErrorKind sub-enum
  • Reporter converts the error chain to a display string at the boundary using anyhow's {:#} formatter, preserving existing output format

Replace the four hardcoded error format strings passed through
LeafExecutionReporter::finish() with a typed ExecutionError enum
using thiserror. The enum has three variants:

- Cache { kind, source } — covers both lookup and update failures
- Spawn — process spawn failure
- PostRunFingerprint — fingerprint creation failure

The reporter converts the error chain to a display string at the
boundary using anyhow's {:#} formatter, preserving the existing
output format.
@branchseer branchseer merged commit a6c49eb into main Feb 15, 2026
6 checks passed
@branchseer branchseer deleted the refactor/reporter-error-enums branch February 15, 2026 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant