Skip to content

Rethrown errors should retain stack from the original error #815

@luxaritas

Description

@luxaritas

Describe your idea

Currently, if an error is caught and a new error (eg, with a better description) is rethrown, it will include the traceback at the point the new error is thrown. We may want to have information about the original error, namely its stack trace.

Motivation

Easier debugging

Proposed Solution

We should probably make use of Error.cause, setting it when "rethrowing" errors and using it when logging/showing error details eg in the error dialog

Other Information

Covering related concerns: #797 #796 #794

Metadata

Metadata

Assignees

No one assigned

    Labels

    priority: p4/minorThere is a reasonable workaround, or there is a nice to have with limited impactsize: mdtype: enhancementNew feature or request

    Type

    No type

    Projects

    Status

    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions