Common utilities for error handling within Backstage with structured error classes and serialization functions
63
Pending
Does it follow best practices?
Impact
63%
1.28xAverage score across 10 eval scenarios
Pending
The risk profile of this skill
{
"context": "Evaluates whether upstream failures are wrapped with @backstage/errors primitives that preserve the original error name while adding local context. Scoring focuses on correct use of ForwardedError to attach the cause, rely on its message enrichment, and handle non-error inputs with the built-in fallback behavior.",
"type": "weighted_checklist",
"checklist": [
{
"name": "Uses ForwardedError",
"description": "Creates the wrapper via `ForwardedError` from `@backstage/errors` (not a custom class) when surfacing upstream failures.",
"max_score": 40
},
{
"name": "Cause attached",
"description": "Passes the original error as the `cause` argument to `ForwardedError` so the resulting `cause` property retains the exact instance.",
"max_score": 25
},
{
"name": "Context message",
"description": "Supplies the local step/context as the `ForwardedError` message and relies on its `CustomErrorBase` formatting to include the cause text (no manual name overrides).",
"max_score": 20
},
{
"name": "Fallback name",
"description": "Handles non-Error inputs by letting `ForwardedError` (optionally combined with `isError`) default the `name` to \"Error\" rather than inventing a custom label.",
"max_score": 15
}
]
}evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10