{"record":{"id":"a617613ee7d3ace5","repo":"mastra-ai/mastra","slug":"observational-memory-requires-mastra-core-support","errorCode":null,"errorMessage":"Observational memory requires @mastra/core support for request-response-id-rotation. Please bump @mastra/core to a newer version.","messagePattern":"Observational memory requires @mastra/core support for request-response-id-rotation\\. Please bump @mastra/core to a newer version\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/memory/src/index.ts","lineNumber":1936,"sourceCode":"\n    const coreSupportsOM = coreFeatures.has('observationalMemory');\n    if (!coreSupportsOM) {\n      throw new Error(\n        'Observational memory is enabled but the installed version of @mastra/core does not support it. ' +\n          'Please upgrade @mastra/core to a version that includes observational memory support.',\n      );\n    }\n\n    if (omConfig.observation?.bufferTokens !== false && !coreFeatures.has('asyncBuffering')) {\n      throw new Error(\n        'Observational memory async buffering is enabled by default but the installed version of @mastra/core does not support it. ' +\n          'Either upgrade @mastra/core, @mastra/memory, and your storage adapter (@mastra/libsql, @mastra/pg, @mastra/mongodb, or @mastra/convex) to the latest version, ' +\n          'or explicitly disable async buffering by setting `observation: { bufferTokens: false }` in your observationalMemory config.',\n      );\n    }\n\n    if (!coreFeatures.has('request-response-id-rotation')) {\n      throw new Error(\n        'Observational memory requires @mastra/core support for request-response-id-rotation. Please bump @mastra/core to a newer version.',\n      );\n    }\n\n    if (omConfig.experimental_subconscious) {\n      await this.getKnowledgeStore();\n    }\n\n    const { ObservationalMemory: OMClass } = await import('./processors/observational-memory');\n\n    const onIndexObservations = this.hasRetrievalSearch(omConfig.retrieval)\n      ? async (observation: {\n          text: string;\n          groupId: string;\n          range: string;\n          threadId: string;\n          resourceId: string;\n          observedAt?: Date;","sourceCodeStart":1918,"sourceCodeEnd":1954,"githubUrl":"https://github.com/mastra-ai/mastra/blob/75dd419e613fe9c39f846ffc500716141b74fda6/packages/memory/src/index.ts#L1918-L1954","documentation":"Observational memory depends on @mastra/core's 'request-response-id-rotation' capability to safely rotate request/response ids during observation processing. If the installed core lacks that feature flag, Memory throws before using OM. Unlike the previous two gates, there is no config opt-out — a newer core is required.","triggerScenarios":"Enabling observationalMemory with an @mastra/core version that supports observationalMemory and asyncBuffering but predates the request-response-id-rotation feature.","commonSituations":"Running an intermediate core version (new enough to pass the earlier checks but still missing this flag); frozen lockfiles in CI resolving stale core; mixed @mastra/* versions in a monorepo.","solutions":["Bump @mastra/core to the latest version that includes request-response-id-rotation support.","Deduplicate @mastra/core in your workspace (pnpm dedupe / check the lockfile) so a single current version is used everywhere.","If upgrading is impossible, disable observationalMemory."],"exampleFix":"// before (lockfile has @mastra/core 0.x older)\n\"@mastra/core\": \"0.10.0\"\n// after\n\"@mastra/core\": \"latest\" // or the release line matching @mastra/memory\n// then: pnpm install && pnpm dedupe","handlingStrategy":"validation","validationCode":"import { features } from '@mastra/core';\nif (memoryConfig.observationalMemory?.enabled && !features.has('request-response-id-rotation')) {\n  throw new Error('request-response-id-rotation requires a newer @mastra/core');\n}","typeGuard":"function coreSupportsIdRotation(coreFeatures: Set<string>): boolean {\n  return coreFeatures.has('request-response-id-rotation');\n}","tryCatchPattern":"try {\n  await initMemory();\n} catch (e) {\n  if (e instanceof Error && e.message.includes('request-response-id-rotation')) {\n    logger.error('Bump @mastra/core; there is no config opt-out for this requirement.');\n  }\n  throw e;\n}","preventionTips":["Bump @mastra/core to the latest version before enabling observationalMemory.","Run pnpm dedupe so only one (current) @mastra/core version exists in the workspace.","Do not partially upgrade @mastra/* packages."],"tags":["memory","observational-memory","version-compatibility","upgrade"],"backgroundTag":"peer-dependency-version-mismatch","analyzedSha":"75dd419e613fe9c39f846ffc500716141b74fda6","analyzedAt":"2026-08-30T00:15:31.844Z","schemaVersion":2},"datasetVersion":"2026-08-30T03:17:51.788Z"}