{"record":{"id":"66d6362fd9355b0a","repo":"JuliusBrussee/caveman","slug":"ccr-unknown-lifecycle-q","errorCode":null,"errorMessage":"ccr: unknown lifecycle %q","messagePattern":"ccr: unknown lifecycle %q","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"engine/ccr/store.go","lineNumber":118,"sourceCode":"\nfunc prepareObject(obj Object) (Object, error) {\n\tif _, ok := objectTypes[obj.Type]; !ok {\n\t\treturn Object{}, fmt.Errorf(\"ccr: unknown object type %q\", obj.Type)\n\t}\n\tif strings.TrimSpace(obj.SessionID) == \"\" {\n\t\treturn Object{}, errors.New(\"ccr: typed object session_id is required\")\n\t}\n\tif obj.Currentness == \"\" {\n\t\tobj.Currentness = Current\n\t}\n\tif obj.Currentness != Current && obj.Currentness != Stale && obj.Currentness != Archived {\n\t\treturn Object{}, fmt.Errorf(\"ccr: unknown currentness %q\", obj.Currentness)\n\t}\n\tif obj.Lifecycle == \"\" {\n\t\tobj.Lifecycle = Hot\n\t}\n\tif obj.Lifecycle != Hot && obj.Lifecycle != Warm && obj.Lifecycle != Cold && obj.Lifecycle != LifecycleArchived {\n\t\treturn Object{}, fmt.Errorf(\"ccr: unknown lifecycle %q\", obj.Lifecycle)\n\t}\n\tif obj.CreatedAt.IsZero() {\n\t\tobj.CreatedAt = time.Now().UTC()\n\t} else {\n\t\tobj.CreatedAt = obj.CreatedAt.UTC()\n\t}\n\tdataSum := sha256.Sum256(obj.Data)\n\tcomputedHash := \"sha256:\" + hex.EncodeToString(dataSum[:])\n\tif obj.ContentHash == \"\" {\n\t\tobj.ContentHash = computedHash\n\t} else if obj.ContentHash != computedHash {\n\t\treturn Object{}, errors.New(\"ccr: typed object content_hash does not match data\")\n\t}\n\tif obj.OriginalByteLength == 0 {\n\t\tobj.OriginalByteLength = len(obj.Data)\n\t}\n\tif obj.StoredByteLength == 0 {\n\t\tobj.StoredByteLength = len(obj.Data)","sourceCodeStart":100,"sourceCodeEnd":136,"githubUrl":"https://github.com/JuliusBrussee/caveman/blob/27d5a3981a347890211bb1bf2439e5c821a63bc9/engine/ccr/store.go#L100-L136","documentation":"Error \"ccr: unknown lifecycle %q\" thrown in JuliusBrussee/caveman.","triggerScenarios":"Thrown at engine/ccr/store.go:118 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use a known ccr lifecycle value."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"27d5a3981a347890211bb1bf2439e5c821a63bc9","analyzedAt":"2026-08-15T09:26:11.751Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}