or run

npx @tessl/cli init
Log in

Version

Files

docs

index.md
tile.json

rubric.jsonevals/scenario-3/

{
  "context": "This criteria evaluates how well the engineer uses the promise.allsettled package to handle advanced error scenarios, specifically focusing on robustness when dealing with modified promise behavior (poisoned .then() methods) and various error types in asynchronous operations.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "Uses promise.allsettled",
      "description": "The implementation imports and uses the promise.allsettled package (or requires it) as the primary mechanism for processing promises.",
      "max_score": 25
    },
    {
      "name": "Handles poisoned .then()",
      "description": "The solution correctly processes promises where the .then() method throws an error when accessed, demonstrating that promise.allsettled's advanced error handling is being leveraged (not implementing custom error handling for this).",
      "max_score": 25
    },
    {
      "name": "Captures all error types",
      "description": "The implementation correctly captures and preserves rejection reasons of different types (Error objects, strings, numbers) in the result's reason field without additional normalization or transformation.",
      "max_score": 20
    },
    {
      "name": "Returns correct format",
      "description": "Results match the promise.allsettled specification format: objects with status='fulfilled' and value field for successes, or status='rejected' and reason field for failures.",
      "max_score": 20
    },
    {
      "name": "Handles mixed scenarios",
      "description": "The solution correctly handles collections containing both normal promises and problematic ones (poisoned .then(), various error types) in a single call, demonstrating promise.allsettled's robustness.",
      "max_score": 10
    }
  ]
}