{"record":{"id":"d37db1c4c4c430e4","repo":"stablyai/orca","slug":"no-user-wsl-distro-found-install-enable-wsl-or-pa","errorCode":null,"errorMessage":"No user WSL distro found. Install/enable WSL or pass --distro=NAME.","messagePattern":"No user WSL distro found\\. Install/enable WSL or pass --distro=NAME\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"config/scripts/repro-windows-apphang-terminal-activation.mjs","lineNumber":124,"sourceCode":"}\n\nfunction parsePositiveInt(name, value) {\n  const parsed = Number.parseInt(value ?? '', 10)\n  if (!Number.isInteger(parsed) || parsed <= 0 || String(parsed) !== value) {\n    throw new Error(`${name} requires a positive integer.`)\n  }\n  return parsed\n}\n\nasync function main() {\n  if (process.platform !== 'win32') {\n    throw new Error('This repro harness is intentionally Windows-only.')\n  }\n  const args = parseArgs()\n  const distros = listWslDistros()\n  const distro = args.distro ?? distros[0]\n  if (!distro) {\n    throw new Error('No user WSL distro found. Install/enable WSL or pass --distro=NAME.')\n  }\n  console.log(\n    `[apphang-repro] issue=https://github.com/stablyai/orca/issues/6874 distro=${distro} gpuModes=${args.gpuModes.join(',')} cycles=${args.cycles}`\n  )\n  const fixture = createWslFixture(distro)\n  console.log(\n    `[apphang-repro] fixture repo=${fixture.repoUncPath} plain=${fixture.plainUncPath} base=${fixture.baseLinuxPath}`\n  )\n\n  const results = []\n  try {\n    for (const gpuMode of args.gpuModes) {\n      results.push(await runGpuMode(gpuMode, args, fixture))\n      if (args.expect === 'repro' && results.at(-1)?.reproduced) {\n        break\n      }\n    }\n  } finally {","sourceCodeStart":106,"sourceCodeEnd":142,"githubUrl":"https://github.com/stablyai/orca/blob/1136503c6a231a16dce8f921f6fadb63d181e8db/config/scripts/repro-windows-apphang-terminal-activation.mjs#L106-L142","documentation":"Thrown by the apphang repro harness when listWslDistros() returns no usable distros (after filtering out docker-desktop). The harness needs at least one WSL distro to create a workspace fixture and drive terminal activation.","triggerScenarios":"Running on Windows where WSL is not installed, has no distros installed, or only has docker-desktop. Also fires if --distro names a distro that is not in the list (distros[0] is undefined and args.distro is null).","commonSituations":"A Windows machine with WSL enabled but no Linux distro installed, or only the docker-desktop integration distro present.","solutions":["Install a WSL distro: `wsl --install -d Ubuntu` then rerun.","Pass an explicit distro name if auto-detection picks the wrong one: --distro=Ubuntu."],"exampleFix":"// before\nnode config/scripts/repro-windows-apphang-terminal-activation.mjs\n// after (after installing)\nnode config/scripts/repro-windows-apphang-terminal-activation.mjs --distro=Ubuntu","handlingStrategy":"validation","validationCode":"const distros = listWslDistros()\nconst distro = options.distro ?? distros[0]\nif (!distro) {\n  throw new Error('No user WSL distro found. Install/enable WSL or pass --distro=NAME.')\n}","typeGuard":"function hasUserWslDistro(distros) {\n  return Array.isArray(distros) && distros.length > 0\n}","tryCatchPattern":null,"preventionTips":["Pre-check `wsl --list --quiet` before running the harness so you know a distro is available.","Pass --distro explicitly in automation to avoid depending on auto-detection order."],"tags":["windows","wsl","environment","apphang"],"backgroundTag":null,"analyzedSha":"1136503c6a231a16dce8f921f6fadb63d181e8db","analyzedAt":"2026-08-12T23:15:58.167Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}