evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
{
"context": "Evaluates whether the solution leans on portfinder to locate free TCP ports across default and custom hosts, pruning invalid hosts and respecting bounded ranges without reimplementing socket probing.",
"type": "weighted_checklist",
"checklist": [
{
"name": "Default hosts",
"description": "Combines caller-provided hosts with `portfinder._defaultHosts` (or the library's exported default host list) instead of hardcoding host detection before searching for a port.",
"max_score": 25
},
{
"name": "Promise search",
"description": "Obtains available ports via `portfinder.getPortPromise` (or a promisified `getPort`) rather than manual socket binding or custom probing.",
"max_score": 20
},
{
"name": "Host option",
"description": "Passes a `host` option into each `getPortPromise/getPort` call to target specific hosts in sequence instead of bypassing the library's host-aware scanning.",
"max_score": 20
},
{
"name": "Prunes invalid",
"description": "Relies on portfinder's invalid-host rejection (e.g., errors when a supplied `host` is unbindable) to skip bad hosts and emits a clear failure when all hosts are invalid.",
"max_score": 20
},
{
"name": "Bounded range",
"description": "Uses portfinder's range controls such as `port`/`startPort` with `stopPort` or `setBasePort`/`setHighestPort` to enforce the search window instead of manual iteration.",
"max_score": 15
}
]
}