{"record":{"id":"2957e0263a3a1c60","repo":"Fission-AI/OpenSpec","slug":"no-openspec-root","errorCode":"no_openspec_root","errorMessage":"No OpenSpec root found from the current directory.","messagePattern":"No OpenSpec root found from the current directory\\.","errorType":"exception","errorClass":"RootSelectionError","httpStatus":null,"severity":"error","filePath":"src/core/root-selection.ts","lineNumber":448,"sourceCode":"    fromStoreError(error);\n  }\n  const registeredIds = registry\n    ? listStoreRegistryEntries(registry).map((entry) => entry.id)\n    : [];\n\n  if (registeredIds.length > 0) {\n    throw new RootSelectionError(\n      `No OpenSpec root found in the current directory or its ancestors. Registered stores: ${registeredIds.join(', ')}. Pass --store <id> to use one, or run openspec init to create a local root.`,\n      'no_root_with_registered_stores',\n      {\n        target: 'openspec.root',\n        fix: `Rerun with --store <id> (registered: ${registeredIds.join(', ')}) or run openspec init.`,\n      }\n    );\n  }\n\n  if (options.allowImplicitRoot === false) {\n    throw new RootSelectionError(\n      'No OpenSpec root found from the current directory.',\n      'no_openspec_root',\n      { target: 'openspec.root', fix: 'Run openspec init to create a root here.' }\n    );\n  }\n\n  return makeRoot(canonicalDirectory(startPath), 'implicit');\n}\n\n// -----------------------------------------------------------------------------\n// Output helpers\n// -----------------------------------------------------------------------------\n\nexport interface RootOutput {\n  path: string;\n  source: OpenSpecRootSource;\n  store_id?: string;\n}","sourceCodeStart":430,"sourceCodeEnd":466,"githubUrl":"https://github.com/Fission-AI/OpenSpec/blob/6926ccb18afa4ff621112813e9968334576ee11a/src/core/root-selection.ts#L430-L466","documentation":"Error \"No OpenSpec root found from the current directory.\" thrown in Fission-AI/OpenSpec.","triggerScenarios":"Thrown at src/core/root-selection.ts:448 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":"6926ccb18afa4ff621112813e9968334576ee11a","analyzedAt":"2026-08-25T12:29:45.729Z","schemaVersion":2},"datasetVersion":"2026-08-25T16:17:27.014Z"}