{"record":{"id":"408319c9a05fd2bc","repo":"coollabsio/coolify","slug":"failed-to-encode-transfer-bundle","errorCode":null,"errorMessage":"Failed to encode transfer bundle.","messagePattern":"Failed to encode transfer bundle\\.","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"app/Livewire/Server/Transfer.php","lineNumber":127,"sourceCode":"\n            $bundle = $exporter->export($this->server, includeSensitive: true);\n            $this->exportId = data_get($bundle, 'export_id');\n            $this->lastWarnings = array_values((array) data_get($bundle, 'warnings', []));\n            $this->lastResultJson = null;\n\n            $payload = $bundle;\n            $fileName = 'server-transfer-'.$this->server->uuid.'.json';\n            if ($this->encryptBundle) {\n                if (blank($this->passphrase)) {\n                    throw new \\RuntimeException('Passphrase is required to encrypt the bundle.');\n                }\n                $payload = ServerTransferBundle::encryptWithPassphrase($bundle, $this->passphrase);\n                $fileName = 'server-transfer-'.$this->server->uuid.'.encrypted.json';\n            }\n\n            $json = json_encode($payload, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES);\n            if ($json === false) {\n                throw new \\RuntimeException('Failed to encode transfer bundle.');\n            }\n\n            $this->dispatch('success', 'Transfer bundle ready for download.');\n\n            return response()->streamDownload(function () use ($json) {\n                echo $json;\n            }, $fileName, [\n                'Content-Type' => 'application/json',\n            ]);\n        } catch (Throwable $e) {\n            return handleError($e, $this);\n        }\n    }\n\n    public function completeTransfer(ServerTransferClaimer $claimer): void\n    {\n        $this->ensureDevelopmentAvailability();\n","sourceCodeStart":109,"sourceCodeEnd":145,"githubUrl":"https://github.com/coollabsio/coolify/blob/70b9acc42467278373e00de77abb40684e25b395/app/Livewire/Server/Transfer.php#L109-L145","documentation":"Error \"Failed to encode transfer bundle.\" thrown in coollabsio/coolify.","triggerScenarios":"Thrown at app/Livewire/Server/Transfer.php:127 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":"70b9acc42467278373e00de77abb40684e25b395","analyzedAt":"2026-08-17T01:41:01.313Z","schemaVersion":2},"datasetVersion":"2026-08-17T04:17:16.089Z"}