{"record":{"id":"9928e490cc46e0f3","repo":"paperclipai/paperclip","slug":"routinekey-is-required-valid-values-wiki-maint","errorCode":null,"errorMessage":"routineKey is required; valid values: ${WIKI_MAINTENANCE_ROUTINE_KEYS.join(\", \")}","messagePattern":"routineKey is required; valid values: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/plugins/plugin-llm-wiki/src/worker.ts","lineNumber":71,"sourceCode":"  selectWikiAgentResource,\n  selectWikiProjectResource,\n  startWikiQuerySession,\n  spaceFolderStatus,\n  updateEventIngestionSettings,\n  updatePaperclipIngestionProfile,\n  updateSpace,\n  writeTemplate,\n  writeWikiPage,\n} from \"./wiki.js\";\n\nfunction stringField(value: unknown): string | null {\n  return typeof value === \"string\" && value.trim().length > 0 ? value.trim() : null;\n}\n\nfunction routineKeyField(value: unknown): (typeof WIKI_MAINTENANCE_ROUTINE_KEYS)[number] {\n  const routineKey = stringField(value);\n  if (!routineKey) {\n    throw new Error(`routineKey is required; valid values: ${WIKI_MAINTENANCE_ROUTINE_KEYS.join(\", \")}`);\n  }\n  if (!WIKI_MAINTENANCE_ROUTINE_KEYS.includes(routineKey as (typeof WIKI_MAINTENANCE_ROUTINE_KEYS)[number])) {\n    throw new Error(`Unknown managed routine: ${routineKey}`);\n  }\n  return routineKey as (typeof WIKI_MAINTENANCE_ROUTINE_KEYS)[number];\n}\n\nfunction routineOverridesFromParams(params: Record<string, unknown>) {\n  const overrides: { assigneeAgentId?: string; projectId?: string } = {};\n  const assigneeAgentId = stringField(params.assigneeAgentId);\n  const projectId = stringField(params.projectId);\n  if (assigneeAgentId) overrides.assigneeAgentId = assigneeAgentId;\n  if (projectId) overrides.projectId = projectId;\n  return overrides;\n}\n\nlet activeContext: PluginContext | null = null;\nconst PAPERCLIP_EVENT_INGESTION_EVENTS = [","sourceCodeStart":53,"sourceCodeEnd":89,"githubUrl":"https://github.com/paperclipai/paperclip/blob/5716fe907e596ce73501408fc6efdb19fb61edf2/packages/plugins/plugin-llm-wiki/src/worker.ts#L53-L89","documentation":"Error \"routineKey is required; valid values: ${WIKI_MAINTENANCE_ROUTINE_KEYS.join(\", \")}\" thrown in paperclipai/paperclip.","triggerScenarios":"Thrown at packages/plugins/plugin-llm-wiki/src/worker.ts:71 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Pass routineKey with one of the listed valid routine keys."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"5716fe907e596ce73501408fc6efdb19fb61edf2","analyzedAt":"2026-08-18T22:49:45.177Z","contentChangedAt":"2026-08-18T22:49:45.177Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}