tessl install tessl/npm-rest@2.0.0RESTful HTTP client library with composable interceptor architecture for Node.js and browsers
Agent Success
Agent success rate when using this tile
76%
Improvement
Agent success rate improvement when using this tile compared to baseline
1.29x
Baseline
Agent success rate without this tile
59%
{
"context": "This criteria evaluates how well the engineer uses the rest.js package's request cancellation capabilities to implement a request monitoring utility. The focus is on proper usage of rest.js cancellation API, particularly the cancel() method and canceled flag.",
"type": "weighted_checklist",
"checklist": [
{
"name": "Uses rest client",
"description": "Implementation imports and uses the rest.js client to make HTTP requests (e.g., `require('rest')` or `import rest from 'rest'`)",
"max_score": 10
},
{
"name": "Stores request objects",
"description": "The initiateRequest function properly stores and returns the request object/promise returned by rest.js, which provides access to cancellation methods",
"max_score": 15
},
{
"name": "Uses cancel() method",
"description": "Implementation uses the request.cancel() method to cancel individual requests when cancelRequest() is called",
"max_score": 25
},
{
"name": "Tracks request state",
"description": "Implementation maintains a collection or registry of active requests to track which requests are currently in-flight and need cancellation management",
"max_score": 15
},
{
"name": "Handles request completion",
"description": "Implementation properly removes requests from the active tracking collection when they complete (either successfully or with error) to prevent memory leaks",
"max_score": 15
},
{
"name": "Batch cancellation",
"description": "The cancelAllRequests function iterates through all tracked active requests and calls cancel() on each one",
"max_score": 10
},
{
"name": "Active count accuracy",
"description": "The getActiveRequestCount function accurately returns the current number of requests that are in-flight (not yet completed or canceled)",
"max_score": 10
}
]
}