{"record":{"id":"4d2c24c238360b7c","repo":"deepseek-ai/deepseek-harness","slug":"expected-json-string-field-key","errorCode":null,"errorMessage":"expected JSON string field \"${key}\"","messagePattern":"expected JSON string field \"(.+?)\"","errorType":"validation","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/extensions/tool-cordis/src/index.ts","lineNumber":410,"sourceCode":"          text: reference === undefined ? renderUnavailableReference(id) : renderReference(reference),\n        }],\n        source: { kind: 'plugin', plugin: name, form: 'instructions' },\n      })\n    })\n    return { kind: 'enter', messages: [...decision.messages, ...contexts] }\n  })\n}\n\nfunction requireJsonObject(value: JsonValue): Record<string, JsonValue> {\n  if (typeof value !== 'object' || value === null || Array.isArray(value)) {\n    throw new Error('expected a JSON object')\n  }\n  return value\n}\n\nfunction requireJsonString(value: Record<string, JsonValue>, key: string): string {\n  const field = value[key]\n  if (typeof field !== 'string') throw new Error(`expected JSON string field \"${key}\"`)\n  return field\n}\n\ntype SelfState = 'defined' | 'awaiting-approval' | 'client-pending' | 'stopped' | 'running' | 'waiting' | 'failed'\n\nfunction selfSummary(reference: DynamicCordisReference & { packages?: readonly unknown[] }): Record<string, JsonValue> {\n  const latest = reference.latestRun\n  const state = selfState(reference)\n  return {\n    pluginId: String(reference.pluginId),\n    name: reference.name,\n    packageCount: reference.packages?.length ?? 1,\n    state,\n    ...reference.currentPackageId === undefined ? {} : { currentPackageId: String(reference.currentPackageId) },\n    ...reference.nextPackageId === undefined ? {} : { nextPackageId: String(reference.nextPackageId) },\n    ...reference.activeRun === undefined ? {} : {\n      activeRun: {\n        pluginRunId: String(reference.activeRun.pluginRunId),","sourceCodeStart":392,"sourceCodeEnd":428,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/extensions/tool-cordis/src/index.ts#L392-L428","documentation":"Error \"expected JSON string field \"${key}\"\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/extensions/tool-cordis/src/index.ts:410 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"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"}