{"record":{"id":"4e010bb26dc5aa6b","repo":"ReactiveX/rxjs","slug":"harness-requires-codex-claude-or-cursor","errorCode":null,"errorMessage":"--harness requires codex, claude, or cursor","messagePattern":"--harness requires codex, claude, or cursor","errorType":"validation","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/migrate/src/skill-cli.ts","lineNumber":84,"sourceCode":"  }\n  throw new Error('Cannot locate the canonical Skill shipped by @rxjs/migrate.');\n}\n\nfunction parseSkillArguments(argv: readonly string[]): ParsedSkillCliOptions {\n  const action = argv[0];\n  if (action !== 'check' && action !== 'install' && action !== 'update' && action !== 'remove') {\n    throw new Error(\n      'Usage: rxjs-migrate-skill <check|install|update|remove> --harness <codex|claude|cursor> [--project-root <dir>] [--force]'\n    );\n  }\n  let harness: SkillHarness | undefined;\n  let projectRoot = process.cwd();\n  let force = false;\n  for (let index = 1; index < argv.length; index++) {\n    const argument = argv[index];\n    if (argument === '--harness') {\n      const value = argv[++index];\n      if (!value || !skillHarnesses.includes(value as SkillHarness)) throw new Error('--harness requires codex, claude, or cursor');\n      harness = value as SkillHarness;\n    } else if (argument === '--project-root') {\n      const value = argv[++index];\n      if (!value) throw new Error('--project-root requires a directory');\n      projectRoot = value;\n    } else if (argument === '--force') {\n      force = true;\n    } else {\n      throw new Error(`Unknown option: ${String(argument)}`);\n    }\n  }\n  if (!harness) throw new Error('--harness is required');\n  return { action, harness, projectRoot, force };\n}\n\nfunction writeJson(stream: Pick<NodeJS.WriteStream, 'write'>, value: unknown): void {\n  stream.write(`${JSON.stringify(value, null, 2)}\\n`);\n}","sourceCodeStart":66,"sourceCodeEnd":102,"githubUrl":"https://github.com/ReactiveX/rxjs/blob/54796b38a57e6309f9861e174737479bb3f63f61/packages/migrate/src/skill-cli.ts#L66-L102","documentation":"Thrown by parseSkillArguments when --harness is missing a value or the value is not one of the supported harness identifiers (codex, claude, cursor).","triggerScenarios":"Running with --harness alone at the end of the command, --harness windsurf (unsupported), or a typo like '--harness cluade'.","commonSituations":"Expecting support for other agent harnesses; forgetting the value; trailing-flag truncation in scripts.","solutions":["Pass one of the exact values: codex, claude, or cursor","Quote and double-check the value for typos","If you need another harness, check the package's adapter list and supported version"],"exampleFix":"# before\nrxjs-migrate-skill check --harness windsurf\n# after\nrxjs-migrate-skill check --harness claude","handlingStrategy":"validation","validationCode":"const harnesses = ['codex','claude','cursor'];\nif (!harnesses.includes(value)) throw new TypeError(`harness must be one of ${harnesses.join('|')}`);","typeGuard":"const isHarness = (v: string): v is 'codex'|'claude'|'cursor' => ['codex','claude','cursor'].includes(v);","tryCatchPattern":null,"preventionTips":["Copy exact harness identifiers from docs","Validate CLI inputs in wrapper scripts"],"tags":["cli","arguments","validation"],"backgroundTag":"invalid-cli-argument","analyzedSha":"54796b38a57e6309f9861e174737479bb3f63f61","analyzedAt":"2026-08-28T10:21:27.410Z","schemaVersion":2},"datasetVersion":"2026-08-28T11:17:15.048Z"}