getgrav/grav · error · RuntimeException
Cannot retrieve stream after it has already been moved
Error message
Cannot retrieve stream after it has already been moved
What it means
Error "Cannot retrieve stream after it has already been moved" thrown in getgrav/grav.
Source
Thrown at system/src/Grav/Framework/Form/FormFlashFile.php:244
'id:private' => $this->id,
'field:private' => $this->field,
'moved:private' => $this->moved,
'upload:private' => $this->upload,
];
}
/**
* @return void
* @throws RuntimeException if is moved or not ok
*/
private function validateActive(): void
{
if (!$this->isOk()) {
throw new RuntimeException('Cannot retrieve stream due to upload error');
}
if ($this->moved) {
throw new RuntimeException('Cannot retrieve stream after it has already been moved');
}
if (!$this->getTmpFile()) {
throw new RuntimeException('Cannot retrieve stream as the file is missing');
}
}
/**
* @return bool return true if there is no upload error
*/
private function isOk(): bool
{
return \UPLOAD_ERR_OK === $this->getError();
}
}
View on GitHub (pinned to 6040efed04)
When it happens
Trigger: Thrown at system/src/Grav/Framework/Form/FormFlashFile.php:244 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of getgrav/grav@6040efed04 (2026-08-17).
Data as JSON: /api/errors/908d3efd9f9e0aa9.
Report an issue: GitHub.