{"record":{"id":"530b5b0157628c9f","repo":"Wox-launcher/Wox","slug":"png-header-is-missing","errorCode":null,"errorMessage":"PNG header is missing","messagePattern":"PNG header is missing","errorType":"console","errorClass":"SystemExit","httpStatus":null,"severity":"error","filePath":"assets/generate_app_icons.sh","lineNumber":108,"sourceCode":"        offset += 4\n\n        if kind == b\"IHDR\":\n            width, height, bit_depth, color_type, compression, filter_method, interlace = struct.unpack(\">IIBBBBB\", payload)\n            if bit_depth != 8:\n                raise SystemExit(\"Only 8-bit PNG files are supported\")\n            if compression != 0 or filter_method != 0 or interlace != 0:\n                raise SystemExit(\"Only non-interlaced standard PNG files are supported\")\n        elif kind == b\"PLTE\":\n            palette = [tuple(payload[index : index + 3]) for index in range(0, len(payload), 3)]\n        elif kind == b\"tRNS\":\n            transparency = payload\n        elif kind == b\"IDAT\":\n            idat.extend(payload)\n        elif kind == b\"IEND\":\n            break\n\n    if width is None or height is None or color_type is None:\n        raise SystemExit(\"PNG header is missing\")\n\n    channels_by_type = {0: 1, 2: 3, 3: 1, 4: 2, 6: 4}\n    if color_type not in channels_by_type:\n        raise SystemExit(f\"Unsupported PNG color type: {color_type}\")\n    if color_type == 3 and palette is None:\n        raise SystemExit(\"Palette PNG is missing PLTE chunk\")\n\n    channels = channels_by_type[color_type]\n    row_bytes = width * channels\n    raw = zlib.decompress(bytes(idat))\n    rgba = bytearray(width * height * 4)\n    previous = bytearray(row_bytes)\n    source_offset = 0\n    target_offset = 0\n\n    for _ in range(height):\n        filter_type = raw[source_offset]\n        source_offset += 1","sourceCodeStart":90,"sourceCodeEnd":126,"githubUrl":"https://github.com/Wox-launcher/Wox/blob/1659730fcb37154f26497e07308b1f8789d659fe/assets/generate_app_icons.sh#L90-L126","documentation":"Error \"PNG header is missing\" thrown in Wox-launcher/Wox.","triggerScenarios":"Thrown at assets/generate_app_icons.sh:108 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":"1659730fcb37154f26497e07308b1f8789d659fe","analyzedAt":"2026-08-15T23:31:07.596Z","schemaVersion":2},"datasetVersion":"2026-08-16T03:17:38.424Z"}