{"record":{"id":"908d3efd9f9e0aa9","repo":"getgrav/grav","slug":"cannot-retrieve-stream-after-it-has-already-been-m","errorCode":null,"errorMessage":"Cannot retrieve stream after it has already been moved","messagePattern":"Cannot retrieve stream after it has already been moved","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"system/src/Grav/Framework/Form/FormFlashFile.php","lineNumber":244,"sourceCode":"            'id:private' => $this->id,\n            'field:private' => $this->field,\n            'moved:private' => $this->moved,\n            'upload:private' => $this->upload,\n        ];\n    }\n\n    /**\n     * @return void\n     * @throws RuntimeException if is moved or not ok\n     */\n    private function validateActive(): void\n    {\n        if (!$this->isOk()) {\n            throw new RuntimeException('Cannot retrieve stream due to upload error');\n        }\n\n        if ($this->moved) {\n            throw new RuntimeException('Cannot retrieve stream after it has already been moved');\n        }\n\n        if (!$this->getTmpFile()) {\n            throw new RuntimeException('Cannot retrieve stream as the file is missing');\n        }\n    }\n\n    /**\n     * @return bool return true if there is no upload error\n     */\n    private function isOk(): bool\n    {\n        return \\UPLOAD_ERR_OK === $this->getError();\n    }\n}\n","sourceCodeStart":226,"sourceCodeEnd":260,"githubUrl":"https://github.com/getgrav/grav/blob/6040efed04efa69b8209448ed81308e7c24147c2/system/src/Grav/Framework/Form/FormFlashFile.php#L226-L260","documentation":"Error \"Cannot retrieve stream after it has already been moved\" thrown in getgrav/grav.","triggerScenarios":"Thrown at system/src/Grav/Framework/Form/FormFlashFile.php:244 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":"6040efed04efa69b8209448ed81308e7c24147c2","analyzedAt":"2026-08-17T05:07:31.593Z","schemaVersion":2},"datasetVersion":"2026-08-17T09:17:11.063Z"}