{"record":{"id":"e8dbf785c2c696b0","repo":"phacility/phabricator","slug":"this-file-is-not-a-viewable-image","errorCode":null,"errorMessage":"This file is not a viewable image.","messagePattern":"This file is not a viewable image\\.","errorType":"exception","errorClass":"Exception","httpStatus":null,"severity":"error","filePath":"src/applications/files/storage/PhabricatorFile.php","lineNumber":1098,"sourceCode":"\n  public function getStorageProperty($key, $default = null) {\n    $properties = $this->getStorageProperties();\n    return idx($properties, $key, $default);\n  }\n\n  public function loadDataFromIterator($iterator) {\n    $result = '';\n\n    foreach ($iterator as $chunk) {\n      $result .= $chunk;\n    }\n\n    return $result;\n  }\n\n  public function updateDimensions($save = true) {\n    if (!$this->isViewableImage()) {\n      throw new Exception(pht('This file is not a viewable image.'));\n    }\n\n    if (!function_exists('imagecreatefromstring')) {\n      throw new Exception(pht('Cannot retrieve image information.'));\n    }\n\n    if ($this->getIsChunk()) {\n      throw new Exception(\n        pht('Refusing to assess image dimensions of file chunk.'));\n    }\n\n    $engine = $this->instantiateStorageEngine();\n    if ($engine->isChunkEngine()) {\n      throw new Exception(\n        pht('Refusing to assess image dimensions of chunked file.'));\n    }\n\n    $data = $this->loadFileData();","sourceCodeStart":1080,"sourceCodeEnd":1116,"githubUrl":"https://github.com/phacility/phabricator/blob/5720a38cfe95b00ca4be5016dd0d2f3195f4fa04/src/applications/files/storage/PhabricatorFile.php#L1080-L1116","documentation":"Error \"This file is not a viewable image.\" thrown in phacility/phabricator.","triggerScenarios":"Thrown at src/applications/files/storage/PhabricatorFile.php:1098 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":"5720a38cfe95b00ca4be5016dd0d2f3195f4fa04","analyzedAt":"2026-08-21T05:07:25.672Z","schemaVersion":2},"datasetVersion":"2026-08-21T11:28:35.574Z"}