mirror of
https://github.com/hanzoai/metrics.git
synced 2026-10-30 20:03:39 +00:00
Previously, for `^` aka pow function calls, VictoriaMetrics returned `1` if left arg was Nan. For example, given query=`(hour()==2)^1` returns 1 for NaN produced by hour() == 2 function. It added additional non-exist datapoints to the timeseries. This commit port bugfix from `metricql` package and adds test for it. Now, VictoriaMetrics correctly returns `NaN` for such cases. Related issue: https://github.com/VictoriaMetrics/VictoriaMetrics/issues/7359 Signed-off-by: f41gh7 <[email protected]>
14 lines
345 B
Go
14 lines
345 B
Go
// Copyright 2024 The Go Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style
|
|
// license that can be found in the LICENSE file.
|
|
|
|
//go:build linux && go1.24
|
|
|
|
package unix
|
|
|
|
import _ "unsafe"
|
|
|
|
//go:linkname vgetrandom runtime.vgetrandom
|
|
//go:noescape
|
|
func vgetrandom(p []byte, flags uint32) (ret int, supported bool)
|