SigNoz is an open-source, OpenTelemetry-native observability platform for your team and their AI agents. Get logs, metrics, and traces in one tool with features like APM, distributed tracing, log management, infra monitoring, etc. Combined with SigNoz MCP and a native AI teammate (in SigNoz Cloud) it helps you build more resilient apps.
TypeScript apmapplication-monitoringdistributed-tracinggogood-first-issuejaegerloglogsmetricsmonitoringnextjsobservabilityopen-sourceopentelemetryprometheusreactreactjsself-hostedtracingtypescript
fix: handle expected value less than zero (#7410)
Srikanth Chekuri8f095dfbc9c2
diff --git a/ee/query-service/anomaly/seasonal.go b/ee/query-service/anomaly/seasonal.goindex 900145f4a7..ea71a3a749 100644--- a/ee/query-service/anomaly/seasonal.go+++ b/ee/query-service/anomaly/seasonal.go@@ -313,6 +313,9 @@ func (p *BaseSeasonalProvider) getScore(series, prevSeries, weekSeries, weekPrevSeries, past2SeasonSeries, past3SeasonSeries *v3.Series, value float64, idx int,) float64 {expectedValue := p.getExpectedValue(series, prevSeries, weekSeries, weekPrevSeries, past2SeasonSeries, past3SeasonSeries, idx)+ if expectedValue < 0 {+ expectedValue = p.getMovingAvg(prevSeries, movingAvgWindowSize, idx)+ }return (value - expectedValue) / p.getStdDev(weekSeries)}