Skip to content

Error details that created with errors.NewWithDetails are lost after it combined using errors.Combine #26

@dimasdanz

Description

@dimasdanz

Code to reproduce

errWithDetail := errors.NewWithDetails(
 "errorMessage",
  "key", "value",
)
errOther := errors.New("Something")

errors.GetDetails(errWithDetail) // [key, value] -> detail exists
errors.GetDetails(errors.Combine(errWithDetail, errOther) // [] -> prints empty slice

// also happened here
errors.Append(errWithDetail, errOther) // []

Is this expected?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions