CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/npm-aggregate-error

Create an error from multiple errors

94

1.28x
Overview
Eval results
Files

rubric.jsonevals/scenario-3/

{
  "context": "This criteria evaluates how effectively the engineer uses the aggregate-error package to consolidate multiple validation errors with properly formatted and indented output. The focus is on correct usage of the AggregateError constructor and understanding of its message formatting capabilities.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "AggregateError Import",
      "description": "Correctly imports AggregateError from the 'aggregate-error' package using require() or import statement",
      "max_score": 10
    },
    {
      "name": "Error Collection",
      "description": "Collects validation errors into an array before creating the AggregateError, rather than throwing individual errors",
      "max_score": 20
    },
    {
      "name": "AggregateError Construction",
      "description": "Instantiates AggregateError using the 'new' keyword and passes the array of errors to the constructor",
      "max_score": 25
    },
    {
      "name": "Error Input Types",
      "description": "Passes validation errors in appropriate formats (Error instances, objects with message property, or strings) to the AggregateError constructor",
      "max_score": 20
    },
    {
      "name": "Formatted Output",
      "description": "Leverages AggregateError's automatic message formatting and indentation rather than manually formatting error messages",
      "max_score": 25
    }
  ]
}

Install with Tessl CLI

npx tessl i tessl/npm-aggregate-error

tile.json