{"record":{"id":"6dd8081054f8cd26","repo":"ruvnet/ruflo","slug":"no-baseline-found-capturing-initial-baseline","errorCode":null,"errorMessage":"No baseline found. Capturing initial baseline...","messagePattern":"No baseline found\\. Capturing initial baseline\\.\\.\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"v3/@claude-flow/testing/src/regression/performance-baseline.ts","lineNumber":93,"sourceCode":"    const baseline: BaselineData = {\n      version: '1.0.0',\n      capturedAt: Date.now(),\n      metrics,\n    };\n\n    await this.saveBaseline(baseline);\n    this.cachedBaseline = baseline;\n\n    return baseline;\n  }\n\n  /**\n   * Compare current performance against baseline\n   */\n  async compare(): Promise<BaselineComparison[]> {\n    const baseline = await this.loadBaseline();\n    if (!baseline) {\n      console.warn('No baseline found. Capturing initial baseline...');\n      await this.captureBaseline();\n      return [];\n    }\n\n    const currentMetrics = await this.measureCurrentPerformance();\n    const comparisons: BaselineComparison[] = [];\n\n    for (const current of currentMetrics) {\n      const baselineMetric = baseline.metrics.find((m) => m.name === current.name);\n      if (!baselineMetric) continue;\n\n      const isHigherBetter = current.category === 'throughput';\n      const diff = current.value - baselineMetric.value;\n      const percentChange = (diff / baselineMetric.value) * 100;\n\n      // For latency/memory, higher is worse. For throughput, lower is worse.\n      const degradation = isHigherBetter ? -percentChange : percentChange;\n","sourceCodeStart":75,"sourceCodeEnd":111,"githubUrl":"https://github.com/ruvnet/ruflo/blob/fa13ee4ad60ac2090b1480656eb233521790d640/v3/@claude-flow/testing/src/regression/performance-baseline.ts#L75-L111","documentation":"Bootstrap path in PerformanceBaseline.compare(): no baseline data exists yet, so compare() captures the current metrics as the initial baseline and returns an empty comparison array. First-run seeding, not a regression.","triggerScenarios":"Performance regression suite runs without an existing baseline file (first run on a machine, cleaned artifacts, or new benchmark); current timings are captured as the reference baseline.","commonSituations":"See trigger scenarios.","solutions":["Commit the captured initial performance baseline so future runs can compare against it.","Verify the baseline file path is correct and restore it from version control if it was deleted.","Re-run the baseline capture on representative hardware before trusting comparisons."],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"fa13ee4ad60ac2090b1480656eb233521790d640","analyzedAt":"2026-08-18T21:34:22.708Z","contentChangedAt":"2026-08-18T21:34:22.708Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}