open-codebase-index 0.22.0 → 0.22.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.js CHANGED
@@ -16500,6 +16500,15 @@ async function runEvaluation(options) {
16500
16500
  const indexer = new Indexer(options.projectRoot, effectiveConfig, "opencode");
16501
16501
  try {
16502
16502
  await indexer.index();
16503
+ if (options.ciMode) {
16504
+ const indexStatus = await indexer.getStatus();
16505
+ if (!indexStatus.indexed || indexStatus.vectorCount === 0) {
16506
+ const failedBatchDetails = indexStatus.failedBatchesCount > 0 ? ` ${indexStatus.failedBatchesCount} embedding batch(es) failed; diagnostics: ${indexStatus.failedBatchesPath ?? "unavailable"}.` : "";
16507
+ throw new Error(
16508
+ `Evaluation reindex produced no searchable vectors.${failedBatchDetails} Check the embedding provider and indexing diagnostics before evaluating retrieval quality.`
16509
+ );
16510
+ }
16511
+ }
16503
16512
  const perQuery = [];
16504
16513
  for (const query of dataset.queries) {
16505
16514
  if (query.expected.branch && query.expected.branch !== indexer.getCurrentBranch()) {