JuliusBrussee/caveman · error
cacheengine: unknown attribution %q
Error message
cacheengine: unknown attribution %q
What it means
Error "cacheengine: unknown attribution %q" thrown in JuliusBrussee/caveman.
Source
Thrown at cacheengine/engine.go:295
}
if request.ExpectedCalls < 0 || request.ExpectedRequestsPerMinute < 0 {
return errors.New("cacheengine: negative traffic expectation")
}
profile := normalizedProfile(request.Profile)
if !validIdentity(profile.ID, 256, false) || !validIdentity(profile.Provider, 64, true) || !validIdentity(profile.OptimizerID, 256, true) {
return errors.New("cacheengine: invalid profile identity")
}
if profile.Mode != ModeUnsupported && profile.Mode != ModeImplicit && profile.Mode != ModeAffinity && profile.Mode != ModeExplicit {
return fmt.Errorf("cacheengine: unknown mode %q", profile.Mode)
}
if profile.Mode != ModeUnsupported {
if profile.MaxBreakpoints <= 0 || profile.MinPrefixTokens < 0 || profile.MaxRPMPerKey < 0 || profile.TTL < 0 {
return errors.New("cacheengine: invalid cache thresholds")
}
switch profile.Attribution {
case AttributionNone, AttributionOrganic, AttributionAffinity, AttributionCausal:
default:
return fmt.Errorf("cacheengine: unknown attribution %q", profile.Attribution)
}
if profile.EconomicsKnown && (!finiteNonNegative(profile.WriteMultiplier) || !finiteNonNegative(profile.ReadMultiplier)) {
return errors.New("cacheengine: invalid cache economics")
}
}
return nil
}
func normalizedProfile(profile Profile) Profile {
if profile.Mode == ModeUnsupported {
if profile.ID == "" {
profile.ID = "unsupported"
}
return profile
}
if profile.MaxBreakpoints == 0 {
profile.MaxBreakpoints = 1
}View on GitHub (pinned to 27d5a3981a)
Solutions
- Use a known attribution mode.
When it happens
Trigger: Thrown at cacheengine/engine.go:295 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of JuliusBrussee/caveman@27d5a3981a (2026-08-15).
Data as JSON: /api/errors/1c2bfa6ddc052dad.
Report an issue: GitHub.