{"record":{"id":"372b72848acf2b3b","repo":"deepseek-ai/deepseek-harness","slug":"typert-loader-pkgname-typert-schemas-must-be-a","errorCode":null,"errorMessage":"typert-loader: ${pkgName} TYPERT.schemas must be an array","messagePattern":"typert-loader: (.+?) TYPERT\\.schemas must be an array","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/typert/loader/src/index.ts","lineNumber":97,"sourceCode":" * @param pkgName - the package whose typert face was imported.\n * @param exported - the module's `TYPERT` export.\n * @returns the validated contribution.\n */\nexport function validateTypertManifest(pkgName: string, exported: unknown): TypertContribution {\n  if (typeof exported !== 'object' || exported === null) {\n    throw new Error(`typert-loader: ${pkgName} exports \"${TYPERT_HOST_EXPORT}\" but its module has no TYPERT manifest object`)\n  }\n  const manifest = exported as Record<string, unknown>\n  if (manifest.package !== pkgName) {\n    throw new Error(\n      `typert-loader: ${pkgName} TYPERT manifest names package ${JSON.stringify(manifest.package)} — the manifest must be owned by the package that exports it`,\n    )\n  }\n  if (manifest.face !== 'host') {\n    throw new Error(`typert-loader: ${pkgName} exports \"${TYPERT_HOST_EXPORT}\" but TYPERT.face is not \"host\"`)\n  }\n  if (!Array.isArray(manifest.schemas)) {\n    throw new Error(`typert-loader: ${pkgName} TYPERT.schemas must be an array`)\n  }\n  for (const value of manifest.schemas as unknown[]) {\n    if (typeof value !== 'object' || value === null) {\n      throw new Error(`typert-loader: ${pkgName} TYPERT.schemas contains a non-object schema`)\n    }\n    const schema = value as Record<string, unknown>\n    requireString(pkgName, schema, 'name', 'schema')\n    if (typeof schema.schema !== 'object' || schema.schema === null || !('_zod' in schema.schema)) {\n      throw new Error(`typert-loader: ${pkgName} TYPERT schema \"${schema.name as string}\" is not a zod v4 schema instance`)\n    }\n  }\n  const model = requireObject(pkgName, manifest.model, 'TYPERT.model')\n  const services = requireArray(pkgName, model.services, 'TYPERT.model.services')\n  const events = requireArray(pkgName, model.events, 'TYPERT.model.events')\n  const objects = requireArray(pkgName, model.objects, 'TYPERT.model.objects')\n  for (const value of services) {\n    const service = requireObject(pkgName, value, 'service')\n    requireDocumentation(pkgName, service, 'service')","sourceCodeStart":79,"sourceCodeEnd":115,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/typert/loader/src/index.ts#L79-L115","documentation":"Error \"typert-loader: ${pkgName} TYPERT.schemas must be an array\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/typert/loader/src/index.ts:97 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Set TYPERT.schemas to an array in the manifest."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b150a551b8d465e31e418e1b2eaf5e79bbb7d28e","analyzedAt":"2026-08-24T18:12:29.105Z","schemaVersion":2},"datasetVersion":"2026-08-24T22:17:12.610Z"}