Skip to content

Commit 8df5894

Browse files
committed
Fix float32 precision bug causing bucket values to exceed 9999 for users with hash values near max uint32
1 parent 99ff314 commit 8df5894

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/decision/bucketer/murmurhashbucketer.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ import (
2727
"github.com/twmb/murmur3"
2828
)
2929

30-
var maxHashValue = float64(math.Pow(2, 32))
30+
var maxHashValue = math.Pow(2, 32)
3131

3232
// DefaultHashSeed is the hash seed to use for murmurhash
3333
const DefaultHashSeed = 1

0 commit comments

Comments
 (0)