{"record":{"id":"2aaca70714037eb5","repo":"stablyai/orca","slug":"verify-skills-cli-runtime-missing-entry-entry","errorCode":null,"errorMessage":"[verify-skills-cli-runtime] missing entry ${entry}","messagePattern":"\\[verify-skills-cli-runtime\\] missing entry (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"config/scripts/verify-skills-cli-runtime.cjs","lineNumber":115,"sourceCode":"  }\n  if (isOutsideRoot(artifactRoot, resolved)) {\n    throw new Error(\n      `[verify-skills-cli-runtime] import \"${specifier}\" from ` +\n        `${artifactPath(outDir, importer)} resolved outside ${artifactRoot}: ${resolved}`\n    )\n  }\n  return resolved\n}\n\nfunction collectRuntimeClosure(outDir, artifactRoot = dirname(outDir)) {\n  outDir = realpathSync(outDir)\n  artifactRoot = realpathSync(artifactRoot)\n  if (isOutsideRoot(artifactRoot, outDir)) {\n    throw new Error(`[verify-skills-cli-runtime] ${outDir} is outside ${artifactRoot}`)\n  }\n  const entry = resolve(outDir, 'cli', 'index.js')\n  if (!existsSync(entry)) {\n    throw new Error(`[verify-skills-cli-runtime] missing entry ${entry}`)\n  }\n  const pending = [entry]\n  const visited = new Set()\n\n  while (pending.length > 0) {\n    const file = pending.pop()\n    if (!file || visited.has(file)) {\n      continue\n    }\n    visited.add(file)\n    const source = readFileSync(file, 'utf8')\n    for (const specifier of runtimeImportSpecifiers(source, file)) {\n      const resolved = resolveRuntimeImport(outDir, artifactRoot, file, specifier)\n      if (resolved && !isOutsideRoot(artifactRoot, resolved) && /\\.(?:c|m)?js$/.test(resolved)) {\n        pending.push(resolved)\n      }\n    }\n  }","sourceCodeStart":97,"sourceCodeEnd":133,"githubUrl":"https://github.com/stablyai/orca/blob/1136503c6a231a16dce8f921f6fadb63d181e8db/config/scripts/verify-skills-cli-runtime.cjs#L97-L133","documentation":"collectRuntimeClosure() computes the entry as resolve(outDir, 'cli', 'index.js') and throws if it doesn't existSync. The runtime closure walk has to start somewhere; if the expected cli/index.js entry isn't present, the build either didn't run, emitted a different entry path, or outDir is wrong.","triggerScenarios":"The CLI build wasn't run before verification; the build emits index.cjs or dist/cli/index.js instead of cli/index.js; outDir points at the wrong directory; the build failed silently and produced partial output.","commonSituations":"Build step skipped or failing in CI; bundler output config changed the entry filename; monorepo where the package's dist is at a different relative path; verification step running before the build step.","solutions":["Confirm outDir/cli/index.js actually exists (ls the path from the error message).","If the build emits a different entry name, update the verifier's entry path or fix the build to emit cli/index.js.","Ensure the build step ran successfully before the verify step.","Re-check outDir passed to collectRuntimeClosure matches the real build output directory."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Before the closure walk, confirm the entry exists:\nimport { existsSync } from 'node:fs'\nimport path from 'node:path'\nconst entry = path.join(outDir, 'cli', 'index.js')\nif (!existsSync(entry)) {\n  throw new Error(`Build did not produce expected entry ${entry}; run the build first`)\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Order the workflow so the CLI build step completes before the runtime verifier runs.","If the build emits a different entry name, update the verifier or fix the build config to emit cli/index.js.","Fail the build step on non-zero exit so the verifier never runs against partial output."],"tags":["bundler","build-artifact","entry-point","skills-cli","configuration"],"backgroundTag":null,"analyzedSha":"1136503c6a231a16dce8f921f6fadb63d181e8db","analyzedAt":"2026-08-12T23:15:58.167Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}