nextcloud/server · error · Sabre\DAV\Exception
'Failed to rename ' . $this->path . ' to ' . $newPath
Error message
'Failed to rename ' . $this->path . ' to ' . $newPath
What it means
Error "'Failed to rename ' . $this->path . ' to ' . $newPath" thrown in nextcloud/server.
Source
Thrown at apps/dav/lib/Connector/Sabre/Node.php:151
* @throws LockedException
*/
#[\Override]
public function setName($name): void {
if (!$this->canRename()) {
throw new Forbidden('');
}
/** @var string $parentPath */
[$parentPath,] = \Sabre\Uri\split($this->path);
/** @var string $newName */
[, $newName] = \Sabre\Uri\split($name);
$newPath = $parentPath . '/' . $newName;
// verify path of the target
$this->verifyPath($newPath);
if ($this->fileView->rename($this->path, $newPath) === false) {
throw new Exception('Failed to rename ' . $this->path . ' to ' . $newPath);
}
$this->path = $newPath;
$this->refreshInfo();
}
/**
* Returns the last modification time, as a unix timestamp
*
* @return int timestamp as integer
*/
#[\Override]
public function getLastModified(): int {
return $this->info->getMtime();
}
/**View on GitHub (pinned to ecdeb153ff)
When it happens
Trigger: Thrown at apps/dav/lib/Connector/Sabre/Node.php:151 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of nextcloud/server@ecdeb153ff (2026-08-17).
Data as JSON: /api/errors/76f0f6ad915e6745.
Report an issue: GitHub.