{"record":{"id":"8d306c3a777c344e","repo":"paperclipai/paperclip","slug":"repo-must-be-an-owner-name-github-repository-re","errorCode":null,"errorMessage":"--repo must be an owner/name GitHub repository, received '${repo}'.","messagePattern":"--repo must be an owner/name GitHub repository, received '(.+?)'\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"cli/src/commands/install.ts","lineNumber":135,"sourceCode":"  throw new Error(`npm returned an unexpected version response: ${trimmed}`);\n}\n\nexport async function resolvePublishedVersion(spec: string, runCommand: CommandRunner): Promise<string> {\n  const result = await runCommand(\n    \"npm\",\n    [\"view\", `paperclipai@${spec}`, \"version\", \"--json\", `--registry=${PUBLIC_NPM_REGISTRY}`],\n    { maxBuffer: 1024 * 1024 },\n  );\n  return parseResolvedVersion(result.stdout);\n}\n\nexport function resolveGitInstallRequest(options: InstallOptions): { repo: string; ref: string; pinned: boolean } | null {\n  if (!options.ref && !options.repo) return null;\n  if (!options.ref) throw new Error(\"--repo requires --ref.\");\n  if (options.canary || options.version) throw new Error(\"--ref cannot be combined with --canary or --version.\");\n  const repo = (options.repo ?? DEFAULT_GITHUB_REPO).trim();\n  const ref = options.ref.trim();\n  if (!/^[A-Za-z0-9_.-]+\\/[A-Za-z0-9_.-]+$/.test(repo)) throw new Error(`--repo must be an owner/name GitHub repository, received '${repo}'.`);\n  if (!ref || ref.startsWith(\"-\") || /[\\0\\r\\n]/.test(ref)) throw new Error(`Invalid GitHub ref '${options.ref}'.`);\n  return { repo, ref, pinned: /^[0-9a-f]{7,40}$/i.test(ref) };\n}\n\nasync function runGitHubCurl(\n  args: string[],\n  runCommand: CommandRunner,\n  options?: Parameters<CommandRunner>[2],\n): Promise<{ stdout: string; stderr: string }> {\n  // Anonymous GitHub requests are rate-limited per source IP (CI runners and\n  // corporate NAT exhaust the shared quota); honor an ambient token when present.\n  // The token travels via a curl --config file so it never appears in process args.\n  const token = process.env.GH_TOKEN ?? process.env.GITHUB_TOKEN;\n  if (!token) return runCommand(\"curl\", args, options);\n  const configDir = fs.mkdtempSync(path.join(os.tmpdir(), \"paperclipai-gh-\"));\n  const configFile = path.join(configDir, \"headers\");\n  try {\n    fs.writeFileSync(configFile, `header = \"Authorization: Bearer ${token}\"\\n`, { mode: 0o600 });","sourceCodeStart":117,"sourceCodeEnd":153,"githubUrl":"https://github.com/paperclipai/paperclip/blob/67001ec6eb96ae601aa27bc91d9b2415d665334a/cli/src/commands/install.ts#L117-L153","documentation":"Error \"--repo must be an owner/name GitHub repository, received '${repo}'.\" thrown in paperclipai/paperclip.","triggerScenarios":"Thrown at cli/src/commands/install.ts:135 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"67001ec6eb96ae601aa27bc91d9b2415d665334a","analyzedAt":"2026-08-12T12:05:45.408Z","schemaVersion":2},"datasetVersion":"2026-08-12T18:17:37.767Z"}