{"record":{"id":"c978f75c45dc276c","repo":"musistudio/claude-code-router","slug":"unsupported-png-format","errorCode":null,"errorMessage":"Unsupported PNG format.","messagePattern":"Unsupported PNG format\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/electron/src/main/ipc.ts","lineNumber":778,"sourceCode":"    offset += 4;\n    const data = png.subarray(offset, offset + length);\n    offset += length + 4;\n\n    if (type === \"IHDR\") {\n      width = data.readUInt32BE(0);\n      height = data.readUInt32BE(4);\n      bitDepth = data[8];\n      colorType = data[9];\n      interlaceMethod = data[12];\n    } else if (type === \"IDAT\") {\n      idatChunks.push(Buffer.from(data));\n    } else if (type === \"IEND\") {\n      break;\n    }\n  }\n\n  if (width <= 0 || height <= 0 || bitDepth !== 8 || (colorType !== 2 && colorType !== 6) || interlaceMethod !== 0) {\n    throw new Error(\"Unsupported PNG format.\");\n  }\n\n  const channels = colorType === 6 ? 4 : 3;\n  const stride = width * channels;\n  const inflated = inflateSync(Buffer.concat(idatChunks));\n  const pixels = new Uint8Array(width * height * channels);\n  let sourceOffset = 0;\n  let previousRow = new Uint8Array(stride);\n\n  for (let y = 0; y < height; y += 1) {\n    const filter = inflated[sourceOffset];\n    sourceOffset += 1;\n    const row = new Uint8Array(stride);\n    for (let x = 0; x < stride; x += 1) {\n      const raw = inflated[sourceOffset + x];\n      const left = x >= channels ? row[x - channels] : 0;\n      const up = previousRow[x] ?? 0;\n      const upLeft = x >= channels ? previousRow[x - channels] ?? 0 : 0;","sourceCodeStart":760,"sourceCodeEnd":796,"githubUrl":"https://github.com/musistudio/claude-code-router/blob/99f24806c6a2c660b16e53e95211c517448a6c90/packages/electron/src/main/ipc.ts#L760-L796","documentation":"Error \"Unsupported PNG format.\" thrown in musistudio/claude-code-router.","triggerScenarios":"Thrown at packages/electron/src/main/ipc.ts:778 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":"99f24806c6a2c660b16e53e95211c517448a6c90","analyzedAt":"2026-08-27T04:11:01.184Z","schemaVersion":2},"datasetVersion":"2026-08-27T08:17:20.692Z"}