{"record":{"id":"8efc782733bd2c3c","repo":"openai/codex","slug":"codex-config-override-at-path-must-be-a-finite","errorCode":null,"errorMessage":"Codex config override at ${path} must be a finite number","messagePattern":"Codex config override at (.+?) must be a finite number","errorType":"validation","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"sdk/typescript/src/exec.ts","lineNumber":312,"sourceCode":"    }\n    if (child === undefined) {\n      continue;\n    }\n    const path = prefix ? `${prefix}.${key}` : key;\n    if (isPlainObject(child)) {\n      flattenConfigOverrides(child, path, overrides);\n    } else {\n      overrides.push(`${path}=${toTomlValue(child, path)}`);\n    }\n  }\n}\n\nfunction toTomlValue(value: CodexConfigValue, path: string): string {\n  if (typeof value === \"string\") {\n    return JSON.stringify(value);\n  } else if (typeof value === \"number\") {\n    if (!Number.isFinite(value)) {\n      throw new Error(`Codex config override at ${path} must be a finite number`);\n    }\n    return `${value}`;\n  } else if (typeof value === \"boolean\") {\n    return value ? \"true\" : \"false\";\n  } else if (Array.isArray(value)) {\n    const rendered = value.map((item, index) => toTomlValue(item, `${path}[${index}]`));\n    return `[${rendered.join(\", \")}]`;\n  } else if (isPlainObject(value)) {\n    const parts: string[] = [];\n    for (const [key, child] of Object.entries(value)) {\n      if (!key) {\n        throw new Error(\"Codex config override keys must be non-empty strings\");\n      }\n      if (child === undefined) {\n        continue;\n      }\n      parts.push(`${formatTomlKey(key)} = ${toTomlValue(child, `${path}.${key}`)}`);\n    }","sourceCodeStart":294,"sourceCodeEnd":330,"githubUrl":"https://github.com/openai/codex/blob/339751715c64496cb86246bfb3935f40e309dd3d/sdk/typescript/src/exec.ts#L294-L330","documentation":"Error \"Codex config override at ${path} must be a finite number\" thrown in openai/codex.","triggerScenarios":"Thrown at sdk/typescript/src/exec.ts:312 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Set the override at the given path to a finite number instead of NaN or Infinity."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"339751715c64496cb86246bfb3935f40e309dd3d","analyzedAt":"2026-08-25T05:35:09.876Z","schemaVersion":2},"datasetVersion":"2026-08-25T06:17:31.827Z"}