Skip to content

CLI worktree handlers discard error source chain #80

@wollax

Description

@wollax

Problem

anyhow::anyhow!("{e}") discards the error source chain by formatting to string. This loses the full cause chain that anyhow's debug formatting ({e:#}) would display. Pattern appears at multiple call sites in the worktree CLI handlers.

Solution

Solution

Use .map_err(|e| anyhow::Error::from(e)) or implement From<AssayError> for anyhow::Error to preserve the full chain.


Created via Kata PR review backlog

Metadata

Metadata

Assignees

No one assigned

    Labels

    backlogKata backlog issues

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions